Message and Input Boxes

format:


      anIntvar = msgbox(strmsg [,[intType] [,strTitle]])


ex.:


intPress = msgbox("are you Ok ?",_vbQuestion + vbYesNoCancel,_"Report Request")


where:


vbOkOnly - display the Ok button

vbOkcancel - display Ok & cancel

vbYesNocancel - Yes, No, Cancel

vbYesNo - Yes & No button

vbRetryCancel - retry & cancel


vbCritical - critical message icon

vbQuestion - warning query icon

vbExclamation - warning message icon

vbInformation - information icon



MsgBox() Return Value


vbOk               - 1

vbCancel         - 2

vbAbort           - 3

vbRetry           - 4

vbIgnore          - 5

vbYes              - 6

vbNo               - 7


strcomp = InputBox("what is the name of the company ?", "company request","xyz, Inc.")

 

InputBox() - build-in function that will allow user to make simple & direct single entry prompt

 

  return value is a STRING and it

  returns a NULL --> "" when empty

 

  dim sRet as String

 

  sRet = InputBox("String", _"Title", _"Default value")