Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

Can we display only integers / numbers through the message
box? Is there any constraint to do so?

Answer Posted / hemal1972

yes, we can display only integers/numbers through the
message box. following is the code.

'code starts here
'declaring variable which holds integer number.
dim intA as integer
'declaring variable which holds string value
dim strB as string

'now, if we have textbox control in which we enter the
value of any number which may or may not be integer.

intA=cint(val(text1.text))'text1 is name of textbox
control.
strB= cstr(intA)
msgbox strB,vbokonly,"here is integer number"
'code ends here.

paste this code in command1_click event in the form which
contains textbox control text1 and commandbutton control
command1.run the program. enter any number in textbox,
click command1 and see the result in message box. thanks.


Is This Answer Correct ?    0 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can you Navigate from the DHTML application to another DHTML application? .

1790


Can you create a tabletype of recordset in Jet connected ODBC dbengine.

1903


How would you attach pictures in column headers of List View Control?

2022


___,_____ and ____ container objects.

1562


Explain about creating VB applications in excel?

1061


Is visual basic easy?

962


Explain about conditional operators?

951


What is Seek Method which type of record set is available this?

1860


Can you create a tabletype of recordset in Jet - connected ODBC dbengine?

2000


what are the Differences between Recordset and Resultsets?

2464


what are the Types of LockEdits in RDO?

2032


How do I add a form in visual basic?

901


What is snapshot in vb?

894


What type of databases you can access through ADO Data Access Object?

2041


____ property of menu cannot be set at run time.

1658