Registry Problems Help Please! - registry.bas (0/1) 
Author Message
 Registry Problems Help Please! - registry.bas (0/1)

I looked up GetSettings() and SaveSettings() at MS and the KB
said that they could only save to the "VB and VBA Settings" Key..  
I do not want that so I'm using the API calls from AdvAPI32.DLL

I have been, still, trying to get
RegSetValueExString, and
to work for me..  I feel this is the better way to go, but have some
problems..   I am able to create a Key like
When I try to Set a value it doesn't seem to write the value to

This is the code that I'm writting on the form:
strCISServerPath = QueryValue("SOFTWARE\\CIS4WinClient", _

If strCISServerPath = "" Then
    strCISServerPath = "C:\DCOMServer\debug"
    CreateNewKey "SOFTWARE\\CIS4WinClient", _
    SetKeyValue "SOFTWARE\\CIS4WinClient", "Dir", _
        "C:\DCOMServer\debug", REG_SZ
End If

I have put together a Modal, BAS File, of exactly what I'm doing and
how  I'm calling these API calls and it is the attached file to this
message..   If someone would download and try to figure out what I'm
doing wrong I would be more than gracious.

Thanx in advance,
Chizl - CEO

Karland International

Tue, 29 Feb 2000 03:00:00 GMT  
 Registry Problems Help Please! - registry.bas (0/1)


>This is the code that I'm writting on the form:
>strCISServerPath = QueryValue("SOFTWARE\\CIS4WinClient", _
> "Dir")

>If strCISServerPath = "" Then
>    strCISServerPath = "C:\DCOMServer\debug"
>    CreateNewKey "SOFTWARE\\CIS4WinClient", _
>    SetKeyValue "SOFTWARE\\CIS4WinClient", "Dir", _
>    "C:\DCOMServer\debug", REG_SZ
>End If

I haven't test this, and I'm new at this as well, so you pays your
money and you takes your chances, but here goes.  As in so many other
places, the \ character is a control character ( like when you use
'\n' for a carriage return or new line, not as a subdirectory called
'n'), so if you actually want to print one out, you have to use \\.
At least this is how it is in a *.reg file.  If you entered your
c:\dcomserver\debug into the registry and then exported the resulting
key to a reg file and viewed it in notepad (did you know you can do
that?), you would see it as c:\\dcomserver\\debug.  My guess is that
you need to have the double backslash in your code as well.  But this
is just my first thought off the top of my head.  If this works,
please e-mail me at rramsey AT soli DOT inav DOT net.  


Wed, 01 Mar 2000 03:00:00 GMT  
 [ 2 post ] 

 Relevant Pages 

1. Registry Problems Help Please! - registry.bas (1/1)

2. Calling Registry.LocalMachine, Registry.CurrentUser by Registry.regHive?

3. Registry Problems - Please Help...

4. Major Registry Problems (Please Help!)

5. Reading Registry value, help me please,please

6. Registry Bas

7. registry.bas (0/1)

8. registry.bas (1/1)

9. Unusual results writing longs to Registry (please help)

10. registry help please

11. help please: example of seeing of a registry key exists

12. Retreiving a value from registry...please help


Powered by phpBB® Forum Software