Jump to content


This is a ready-only archive of the InstallSite Forum. You cannot post any new content here. / Dies ist ein Archiv des InstallSite Forums. Hier können keine neuen Beiträge veröffentlicht werden.
Photo

Pass ini file data to registry


1 reply to this topic

jez123456

jez123456
  • Members
  • 2 posts

Posted 07 March 2006 - 11:34

Hi Experts

I'm building a Basic MSI package and have got most things working. I'm
having problems reading ini file data and then entering this into the
registry.

I've looked at the InstallScript example with a Custom Action which displays
a message with the contents from an ini file, but how can I pass that
Installscript string variable to the registry?

Here's what I have

ServerSettings.ini
[Server]
Name=JDSGLASGOW
Port=149
Site_UNC=\\JDSGLASGOW\SelfService
Site_URL=http://JDSGLASGOW/SelfService/

I require the Basic MSI setup.exe to read JDSGLASGOW from this ini file and
then enter it in the registry.

Many thanks


aarthi_m

aarthi_m
  • Full Members
  • 65 posts

Posted 07 March 2006 - 15:05

If you are not very specific about using installscript, there are some windows API's which can be used to read the entry from ini file.
GetPrivateProfileString will help you read the value against a keyword in the ini file. Then you can use any registry API to key that value into the registry.

Hope that helps