i am trying to make a program that sets restrictions on user accounts, i have checkboxes that the admin checks to set restrictions on the user accounts, but i need the code to add a .reg file to the registry.
can anybody help me plz
chris1990
Printable View
i am trying to make a program that sets restrictions on user accounts, i have checkboxes that the admin checks to set restrictions on the user accounts, but i need the code to add a .reg file to the registry.
can anybody help me plz
chris1990
shell regsrvr32, there is a parameter that will stop the messageboxes, maybe /s
Quote:
Originally Posted by chris1990
Make sure that you encript the data somehow. I personally would use a database but I don't know what type of application you have designed. Tell us more about your app.
I am trying to make a program like the one in the hyperlink
i think it uses the reg
http://www.softheap.com/secagentscreenshots.html
For merging .reg files, use regedit.exeQuote:
Originally Posted by chris1990
If you want to do it in VB use ShellExecute:-Code:'From the command line.
' /s means silent mode merging.
regedit /s C:\Temp\MySettings.reg
VB Code:
Option Explicit 'Form level code. Private Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" _ (ByVal hwnd As Long, ByVal lpOperation As String, ByVal lpFile As String, _ ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long Const SW_HIDE = 0 Private Sub Form_Click() Dim retval As Long 'Merge it without confirmation messages. retval = ShellExecute(Me.hwnd, "open", "regedit.exe", "/s C:\Temp\MySettings.reg", vbNullString, SW_HIDE) End Sub