Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Nov 22nd, 2007, 10:26 PM   #1
venkatramasamy
Newbie
 
Join Date: Oct 2007
Location: INDIA
Posts: 19
Rep Power: 0 venkatramasamy is an unknown quantity at this point
Send a message via AIM to venkatramasamy
Post Registry Edit

Hi,

I use thefollowing code to Disable the UAC in windows Vista through registry access

KeyFound = myReg.UpdateKey(HKEY_LOCAL_MACHINE, "Software\Microsoft\Windows\CurrentVersion\Policies\System", "EnableLUA", "0")

it changes the "EnableLUA" value to "0" but the problem is
it changes the Type REG_DWORD to REG_SZ

i need REG_DWORD type remains the same...

is anybody there to say how to set the Type as REG_DWORD

Thanks in advance

Venkatramasamy SN
venkatramasamy is offline   Reply With Quote
Old Nov 29th, 2007, 9:15 PM   #2
Ancient Dragon
PFO God In Training
 
Ancient Dragon's Avatar
 
Join Date: Jun 2005
Location: near St Louis, MO. (USA)
Posts: 489
Rep Power: 4 Ancient Dragon is on a distinguished road
Re: Registry Edit

It appears that UpdateKey is something of your own doing -- I can't find it in any of the VB6 documentation.
Ancient Dragon is offline   Reply With Quote
Old Nov 29th, 2007, 9:43 PM   #3
venkatramasamy
Newbie
 
Join Date: Oct 2007
Location: INDIA
Posts: 19
Rep Power: 0 venkatramasamy is an unknown quantity at this point
Send a message via AIM to venkatramasamy
Re: Registry Edit

Hello Ancient dragon,
thank you for spending your time here

just tell me your suggestion to update the registry value properly,

Thanks in advance
Venkaramasamy SN

Last edited by Ancient Dragon; Nov 29th, 2007 at 10:40 PM. Reason: correct spelling
venkatramasamy is offline   Reply With Quote
Old Nov 29th, 2007, 10:27 PM   #4
Dameon
Troll
 
Dameon's Avatar
 
Join Date: Apr 2005
Location: Texas
Posts: 730
Rep Power: 4 Dameon is on a distinguished road
Re: Registry Edit

UpdateKey is possibly overloaded, meaning in this case that the key type will be set as string because the value parameter (0) is a string. Remove the quotes. If that doesn't work, check the documentation for how to supply the type explicitly. However, I'm neither familiar with this function nor can I find any reference to it online, so perhaps it is just some random snippet you found. If so, perhaps you should find a better way to poke the registry.

See here for one option
http://www.thescarms.com/VBasic/WshRegWait.aspx
__________________
MD5(sig) = bcef75433db02e9ad9bf81d6f7c5c270
Dameon is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Registry edit Programatically venkatramasamy Visual Basic 1 Nov 21st, 2007 4:36 AM
very simple question. make button change number in edit box nickm Delphi 2 Apr 29th, 2006 10:47 PM
Exception writing to registry... why? kurifu C# 3 Jun 4th, 2005 10:14 PM
Reading edit controls (I have tried, code provided) layer C++ 5 Apr 27th, 2005 7:31 PM
Edit registry via Command Prompt/Batch? [SOLVED] darklegend Other Scripting Languages 6 Mar 23rd, 2005 9:47 PM




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 4:42 PM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC