Can anyone tell me what adjustments I need to make to the following to make it work in VBA?
SELECT Data.[Procurement Lead], Data.ProjectStatus
FROM Data
WHERE (((Data.[Procurement Lead])=IIf([Forms]![FilterForm]![FilterFormProcurementLead].[Value]='All',[Data].[Procurement Lead],[Forms]![FilterForm]![FilterFormProcurementLead])) AND ((Data.ProjectStatus)=IIf([Forms]![FilterForm]![FilterFormProjectStatus].[Value]='Open','1',IIf([Forms]![FilterForm]![FilterFormProjectStatus].[Value]='Closed','2',IIf([Forms]![FilterForm]![FilterFormProjectStatus].[Value]='All',[Data].[ProjectStatus])))))
SELECT Data.[Procurement Lead], Data.ProjectStatus
FROM Data
WHERE (((Data.[Procurement Lead])=IIf([Forms]![FilterForm]![FilterFormProcurementLead].[Value]='All',[Data].[Procurement Lead],[Forms]![FilterForm]![FilterFormProcurementLead])) AND ((Data.ProjectStatus)=IIf([Forms]![FilterForm]![FilterFormProjectStatus].[Value]='Open','1',IIf([Forms]![FilterForm]![FilterFormProjectStatus].[Value]='Closed','2',IIf([Forms]![FilterForm]![FilterFormProjectStatus].[Value]='All',[Data].[ProjectStatus])))))