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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

msgbox help

Status
Not open for further replies.

skierm

Programmer
Jun 9, 2003
39
US
i want to use a msgbox that has yes or no option and then depending on what the user chooses i want to do something. i just dont know how to get the values from the function msgbox. thanks
 
Dim strMsg as string

strMsg = MsgBox("Ask a question?", vbYesNo, "Question")

If strMsg = vbYes Then
' do this if yes
Else
' do this if no
End If

****************************
Only two things are infinite, the universe and human stupidity,
and I'm not sure about the former. (Albert Einstein)

Robert L. Johnson III
MCSA, CNA, MCP, Network+, A+
wildmage@tampabay.rr.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top