I created a query and am using it in my subform. it refers to two tables. both have email in them so I created an alis in one table called [new email]
my VB code as follows returns "" in variable newemail below
I just opened this database in Access 2003 and it works fine. I can get an email in variable NewEmail
but then back in 2007 it's = "".
How do I find out which Service pack Office or Access 2007 has? there is no more help/about which in the other versions showed SP?
DougP
my VB code as follows returns "" in variable newemail below
Code:
Dim Conn2 As ADODB.Connection
Dim Rs1 As ADODB.Recordset
Dim SQLCode As String
Set Conn2 = CurrentProject.Connection
Set Rs1 = New ADODB.Recordset
Dim TheID As Integer
Dim NewEmail As String
TheID = Forms![frmUpdateEmails]![qryCompareEmailsToDirectoryDump subform].Form![ID]
[b][COLOR=red]NewEmail = Forms![frmUpdateEmails]![qryCompareEmailsToDirectoryDump subform].Form![New Email][/color][/b]
SQLCode = "Update [Data from pdf Latest] Set [Email Address] = '" & NewEmail & "' Where [ID] = " & TheID & ";"
Rs1.Open SQLCode, Conn2, adOpenStatic, adLockOptimistic
' close it this way
Set Rs1 = Nothing
Set Conn2 = Nothing
I just opened this database in Access 2003 and it works fine. I can get an email in variable NewEmail
but then back in 2007 it's = "".
How do I find out which Service pack Office or Access 2007 has? there is no more help/about which in the other versions showed SP?
DougP