• ·申请链接
  • ·站点地图
  • ·用户注册
  • ·用户登录
  • ·收藏本站
  • ·联系我们
  • 您的位置我爱Aspx >> XML/XLST >> Upgrade Your INI Files to XML with .NET (3)
  • Upgrade Your INI Files to XML with .NET (3)

  • 作者:aspxer  来源:internet  日期:2007-4-30 20:37:07  关键字:.net,xml
  • Upgrade Your INI Files to XML with .NET (cont.)

    Updating and Adding Items

    Updating individual values is similar to retrieving them. You provide a section name, a key name, and the new value. The class uses the GetItem method to locate the appropriate <item> element, and then updates that item's value attribute with the specified new value. The Windows API function WritePrivateProfileString creates new sections and items if you call it with a section or key name that doesn't already exist.

    Although it's not good object-oriented design, for consistency the IniFileReader class acts identically, meaning that you can create a new section simply by passing a nonexistent section name. To update a section name, key name, or value for existing sections or items, select the section and item you want to update, enter the new values in the appropriate fields, and then click the Update button to apply the changes. To create a new section or key on the sample form, first click the New Section or New Key button to clear the current selections, and then enter the new section or key name and click the Update button to apply your changes.

    To delete a section using the API, you pass the section name and a null key value to the WritePrivateProfileString function—and you do the same with the IniFileReader class, except that you use the SetIniValue method. For example, the following code would delete the section named section1.

    【我对这篇文章有话说?】
    第一页上一页12下一页尾页
  • 广告位招租,广告代号:content_468_15
  • 上一篇:Upgrade Your INI Files to XML with .NET (2)
    下一篇:XML在.net平台下的自定义控件的应用
    • 相关文章
    • XML在.net平台下的自定义控件的应..[04-30]
    • 另一篇:用XMLHTTP Post/Get HTM..[04-30]
    • XSLT / XML / C#[04-30]
    • 找到一篇关于xmlhttp的文章[04-30]
    • 将XML信息存入文件[04-30]
    • 我没看但是根据提示这个是写XML的..[04-30]
    • 老外编的程序(一)--XMLDocum..[04-30]
    • Write relational data to an XM..[04-30]
    • 这个东东很好的,俺是从xml偷过来..[04-30]
    • 对象化数据---学习Xml Serializa..[04-30]
    • 最新文章
    • XML在.net平台下的自定义控件的应..[04-30]
    • 另一篇:用XMLHTTP Post/Get HTM..[04-30]
    • XSLT / XML / C#[04-30]
    • 找到一篇关于xmlhttp的文章[04-30]
    • 将XML信息存入文件[04-30]
    • 我没看但是根据提示这个是写XML的..[04-30]
    • 老外编的程序(一)--XMLDocum..[04-30]
    • Write relational data to an XM..[04-30]
    • 这个东东很好的,俺是从xml偷过来..[04-30]
    • 对象化数据---学习Xml Serializa..[04-30]
    • 赞助广告
    • 热门Top20
    • ·[Asp.Net] 南洋理工 校花 下载 南洋..
    • ·[Asp.Net] 南洋理工校花录像
    • ·[书籍] Visual C# 2005程序开发..
    • ·[Asp.Net] 从ASP过渡到ASP.net遗留..
    • ·[.NET专题] Microsoft .Net Remotin..
    • ·[Asp.Net] 通常C#面试题
    • ·[综合资讯] 如何看k线图-K线图三十个..
    • ·[综合资讯] 百度国庆徽标漏绘南海诸..
    • ·[Asp.Net] 江塘集中营剧情分集介绍
    • ·[综合资讯] 火影忍者234话在线观看
    • ·[Asp.Net] C#打造天气预报的WebSer..
    • ·[Asp.Net] 火影忍者在线观看及下载
    • ·[Asp.Net] ASP.Net 2.0的Web.confi..
    • ·[Asp.Net] 精妙SQL语句,基础,提升..
    • ·[Asp.Net] 海军副司令情妇图片
    • ·[Asp.Net] 性爱录音(木子美)碎语
    • ·[Asp.Net] 用Visual C#实现文件下载
    • ·[Asp.Net] 刘亦菲全档案
    • ·[开源] 图书馆管理系统Asp.net2..
    • ·[Asp.Net] JavaScript表单验证集锦
    • 推荐文章
    • ·从ASP过渡到ASP.net遗留的二十大..
    • ·百度称维基百科指责无道理
    • ·百度语音搜索今日上线
    • ·百度PKGoogle人机交互
    • ·酷6股权换百度流量
    • ·百度贴吧增加投票功能
    • ·腾讯QQ也做见不得人的事:带流氓软..
    • ·Programming ASP.NET中文版(第3版..
    • ·google生活搜索上线啦
    • ·2007a*star百度之星程序设计大赛..
    • ·百度电影视频搜索证明百度更加懂..
    • ·百度主题推广和Google Adsense
    • ·百度真的很麻烦
    • ·百度七大罪
    • ·了解WEB页面工具语言XML(五)好处
    • 最新文章
    • ·XML在.net平台下的自定义控件的应..
    • ·另一篇:用XMLHTTP Post/Get HTM..
    • ·XSLT / XML / C#
    • ·找到一篇关于xmlhttp的文章
    • ·将XML信息存入文件
    • ·我没看但是根据提示这个是写XML的..
    • ·老外编的程序(一)--XMLDocum..
    • ·Write relational data to an XM..
    • ·这个东东很好的,俺是从xml偷过来..
    • ·对象化数据---学习Xml Serializa..
    • ·Reading XML Files using XmlDoc..
    • ·将某一目录下的所有相同格式的 X..
    • ·串行化XML(三)
    • ·Upgrade Your INI Files to XML ..
    • ·用C#遍历XML
    • ·XMLHelp 下
    • ·XMLHelp(上)
    • ·XmlConnection
    • ·TextXmlHelp
    • ·XmlDataAdapter
    • 关于我们 | 广告服务 | 网站建设 | 版权申明 | 申请链接 | 联系我们
    • Copyright © 2007 5iaspx.COM. All Right Reserved.
    • 本站内容仅供学习,研究,探讨,个人收藏,如有侵权,敬请联系我们,我们尽快解决!