| | |
input box
Please support our Visual Basic 4 / 5 / 6 advertiser: Programming Forums - DaniWeb Sister Site
Thread Solved |
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
retval = inputbox("type stuff") if retval = "" then ' /* Cancel Pushed, Or Left Blank */ msgbox "You Entered Nothing..." else ' /* They Typed Stuff */ msgbox retval end if
•
•
Join Date: Aug 2006
Posts: 29
Reputation:
Solved Threads: 0
•
•
•
•
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
retval = inputbox("type stuff") if retval = "" then ' /* Cancel Pushed, Or Left Blank */ msgbox "You Entered Nothing..." else ' /* They Typed Stuff */ msgbox retval end if
In the code I posted, retval (the variable) will be blank if the user pressed cancel. Hence the code:
Visual Basic 4 / 5 / 6 Syntax (Toggle Plain Text)
if retval = "" then ' /* Cancel Pushed, Or Left Blank */ msgbox "You Entered Nothing..."
![]() |
Similar Threads
- Looking for List Box help, please! (VB.NET)
- Input box not showing (HTML and CSS)
- Text input box alignment question (HTML and CSS)
- Sending data to a input box on another website? (PHP)
- Validation Problems for Input Box data (VB.NET)
Other Threads in the Visual Basic 4 / 5 / 6 Forum
- Previous Thread: How to delete the registry entry of vb project
- Next Thread: Help with Debugging in VB 6
| Thread Tools | Search this Thread |
Tag cloud for Visual Basic 4 / 5 / 6
* 6 429 2007 access activex add age append application basic beginner birth bmp calculator cd cells.find click client code college column component connection connectionproblemusingvb6usingoledb copy creat ctrl+f data database datareport date delete dissertations dissertationthesis dissertationtopic edit error excel excelmacro file filename form hardware header iamthwee image inboxinvb internetfiledownload keypress label listbox listview liveperson login looping machine microsoft movingranges number objectinsert open oracle password prime program prompt range-objects readfile reading record refresh remotesqlserverdatabase report retrieve save search sendbyte sites sort sql sql2008 sqlserver subroutine table tags textbox time timer urldownloadtofile vb vb6 vb6.0 vba visual visualbasic visualbasic6 web window windows






