I am not able to create and save a
strSQL = "SELECT PRODUCT.product_id, PRODUCT.upc, PRODUCT.name, PRODUCT.size, PRODUCT.uom, PRODUCT.manufacturer, PRODUCT.category, PRODUCT.colour INTO PRODUCT IN 'C:\LIVE IMAGES\" & frm.cboManu.Value & ".mdb'" & _
" FROM PRODUCT " & _
"WHERE (((PRODUCT.desc_a) IN (SELECT desc_a FROM PRODUCT WHERE manufacturer LIKE " & Chr(34) & "*" & frm.cboManu.Value & "*" & Chr(34) & ")));"
You need to create a QueryDef in order to do this. Use the Access help on QueryDef. Hope this helps.
Dim q as QueryDef Set q = New QueryDef q.SQL = strSQL q.Name = "TEST_SQL" CurrentDb.QueryDefs.Append q CurrentDb.QueryDefs.Refresh