so, I quess what you want is:
code:
$nul=writevalue("HKCU\Software\Add-On\Products\exchange central\paths","DefaultDatabse","\\profile-server\profiles\"+@userid+"\applikation data\addon\","REG_SZ")

I don't remember what was the first version that automatically creates the subkeys if they don't exist but if I remember my test version correctly, at least 4.12 supports that.
_________________________
!

download KiXnet