FiveTech Support Forums

FiveWin / Harbour / xBase community
Board index FiveWin for Harbour/xHarbour new var in HKEY_CURRENT_USER
Posts: 340
Joined: Thu Jan 25, 2007 03:53 PM
new var in HKEY_CURRENT_USER
Posted: Wed Jul 03, 2013 09:20 AM

Hi to all,

any help to how insert/search a new var in:

Computer\HKEY_CURRENT_USER\Software\PDFCreator\Program ?

tks

Romeo/Zingoni

Posts: 6755
Joined: Wed Feb 15, 2012 08:25 PM
Re: new var in HKEY_CURRENT_USER
Posted: Wed Jul 03, 2013 09:29 AM

Maybe this thread can serve you

Quizas este hilo te pueda servir

viewtopic.php?f=3t=20357start=0hilit=HKEY_CURRENT_USER

&&&

Cristobal Navarro

Hay dos tipos de personas: las que te hacen perder el tiempo y las que te hacen perder la noción del tiempo

El secreto de la felicidad no está en hacer lo que te gusta, sino en que te guste lo que haces
Posts: 340
Joined: Thu Jan 25, 2007 03:53 PM
Re: new var in HKEY_CURRENT_USER
Posted: Wed Jul 03, 2013 10:09 AM

tks, it works !

now i am able to create a new var....but now i'am not able to cancel this new var using the function:

oreg:delete(cSubKey)

also using the function RegDeleteKey(oreg:nHandle,cSubKey) (it returns code error 2)

the cSubKey always exists

...additional help ?

tks

Posts: 6983
Joined: Fri Oct 07, 2005 07:07 PM
Re: new var in HKEY_CURRENT_USER
Posted: Wed Jul 03, 2013 10:22 AM
I think current user key is only a temporary key. The value is stored in c:\users\' + $element + '\ntuser.dat'.
Best regards,
Otto

This is a PS script which changes values for a specific user.


Code (fw): Select all Collapse
clear host

$null = New-PSDrive -Name HKU   -PSProvider Registry -Root Registry::HKEY_USERS
Get-PSDrive -PSProvider Registry

Push-Location

$array = @("Biene1", "Biene2", "Biene3", "Biene4"  )

#, "Winhotel1", "Winhotel2", "Winhotel3", "Winhotel4", "Winhotel5"

foreach ($element in $array) {
$element

$cQuelle = ' c:\users\' + $element + '\ntuser.dat'
$pfad = 'HKU:\Testuser\Control Panel\Mouse'

reg LOAD HKU\Testuser  $cQuelle


Write-Host $cQuelle
Write-Host $pfad

Set-ItemProperty -Path $pfad -Name 'DoubleClickHeight' -Value 50
Set-ItemProperty -Path $pfad -Name 'DoubleClickSpeed' -Value 370
Set-ItemProperty -Path $pfad -Name 'DoubleClickWidth' -Value 50

Set-Location $pfad

reg UNLOAD HKU\Testuser
}

Pop-Location

Continue the discussion