Read from text file and write to registry

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • somersbd
    New Member
    • Feb 2008
    • 1

    Read from text file and write to registry

    I have a simple text file that I need to read and then write each line to the same key in the registry.
    Example:
    Text file name version.txt with the following lines
    HP
    01/01/2008
    4

    and would like to have end up with a registry key like:

    Windows Registry Editor Version 5.00
    [HKEY_LOCAL_MACH INE\SOFTWARE\Cu stom\Image]
    "Description"=" HP"
    "InstallDat e"= "01/01/2008"
    "Version"= "4"
  • RedSon
    Recognized Expert Expert
    • Jan 2007
    • 4980

    #2
    Originally posted by somersbd
    I have a simple text file that I need to read and then write each line to the same key in the registry.
    Example:
    Text file name version.txt with the following lines
    HP
    01/01/2008
    4

    and would like to have end up with a registry key like:

    Windows Registry Editor Version 5.00
    [HKEY_LOCAL_MACH INE\SOFTWARE\Cu stom\Image]
    "Description"=" HP"
    "InstallDat e"= "01/01/2008"
    "Version"= "4"
    Ok just use the registry functions to open, read and write registry entries.

    Comment

    Working...