Follow Our FB Page << CircleMedia.in >> for Daily Laughter. We Post Funny, Viral, Comedy Videos, Memes, Vines...


I have string like hp company.print tis like company hp.write a program in vbscripting



I have string like hp company.print tis like company hp.write a program in vbscripting ..

Answer / jp mumbai

Hi,

We can write a code in 2 ways. one is Generic Code and another is Hard Code.

In Generic Code:

Str="hp company"
ArrayStr=Split(Str)

For i = uBound(ArrayStr) to 0 Step-1
expStr=expStr &" "& ArrayStr(i)
Next

msgbox expStr

-------------------------------------------------

In Hard Code:

Str="hp company"
ArrayStr=Split(Str)

expStr= ArrayStr(1)&" "&ArrayStr(0)

msgbox expStr

Is This Answer Correct ?    2 Yes 0 No

Post New Answer

More VB Script Interview Questions

Why do we use Option Explicit?

6 Answers  


How will you compare two strings in vbscript?

0 Answers  


filter the array values without using filter function?

0 Answers   CSS Corp, WQED,


Capture the Unique label changes on google home page for I am feeling lucky button and save those label changes to Notepad Note: Using QTP

0 Answers   Quest,


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  






print the array values in ascending order?

2 Answers   CSS Corp,


what is the use of Data base check point ?

3 Answers  


What aspects of vbscript make it safe so that a web page using vbscript cannot destroy or corrupt information on a user's computer?

0 Answers  


I want to import the sheet from the Excel to the Datatable using VB Script. I used the Syntax as 'Datatable.ImportSheet "Filename","SourceSheet","Destinat ionSheet" Ex: Datatable.ImportSheet "D:\Data1.xls","Sheet1","Global" Qtp producing run time error,How I can solve the problem

1 Answers  


Explain about scrrun.dll?

0 Answers  


How to get 120 using 5 zeroes, you can use any operator(+, *, /...) in qtp.

2 Answers   Cognizant,


In what way program "hello world" you can write in vbscript?

0 Answers  






Categories