|
-
Feb 17th, 2007, 03:17 AM
#1
Thread Starter
WiggleWiggle
[RESOLVED] Registry Code Error - Type Mismach
I get a "Type Mismatch" for this line of code:
VB Code:
If RegReadSZ(HKEY_LOCAL_MACHINE, strSubKey, "Reg_FirstTime", strRet) <> "No" Then
My usual boring signature: Something
-
Feb 17th, 2007, 06:26 AM
#2
Re: Registry Code Error - Type Mismach
What function does RegReadSZ do?
I've had that error in the past when a reg key doesn't exist so I've used this. (using your example)
VB Code:
Dim sKey as String
sKey = RegReadSZ(HKEY_LOCAL_MACHINE, strSubKey, "Reg_FirstTime", strRet)
If sKey <> "" Then
If sKey <> "No" Then
'do your stuff
End If
End If
-
Feb 17th, 2007, 12:07 PM
#3
Thread Starter
WiggleWiggle
Re: Registry Code Error - Type Mismach
thanks
My usual boring signature: Something
-
Feb 17th, 2007, 04:22 PM
#4
Re: [RESOLVED] Registry Code Error - Type Mismach
 Originally Posted by dclamp
I get a "Type Mismatch" for this line of code:
VB Code:
If RegReadSZ(HKEY_LOCAL_MACHINE, strSubKey, "Reg_FirstTime", strRet) <> "No" Then
That looks awfully like some code I've created at some time. If it is, then RegReadSZ returns a Long error code. The string Value "No" (or whatever) is returned in strRet. (It's just my way of returning a code as well as a Value)
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|