write a vb script to open a text file and write into it
Answer Posted / sojan davis- infosys
Const ForWriting = 2,
Dim fso, fileObj
Set fso = CreateObject("Scripting.FileSystemObject")
Set fileObj = fso.OpenTextFile(strConfigFile, ForWriting,
True)
fileObj.WriteLine("Hi")
fileObj.Close
Set fileObj=Nothing
Set fso=Nothing
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
Explain about vb script?
When to use function procedures and what are its characteristics?
write any ttest cases using check points and parameterization
Which date function is used in the vbscript language to find the difference between the 2 dates?
How strcomp function works?
Is vbscript language a case-sensitive language and what does it mean?
How to create a cookie using vbscript?
Which function is used in the vbscript language to convert the specified expression into a date type value?
What is byref and byval parameters in vbscript?
what is the difference between modular and data and keyword driven framework
Hi this is Vinoth. I need a help on below mentioned question A combobox contains list of items assume as 5 I have to get each items Individually and I have to Export to datatable. Please help me on this. Thanks
What is the difference between vb debugger and the script debugger?
How will you get the octal value of the given number in vbscript?
Set srchobj=Description.Create() srchobj("type").value="text" srchobj("name").value="q" srchobj("html tag").value="input" browser("micclass:=google").Page("micclass:=google").webedit (srchobj).Set "qtp" what's wrong in my code pls tell me ? the above code working fine and i got my result pass,now i am trying to run the program it shows general run time error why?pls help me i am in learning stage ?
How will you check that a variable is an array in vbscript?