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...

write a vb script to display first 5 odd numbers from 1 to 100

Answer Posted / mudaseer

dim i,vcnt,vstro
vcnt=0
for i=1 to 100 step 2
vstro=vstro & i & vbnewline
vcnt=vcnt+1
if vcnt=5 then exit for
next
msgbox vstro

Is This Answer Correct ?    14 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain about the extension .hta?

1081


What are the naming conventions while declaring a variable in the vbscript language?

1051


What is the difference between for loop and while loop?

1073


What are the different types of operators and their order of precedence?

1046


Mention what is vbscript procedures?

1015


Explain about tristate constants?

1032


What are the different types of loops available in the vbscript language?

990


Give me sm ideas to write Vbscripts abt protocol testing abilash700@gmail.com.

2091


Write a code to print numbers from 5 to 0?

1137


Which in-built functions are used to convert the specified expression in the form of date and string in the vbscript language?

1015


How many types of procedures are available in the vbscript language?

1006


Please let me Know regarding any material regarding VB Scripting which should be easily understandable for Beginners.

2051


Which operator is used to perform the comparison among 2 operands in the vbscript language?

976


Which operator can be used to change the value of the operand or change the state of the condition?

1038


Explain a few date functions in vbscript

995