write a vb script to display apple that is 1st a should be
displayed then ap then app then appl then apple

Answers were Sorted based on User's Feedback



write a vb script to display apple that is 1st a should be displayed then ap then app then appl th..

Answer / aparajita mohapatra

val="apple"
For i=1 to len(val)
val1=mid(val,1,i)
print val1

Next

Is This Answer Correct ?    4 Yes 2 No

write a vb script to display apple that is 1st a should be displayed then ap then app then appl th..

Answer / usha

str="apple"

for i = 1 to len(str)

msgbox left(str,i)

next

Is This Answer Correct ?    1 Yes 0 No

write a vb script to display apple that is 1st a should be displayed then ap then app then appl th..

Answer / mudaseer

above answer is almost correct but there is one mistake

val="apple"
For i=1 to len(val)
val1=mid(val,1,i)
msgbox val1

Next

instead of msgbox he has used print

Is This Answer Correct ?    2 Yes 2 No

write a vb script to display apple that is 1st a should be displayed then ap then app then appl th..

Answer / prathyusha

str="apple"
For i=1 To Len(str)
var=Mid(str,i,1)
char=char&var
newchar=newchar&vbcrlf&char
Next
MsgBox newchar

Is This Answer Correct ?    0 Yes 0 No

write a vb script to display apple that is 1st a should be displayed then ap then app then appl th..

Answer / abhishek mallabadi

dim apple
apple="a"
msgbox apple
apple1=apple & "p"
msgbox apple1
apple2=apple1 & "p"
msgbox apple2
apple3=apple2 & "l"
msgbox apple3
apple4=apple3 & "e"
msgbox apple4

Is This Answer Correct ?    0 Yes 1 No

write a vb script to display apple that is 1st a should be displayed then ap then app then appl th..

Answer / sadashivbyagi

guys dont complex the simple qn's

just try for this k

msgbox "a"&" "&"ap"&" "&"app"&" "&"appl"&" "&"apple"

Is This Answer Correct ?    0 Yes 2 No

write a vb script to display apple that is 1st a should be displayed then ap then app then appl th..

Answer / mudaseer

msgbox "a"
msgbox "ap"
msgbox "app"
msgbox "appl"
msgbox "apple"

Is This Answer Correct ?    0 Yes 5 No

Post New Answer

More VB Script Interview Questions

By default in vbscript the arguments passed to functions and subroutines are by reference or by value?

0 Answers  


write a vbscrpit to swap values

2 Answers   Adani,


Write a function for Instr(). We need to write a function that works as same as Instr(). Code or Even pseudo code is good enough for me.?

0 Answers   Microsoft,


what is the purpose of the Reporter.ReportEvent in QTP and also please give the brief description about Reporter.ReportEvent ?

4 Answers   CybAge,


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

0 Answers  






input values to accept 2 numbers & print the product, difference and sum using switch case

1 Answers   CSC,


A folder is there inside no of textfiles are avilable. How do count the textfiles. Normally folder means we are using subfolder methods but textfiles is not working for subfolder methods and how do get file name also.

0 Answers  


Explain about tristate constants in vbscript?

0 Answers  


When to use function procedures and what are its characteristics?

0 Answers  


accept an email id & validate it .email id should not exceed 25 characters the mail id should contain 3 characters excluding domain name,@ and .(dot) the last 3 characters of the domain should be net,com or org

2 Answers  


Difference between dim,public and private variables in vb script?

0 Answers  


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

0 Answers  


Categories