Syntax
| vValue = XLS.Value(Row, Col)
| ||||||
---|---|---|---|---|---|---|---|
Description
| This property can be read from and written to as well.
When assigning a new value to the cell, the current formatting of that cell remains. To alter the formatting of the cell or if explicit value conditions need to be set (like enforcing the value to be interpreted as plain text), use SetValue instead.
Formatting can also take place afterwards, using SelectRange.
Please take notice that the rows and colums are one-based arrays. Therefore, when referring to Excel cell "A1", row and column numbers are 1 and 1.
| ||||||
See Also
| |||||||
Example
| Sub Main
Dim x As Integer
If Not XLS.AppInit() Then Exit Sub
XLS.AppVisible = True
XLS.AddWorkBook
XLS.AddWorkSheet "Test1"
XLS.MergeCells 3, 1, 6, 1
For x = 1 To 10
XLS.Value(x, 1) = "Waarde " & CStr(x)
Next x
For x = 1 To 10
Debug.Print XLS.Value(x, 1)
Next x
XLS.AppClose
End Sub
|