Pages

Thursday, December 29, 2011

Write And Save A New Query Using Vba

If you want to create a new query using vba in access.

Here is the code-

Sub create_a_new_query_in_access_vba()
Dim new_qry As QueryDef
Set newqry = CurrentDb.CreateQueryDef("new_temp_qry", "SELECT * FROM sales_detail where state ='delhi'")
RefreshDatabaseWindow
End Sub


Download Access Database

No comments:

Post a Comment