Click here to Skip to main content
15,898,035 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralKey board shortcuts are not displayed on the form until user press Alt Key Pin
Sipder21-Jan-08 18:42
Sipder21-Jan-08 18:42 
GeneralRe: Key board shortcuts are not displayed on the form until user press Alt Key Pin
John_Adams21-Jan-08 20:37
John_Adams21-Jan-08 20:37 
GeneralRe: Key board shortcuts are not displayed on the form until user press Alt Key Pin
Sipder22-Jan-08 20:51
Sipder22-Jan-08 20:51 
GeneralRe: Key board shortcuts are not displayed on the form until user press Alt Key Pin
Dave Kreskowiak22-Jan-08 5:00
mveDave Kreskowiak22-Jan-08 5:00 
GeneralSearch a word in a .txt file and add some content [modified] Pin
HenrydeSousa21-Jan-08 14:41
HenrydeSousa21-Jan-08 14:41 
GeneralRe: Search a word in a .txt file and add some content Pin
Steven J Jowett22-Jan-08 5:19
Steven J Jowett22-Jan-08 5:19 
GeneralRe: Search a word in a .txt file and add some content Pin
HenrydeSousa24-Jan-08 6:00
HenrydeSousa24-Jan-08 6:00 
QuestionRe: VB6 - getting contents of registry entry [modified] Pin
mla15421-Jan-08 11:58
mla15421-Jan-08 11:58 
Hello,
I have been trying to get the contents of a registry entry.  I tried the following:

'http://www.andreavb.com/tip080001.html
Private Declare Function RegOpenKeyEx Lib "advapi32.dll" Alias "RegOpenKeyExA" (ByVal hKey As Long, _
    ByVal lpSubKey As String, ByVal ulOptions As Long, ByVal samDesired As Long, phkResult As Long _
    ) As Long
    
'http://www.windowsdevcenter.com/pub/a/windows/2004/07/27/VB_Registry_Values.html
Private Declare Function RegQueryValueEx Lib "advapi32.dll" Alias "RegQueryValueExA" ( _
   ByVal hKey As Long, ByVal lpValueName As String, ByVal lpReserved As Long, _
   lpType As Long, lpData As Any, lpcbData As Long) As Long

Private Sub Form_Load()
   RegOpenKeyEx HKEY_LOCAL_MACHINE, "SOFTWARE\Microsoft\Windows\CurrentVersion", _
        0&, KEY_READ, hKey
   RegQueryValueEx hKey, "CommonFilesDir", 0, 0, sValue, iTemp
End Sub


After the RegOpenKeyEx is executed, hKey has a value of 0.  Something doesn't seem right here.  Can anyone help?

Regards,
Mike

modified on Tuesday, January 22, 2008 9:37:31 AM

QuestionRe: VB6 - getting contents of registry entry [modified] Pin
mla15422-Jan-08 4:43
mla15422-Jan-08 4:43 
GeneralDisplaying data in a gridview programatically Pin
solarthur0121-Jan-08 11:26
solarthur0121-Jan-08 11:26 
GeneralRe: Displaying data in a gridview programatically Pin
Usharva21-Jan-08 19:34
Usharva21-Jan-08 19:34 
Generalnumber of rows retrieved using a select statement and a table adapter Pin
AAGTHosting21-Jan-08 9:23
AAGTHosting21-Jan-08 9:23 
GeneralRe: number of rows retrieved using a select statement and a table adapter Pin
Steven J Jowett21-Jan-08 10:38
Steven J Jowett21-Jan-08 10:38 
GeneralRe: number of rows retrieved using a select statement and a table adapter Pin
AAGTHosting21-Jan-08 12:52
AAGTHosting21-Jan-08 12:52 
GeneralRe: number of rows retrieved using a select statement and a table adapter Pin
Steven J Jowett21-Jan-08 22:16
Steven J Jowett21-Jan-08 22:16 
GeneralRe: number of rows retrieved using a select statement and a table adapter Pin
AAGTHosting21-Jan-08 12:57
AAGTHosting21-Jan-08 12:57 
GeneralSet ListView Item to Selected Pin
VFaul21-Jan-08 7:45
VFaul21-Jan-08 7:45 
GeneralRe: Set ListView Item to Selected Pin
VFaul21-Jan-08 8:41
VFaul21-Jan-08 8:41 
GeneralRestricting multiple instance of application Pin
manisghouri21-Jan-08 2:11
manisghouri21-Jan-08 2:11 
GeneralRe: Restricting multiple instance of application Pin
Steven J Jowett21-Jan-08 2:26
Steven J Jowett21-Jan-08 2:26 
GeneralRe: Restricting multiple instance of application Pin
manisghouri21-Jan-08 3:11
manisghouri21-Jan-08 3:11 
GeneralRe: Restricting multiple instance of application Pin
Steven J Jowett21-Jan-08 4:15
Steven J Jowett21-Jan-08 4:15 
GeneralRe: Restricting multiple instance of application Pin
manisghouri21-Jan-08 10:17
manisghouri21-Jan-08 10:17 
GeneralRe: Restricting multiple instance of application Pin
Steven J Jowett21-Jan-08 10:36
Steven J Jowett21-Jan-08 10:36 
GeneralRe: Restricting multiple instance of application Pin
nlarson1121-Jan-08 11:32
nlarson1121-Jan-08 11:32 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.