A
Arnie
Hi all,
can anyone help the code below seems to be working however, i am being
asked for
the strAfter parameter Value. runing through the code in a watch window i
can see that strAfter = "Fred" but when it gets to the DoCmd.RunSQL StrSQL it
asks me for the parameter value . what have i done wrong?
strFile = "C:\Folder\File.fpm"
intFile = FreeFile()
Open strFile For Input As #intFile
Do While Not EOF(intFile)
Line Input #intFile, strBuffer
intEqualSign = InStr(strBuffer, "=")
If intEqualSign > 0 Then
strBefore = Left$(strBuffer, intEqualSign - 1)
strAfter = Mid$(strBuffer, intEqualSign + 1)
Select Case strBefore
Case "Name"
StrName = strAfter
StrSQL = "INSERT INTO [Table1] (Name)" & " SELECT strAfter"
DoCmd.RunSQL StrSQL
Thanks in advance
Arnie
can anyone help the code below seems to be working however, i am being
asked for
the strAfter parameter Value. runing through the code in a watch window i
can see that strAfter = "Fred" but when it gets to the DoCmd.RunSQL StrSQL it
asks me for the parameter value . what have i done wrong?
strFile = "C:\Folder\File.fpm"
intFile = FreeFile()
Open strFile For Input As #intFile
Do While Not EOF(intFile)
Line Input #intFile, strBuffer
intEqualSign = InStr(strBuffer, "=")
If intEqualSign > 0 Then
strBefore = Left$(strBuffer, intEqualSign - 1)
strAfter = Mid$(strBuffer, intEqualSign + 1)
Select Case strBefore
Case "Name"
StrName = strAfter
StrSQL = "INSERT INTO [Table1] (Name)" & " SELECT strAfter"
DoCmd.RunSQL StrSQL
Thanks in advance
Arnie