Hi,
Below is a short VB function that will delete the query named "TEST 1" from
my database window and pop up a message box saying "Complete!" when done.
I need a paramater VB function like this that can prompt me in a pop-up box
for the query name I wish to delete (in case I wish to delte a different
query or table without creating multiple functions like this for each
database object). Can anyone help?
Function TEST()
On Error GoTo TEST_Err
DoCmd.DeleteObject acQuery, "TEST 1"
MsgBox "Complete!", vbInformation, ""
Exit Function
TEST_Exit:
Exit Function
TEST_Err:
MsgBox Error$
Resume TEST_Exit
End Function

Signature
AndrewB.
SteveS - 08 Mar 2007 00:07 GMT
Check out this page at "The Access Web ".
You should be able to modify it to do what you want:
http://www.mvps.org/access/modules/mdl0014.htm
HTH

Signature
Steve S
--------------------------------
"Veni, Vidi, Velcro"
(I came; I saw; I stuck around.)
> Hi,
>
[quoted text clipped - 21 lines]
>
> End Function