GetSetting Equivalent

  • Thread starter Thread starter Mike
  • Start date Start date
M

Mike

VB .NET version 2003

What is the equivalent of GetSetting when trying to read a .INI file. I'm
trying to read a .INI file and can't find anything that will help.
 
Mike said:
VB .NET version 2003

What is the equivalent of GetSetting when trying to read a .INI file. I'm trying to read a .INI file and can't find
anything that will help.

Look up the following API functions in the Platform SDK

GetPrivateProfileInt
GetPrivateProfileSection
GetPrivateProfileSectionNames
GetPrivateProfileString
GetPrivateProfileStruct

WritePrivateProfileSection
WritePrivateProfileString
WritePrivateProfileStruct

Note that INI files only contain strings, hence there
is no WriteProfileInt function.

When reading/writing specifically to WIN.INI, use
the following instead:

GetProfileInt
GetProfileSection
GetProfileString

WriteProfileSection
WriteProfileString
 
Mike said:
What is the equivalent of GetSetting when trying to read a .INI file. I'm
trying to read a .INI file and can't find anything that will help.

The .NET Framework doesn't have built-in support for accessing INI files.
You'll find some samples which demonstrate how to access INI files on the
bottom of the page referenced below:

Storing and loading user preferences
<URL:http://dotnet.mvps.org/dotnet/faqs/?id=userpreferences&lang=en>
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads

Registry Reading 7
.INI versus Registry 1
GetSetting LOGONSERVER? 1
Calling DLL atruntime 3
OpenNETCF SaveSetting / GetSetting 6
Reg Key Problems 1
Alarm problem 1
Last saved by 1

Back
Top