首页 >> 读书频道 >> 电脑 >> 用ASP读取Windows标准INI格式文件
 
· 怎样使用ASP实现Pin
· 友情连接浏览器
· 结束ADOVB.INC的
· 介绍一下GETROWS的
· 利用MSCHART画图的
· 可以近视替代remote
· 关于打印页面的一些经验
· 将HTML表单数据存储为
· 数据排序及如何动态排序
· 连接各种数据库的代码的总
· 用VB6创建MTS组件
· vbscript和jav
 
· 美容养颜手册
· 加油金顺剧情分集介绍完整
· 红楼梦:120回全本[清
· 素质教育在美国
· 全唐诗卷四十六
· 韩剧《布拉格恋人》剧情介
· 夜航船[作者:明·张岱]
· 局外人[作者:韩·可爱淘
· 现场流行病学
· 源氏物语[日本:紫式部]
· 武林寓言故事
· 2006高考录取规则
 
· (出租)中动商场部分及写
· (出租)中动动漫基地&#
· 喜剧学院
· 《善德女王》剧情介绍
· 魔女18号 剧情
· 丑女无敌剧情介绍
· 魔女幼熙剧情介绍
· 龙游天下剧情介绍
· 震撼世界的七日剧情介绍
· 静静的白桦林剧情介绍
· 心情日记—老公今天我想对
· 旗舰剧情介绍
欢迎来到月影社区!如果您觉得这里不错,请推荐给您的朋友们。月影社区:http://wf66.com/

用ASP读取Windows标准INI格式文件


查看有无更新版本

关键字:ASP技巧 2006-9-8

 

Have you needed to get information dynamically from Standard Formatted Windows INI files? Here's a set of tools to help you with just that. In this tutorial, we are going to discuss specific actions. More details can be obtained by looking at the files supplied.
Let's see how to implement the tools usage by looking at some parts of TEST.ASP:

<!--#include virtual="/readini/inifile.inc"-->
For fairly obvious reasons, we need to include the tools in our page, of course we should fix the path the include file is stored it.
<%
     call IniFileLoad("physical=c:\boot.ini")
%>
Next, a call to IniFileLoad fetches the INI file into a dictionary object called IniFileDictionary. You can specify a physical path as listed above, or you could specify a virtual path such as "virtual=/readini/test.ini".

StrBuf = IniFileValue("boot loader|timeout")
StrBuf = IniFileValue("boot loader")
Finally, we need to ask for a value from the dictionary. You can specify an individual value by using the section name and value name separated by a vertical bar (sometimes referred to as a 'pipe') character. Alternately, we can request the entire content of a section by not specifying the value name. When the section is returned, the data is formatted as:
   Section name|Value name=Value Data~Section name|ValueName=Value Data
Note that each section/value/data triplet is separated by a tilde character.
Well, that's all there is to it! Happy programming!
Attachments:
This ZIP file contains an INC file with the utility routines, a test INI file, and an ASP file that demonstrates the tools usage.  

用ASP读取Windows标准INI格式文件

[ 1 ]
用ASP读取Windows标准INI格式文件 num

打印本页 关闭

关于我们版权声明本站导航友情连结作品演示 TOP↑