How can I format an Excel spreadsheet with Notes? |
 |
EXPERT RESPONSE FROM: Andre Guirard

|
 |
|


|
| > |
QUESTION POSED ON: 13 May 2003
I want to send information to an Excel spreadsheet. That works fine, but I would also like to be able to format the spreadsheet. Specifically, how do I tell it to center the text in a column? In Excel, a macro creates these lines:
With Selection
.HorizontalAlignment = xlCenter
.VerticalAlignment = xlBottom
end With
But Notes doesn't understand xlCenter and xlBottom, so what codes am I supposed to use?
|
|
|
To continue reading for free, register below or login
To read more you must become a member of SearchDomino.com
');
// -->

These are numeric constants defined in Excel VB, but not in LotusScript. To discover their values, create an Excel macro that displays them in a MsgBox:
Sub snoopy()
MsgBox "xlCenter = " & xlCenter
& ", xlBottom = " & xlBottom
End Sub
For me, this generates the following output:
xlCenter = -4108,
xlBottom = -4107
Now you can make your LotusScript code contain those same constants by adding the following statements in your Declarations section:
Const xlCenter = -4108
Const xlBottom = -4107
(You could just use the numbers in your code instead of constant names, but the constants make your code more readable).
|
|
|

|
|
 |

 |
 |
Search and Browse the Expert Answer Center
Search and browse more than 25,000 question and
answer pairs from more than 250 TechTarget industry experts.
|
 |
 |
 |
|
 |
 |
 |
|
 |
|
 |