Can you write a script for to insert array elements in an
excel A to Z columns only. if the number oe elements in the
array is greater than the number of columns (A to Z), come
to next row and proceed furthur. eah cell should contain
only one array value.
Answer / dwarapudi.mca
Dim arr
n=inputbox("Enter Array size")
ReDim arr(n)
For i=0 to n
arr(i)=cint("1")+Cint(i)
Next
Set Excl=CreateObject("Excel.Application")
Excl.workbooks.open("C:\Ex.xlsx")
Set ExclSht=Excl.Sheets.Item("Sheet1")
LOP=int((Ubound(arr)/cint(26))+1)
For i=0 to LOP
For j=0 to 25
If (j+k)<=ubound(arr) Then
ExclSht.cells(i+1,j+1)=arr(j+k)
else
Exit for
End If
Next
k=k+j
Next
Set ExclSht=nothing
Set Excl=nothing
Please let me know if u have simplest answer than this.
Thx
Is This Answer Correct ? | 1 Yes | 0 No |
Hoe to generate all numbers in between to numbers suppose all numbers in between 1 to 100 using vbscript give me code
what is the long form of QTP ?
What is the main difference between QTP 8.0& QTP 9.2.And what r the features and benefits of QTP.
How to swap two numbers by using parameter passing method byref in a fucntion and return the result to outside of the function?
what is Synchronization point in QTP?Can anybody give a perfect example on it Thanks in advance
How do we count the no of mails in Yahoo Inbox for a specified week?
How qtp recognizes the object?
write code to read and write data from file?
Can we do Load Teting with QTP?
What is the Maximum syncronization timeout in seconds in QTP 9.5
If already everything is tested using White-Box testing, then what is the need of using Black box testing?
I want to learn Advanced QTP, suggest me the best faculty in Hyderabad