A
Ant
Hi All
This seems very simple and I am a bit embarassed that I am
having trouble with it. I know I have done it before but
cant remember the exact format that works.
Basically (simplified)
I have a table with 2 columns 'Name' and 'Path' I have a
combo box where the user selects 'Name'. I want to
use 'Path' in my code.
Private Sub cmdSelectDB_Click()
Dim strName As String
Dim strPath As String
Dim strFullPath As String
strName = me.lstName.Text
strPath = "SELECT MAx(Path) FROM TblCompNamePath Where
CompanyName = *strName"
strFullPath = strPath + "\" + strFileName + "_be"
End Sub
* What is the best way to refer to a string in an SQL
statement in Code?
I have simplified this but it should give you an idea of
what I want to do and where I am going wrong.
Ant
This seems very simple and I am a bit embarassed that I am
having trouble with it. I know I have done it before but
cant remember the exact format that works.
Basically (simplified)
I have a table with 2 columns 'Name' and 'Path' I have a
combo box where the user selects 'Name'. I want to
use 'Path' in my code.
Private Sub cmdSelectDB_Click()
Dim strName As String
Dim strPath As String
Dim strFullPath As String
strName = me.lstName.Text
strPath = "SELECT MAx(Path) FROM TblCompNamePath Where
CompanyName = *strName"
strFullPath = strPath + "\" + strFileName + "_be"
End Sub
* What is the best way to refer to a string in an SQL
statement in Code?
I have simplified this but it should give you an idea of
what I want to do and where I am going wrong.
Ant