..:: MX Studio Fóruns ::..: chaves e valores no Registro do Windows - ..:: MX Studio Fóruns ::..

Jump to content

Publicidade




Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

chaves e valores no Registro do Windows

#1 User is offline   xanburzum 

  • Group: Administrador
  • Posts: 2076
  • Joined: 04-November 08

Posted 01 November 2009 - 05:18 PM

A declaração WrReg escreve chaves e valores no Registro do Windows. O
argumento Path é necessário o caminho para uma chave ou valor que será criado se
não foi encontrado. StrToWr são os dados para entrar na chave ou valor especificado no
Path.


WrReg path, strToWrite

usando:
CÓDIGO
<%

' escrever no registo

dim a

' escrever um valor
WrReg "HKCU\testregwrite\testvalue", " teste de valor"

' escrever uma key
WrReg "HKCU\testregwrite\testkey\", "valor key"

%>

code:

CÓDIGO
<%
Private Sub WrReg (byVal path, byVal strToWrite)
    Dim objShl
    Set objShl = CreateObject("wscript.shell")
    On Error Resume Next
    if IsNumeric( strToWrite ) Then
        objShl.WrReg( path, CInt( strToWrite ), "REG_DWORD" )
    else
        objShl.WrReg( path, strToWrite )
    end if
    If Err Then Err.Clear
    On Error GoTo 0
    Set objShl = Nothing
End Sub
%>

0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic



Publicidade




1 User(s) are reading this topic
0 membro(s), 1 visitante(s) e 0 membros anônimo(s)