C
Calvin Willman
How do I deal with double quotes in a string in VBA.
I've created a SQL Query as string to return a Recordset. The string is as
strRs = "SELECT tblKPIs.Customer, DatePart(""M"", [tblKPIs.Date]) as
DateMonth, tblKPIs.TotSales, tblKPIs.Internet, tblKPIs.Email, tblKPIs.Fax,
tblKPIs.Phone, tblKPIs.SameDay, tblKPIs.[24Hrs], tblKPIs.[48Hrs],
tblKPIs.Over48Hrs, tblKPIs.Special" _
& "FROM tblCustomers INNER JOIN tblKPIs ON tblCustomers.CustomerID =
tblKPIs.Customer" _
& "WHERE (((tblKPIs.Customer)= " & intCustomer & "));"
I don't think this is working because of the double quotes in the first line
for DatePart, how do I do this??
Thanks
I've created a SQL Query as string to return a Recordset. The string is as
strRs = "SELECT tblKPIs.Customer, DatePart(""M"", [tblKPIs.Date]) as
DateMonth, tblKPIs.TotSales, tblKPIs.Internet, tblKPIs.Email, tblKPIs.Fax,
tblKPIs.Phone, tblKPIs.SameDay, tblKPIs.[24Hrs], tblKPIs.[48Hrs],
tblKPIs.Over48Hrs, tblKPIs.Special" _
& "FROM tblCustomers INNER JOIN tblKPIs ON tblCustomers.CustomerID =
tblKPIs.Customer" _
& "WHERE (((tblKPIs.Customer)= " & intCustomer & "));"
I don't think this is working because of the double quotes in the first line
for DatePart, how do I do this??
Thanks