Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Message Box to Display Results of a Query

Status
Not open for further replies.

dcrosier

Instructor
Mar 17, 2000
51
US
I would like to create a Message Box that will display the results to two seperate queries. Could someone help me with the syntex? Both Queries are Counts of records based on criteria.

I will be attaching the msgbox to the OnOpen Event of the Switchboard in Access 2000.

msgbox ("Total Items Checked Out: qryResult1 Total Items Late: qryResult2", vbOkOnly, "Late Equipment")

The above is where I am thinking, I just need help on passing the query result into the message box.

Thanks.
Dawn
 
Just concatenate a string for the Prompt:
Code:
Dim sTmp As String

sTmp = "Total Items Checked Out: " & qryResult1 & vbcrlf & _
       "Total Items Late: " & qryResult2

MsgBox (sTmp, vbOkOnly, "Late Equipment")
DimensionalSolutions@Core.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top