Does anyone know how to include the User Name in the ODBC driver by using the following code??
Thanks,
set WshShell = wscript.createObject( "WScript.Shell" )
const ODBC = "HKLM\SOFTWARE\ODBC\ODBC.INI\"
sName = "Name"
sServer = "Server"
sDesc = "Description"
sUser = "UserName"
dim ODBCS...
Thanks. It worked perfect except I could not write the User Name. Does anyone know?
Thanks,
'-----------------------------------------------------
set WshShell = wscript.createObject( "WScript.Shell" )
const ODBC = "HKLM\SOFTWARE\ODBC\ODBC.INI\"
sName = "Name"
sServer = "Server"
sDesc =...
I want to run p1.exe, then p2.exe and p3.exe
The following code execute p1.exe, p2.exe, p3.exe
Set objShell = CreateObject("WScript.Shell")
objShell.Run "C:\p1.exe"
objShell.Run "C:\p2.exe"
objShell.Run "C:\p3.exe"
Can anyone help, please?
Thanks,
I am writing tools for users using VBA. A menu will be added when a user opens the application. In this menu, the code will read the text file and import the modules. This menu will be changed frequently. It would be nice if I can add/ remove modules from a text file instead of editing in my VBA...
I have about 20 modules in folder C\modules
I created a text file that contains only modules I want to import in C:\modules\list.txt
list.txt
module1.bas
module6.bas
module10.bas
Does anyone know how to import the modules in list.txt into a Project's Modules using VBA?
Many thanks,
XT
Here's my code
Sub callLoop()
Dim pGxObj As IGxObject
Dim pGxApp As IGxApplication
Set pGxApp = Application
Set pGxObj = pGxApp.SelectedObject
Call LoopFolders(pGxObj)
MsgBox "A log file has been created in c:\01_BrokenLinks.txt", vbOKOnly
End Sub
Sub LoopFolders(pGxObj As...
PH,
I tried to comment a.close to test and forgot to remove it. Comment or uncomment a.close does not make any changes (I still get the special characters)
Thanks,
XT
I want to create a text file using VBA. If I select a folder, the VBA code will write all folders, filenames to a text file (text.txt)
The codes below write the text.txt but for some reason, the first line shows OK and the rest are in special characters. Does anyone have any ideas?
Thanks,
XT...
Nelviticus,
I have tried this but no luck.
Private Function MxDocument_OpenDocument() As Boolean
Dim strFileName As String
' Full path and name of file.
strFileName = "\\AAA\BBB\CCC\Template.mxt"
' Call function to test file lock.
If Not FileLocked(strFileName) Then...
TomThumbKP,
How do I modify if my template file is TEMPLATE.mxt and store in a network folder \\AAA\BBB\CCC ?
VBAjedi,
Two users can open the TEMPLATE.mxt and save at the same time. It does not have a lock file like Excel or Access.
Thanks,
XT
This is not a "busy" project. Chances to wipe out others' code are very low. We have only three developers and usually don't work at the same time but I just want to make sure ... and know how to deal with VBA.
Thanks,
XT
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.