plz give ans to this in vb script........

"krishna radha"
i want to print this string
"Radha Krishna" like this

Answers were Sorted based on User's Feedback



plz give ans to this in vb script........ "krishna radha" i want to print this string ..

Answer / ddpras

str="krishna radha"
A=Split(str," ")
Fstring=A(0)
Lstring=A(1)
sLString=replace(Lstring,"r","R")
sFString=replace(Fstring,"k","K")
Rstring=sLString&" "&sFString
MsgBox Rstring

The above VB Script is exact ans for this question.

Is This Answer Correct ?    21 Yes 0 No

plz give ans to this in vb script........ "krishna radha" i want to print this string ..

Answer / lak

str="krishna radha"

a=left(str,7)
c=Replace(a,"k","K")
b=right(str,5)
d=Replace(b,"r","R")


msgbox d&" "&c

Is This Answer Correct ?    1 Yes 0 No

plz give ans to this in vb script........ "krishna radha" i want to print this string ..

Answer / prathyusha

s="krishna radha"
words=split(s)
For i = 0 To ubound(words)
arr=words(i)
fword= left(ucase(arr),1)
lword=right(lcase(arr),len(arr)-1)
word=fword&lword
str=word&" "&str
Next
msgbox str

Is This Answer Correct ?    0 Yes 0 No

plz give ans to this in vb script........ "krishna radha" i want to print this string ..

Answer / chinna

hello friend u carefully see the question first ok
i need to print first letter capital letter for every word
ok

Is This Answer Correct ?    1 Yes 2 No

plz give ans to this in vb script........ "krishna radha" i want to print this string ..

Answer / amit joshi

Dim str

str = "Radha Krishna"

Msgbox (str)

Is This Answer Correct ?    2 Yes 21 No

Post New Answer

More VB Script Interview Questions

Explain the constants in vbscript?

0 Answers  


Write a program to resize an array of 5 elements to 4 elements and display all the elements.

1 Answers  


What if you do not specify anything when you call a procedure?

0 Answers  


Why is the use of exit do or exit for statements within loops discouraged?

0 Answers  


Why is it recommended to close the database connection every time after the work is completed?

0 Answers  






I'm new to QTP, i facing a a problem in the script says"Object not found", "Browser("").page("").frame(Name:=fminfo).webtable(). the issue is, QTp is not able to identify the web table in run time.becuase in that fram"fminfo" there are "n"table and the table do not have the names,Html id. 1) i need to count the number webtables available on that page. 2)need to identify the webtable cell values. 3)How Loop the once i get the count and retrive the cell data of each webtable? Can anyone help on this, plz.. Thanks, Suresh

3 Answers  


What is the difference between javascript and vbscript?

0 Answers  


How to generate 3 digit random number?

3 Answers   IBM, Virtusa,


What is Querystring collection?

0 Answers  


Which respective symbols are used to separate a line and to break the lengthy statement into multiple statements in the vbscript language?

0 Answers  


Which data type/types are supported by vbscript language and what are their specialties?

0 Answers  


How to remove the spaces in a string Ex: "this is apple"

5 Answers   Cap Gemini,


Categories