|
|
|
SSC Journeyman
      
Group: General Forum Members
Last Login: Wednesday, October 03, 2012 6:35 AM
Points: 97,
Visits: 501
|
|
Hi, Can anyone post me an example batch file (.bat) that will create a ODBC i.e. regedit, and allow me to change a value for a database in a software application key?? i know the keys i want to edit, as i have created these in other pragram wrappers..but are they the same when i run them through a batch file?
This script will run on logon for each user within a particular OU
My executable script section... SectionEnd Section "Create ODBC (NEW Installs Only)" WriteRegStr HKLM "SOFTWARE\ODBC\ODBC.INI\ODBC Data Sources" "${ODBC_CONNECTION_NAME}" "SQL Server" WriteRegStr HKLM "SOFTWARE\ODBC\ODBC.INI\${ODBC_CONNECTION_NAME}" "Description" "Test Log Connection" WriteRegStr HKLM "SOFTWARE\ODBC\ODBC.INI\${ODBC_CONNECTION_NAME}" "Driver" "$SYSDIR\SQLSRV32.dll" WriteRegStr HKLM "SOFTWARE\ODBC\ODBC.INI\${ODBC_CONNECTION_NAME}" "LastUser" "sysaudit" WriteRegStr HKLM "SOFTWARE\ODBC\ODBC.INI\${ODBC_CONNECTION_NAME}" "Server" "d-ap50" WriteRegStr HKLM "SOFTWARE\ODBC\ODBC.INI\${ODBC_CONNECTION_NAME}" "Database" "SysAudit" WriteRegStr HKLM "SOFTWARE\ODBC\ODBC.INI\${ODBC_CONNECTION_NAME}" "Trusted_Connection" "Trusted_Connection"
SectionEnd
Oraculum
|
|
|
|
|
SSCrazy
      
Group: General Forum Members
Last Login: 2 days ago @ 5:34 PM
Points: 2,605,
Visits: 760
|
|
Try experimenting with reg.exe. It should be installed with Windows by default. It is a command-line registry editing tool. Just run reg /? from a command prompt to get help.
Scott Duncan
MARCUS. Why dost thou laugh? It fits not with this hour. TITUS. Why, I have not another tear to shed; --Titus Andronicus, William Shakespeare
|
|
|
|