Results 1 to 4 of 4

Thread: [VB.net] Input Box - cancel button

Threaded View

  1. #1

    Thread Starter
    Member
    Join Date
    Dec 2007
    Posts
    42

    Resolved [VB.net] Input Box - cancel button

    Hi there, I have a problem with INPUT BOX.

    This is it:

    Code:
    dim variable1 as double
    
    variable1 = CDbl(InputBox("What is your height?"))
    Now, varible1 is double and whem I enter value into input box it is working.

    Problem:
    When I click cancel button, it sends empty string to this variable which leads to this error.

    Conversion from string "" to type 'Double' is not valid.

    Any help for me?
    Last edited by [venom]; Dec 4th, 2007 at 08:32 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width