| View previous topic :: View next topic |
| Author |
Message |
viaduct Newbie


Joined: 07 Jun 2005 Posts: 2
|
Posted: Tue Jun 07, 2005 7:19 am Post subject: Changing the HTML view style to Print Layout |
|
|
Hi all,
I'm using VBS to load an HTML file, and want to also get it to set the View style to Print Layout and can't find how to do it anywhere!
Any help gratefully received, total newbie going nuts here!
Thanks! |
|
| Back to top |
|
 |
ms777 Super User


Joined: 07 Feb 2004 Posts: 1355
|
Posted: Tue Jun 07, 2005 1:35 pm Post subject: |
|
|
Thats how it goes in BASIC ... | Code: | Sub Main
sUrl = ConvertToUrl("C:\Windows\Desktop\test.htm")
oDoc = StarDesktop.LoadComponentFromUrl(sUrl,"_default",0,Array())
oContr = oDoc.CurrentController
oContr.ViewSettings.setPropertyValue("ShowOnlineLayout", false)
End Sub |
For testing / learning the OO API I recommend the following:
- Always start with BASIC (because there you have XRay to examine the OO objects)
- install XRay
- install the SDK doc (XRay needs it to show info about the objects)
Links are given here http://www.oooforum.org/forum/viewtopic.phtml?p=80453#80453
Good luck ms777 |
|
| Back to top |
|
 |
viaduct Newbie


Joined: 07 Jun 2005 Posts: 2
|
Posted: Tue Jun 07, 2005 11:50 pm Post subject: |
|
|
Genius, spot on.
I find it hard to accept that something that was going to take pages and pages of C++ can be done in 4 lines of BASIC!
Thanks ms777! |
|
| Back to top |
|
 |
|