 | OO-Snippets: HelloWorldCommons| Keywords | |
|---|
| Language | ooRexx |
|---|
| Application | Calc |
|---|
| Authors | Michael Hinz (initial)
|
|---|
| Supported Versions | 2.0.x |
|---|
| Supported OS | Win32 |
|---|
| Question | Howcan I access a cell and set its value
|
|---|
| Answer | |
|---|
oDesktop = UNO.createDesktop()
xComponentLoader = oDesktop~XDesktop~XComponentLoader
url = "private:factory/scalc"
xCalcComponent = xComponentLoader~loadComponentFromURL(url, "_blank", 0, .UNO~noProps)
xDocument = xCalcComponent~XSpreadSheetDocument
xSheet = xDocument~getSheets~XIndexAccess~getByIndex(0)~XSpreadSheet
CALL UNO.setCell xSheet, 0, 0, "HelloWorld!"
::requires UNO.cls
|
|