Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Vivek Deodhar
  Where is Vivek Deodhar?
 SANGLI
 India
 Vivek Deodhar
 Tags
Subject: Open Office Properties
Thread ID: 289133 Message ID: 289133 # Views: 68 # Ratings: 4
Version: Visual FoxPro 9 SP2 Category: Microsoft Office Automation
Date: Tuesday, December 28, 2010 3:51:32 PM         
   


Hi,

I got to know today some properties which can be easily applied to open office documents while automating. Since it is somewhat harder to use automation with Oo, I am giving it hereunder.
Since some other members are also using Oo in place of excel, this might come handy.

There are 28 properties, which have boolean value.

ColumnRowHeaders
GridColor
HasColumnRowHeaders
HasHorizontalScrollBar
HasSheetTabs
HasVerticalScrollBar
HideSpellMarks
HorizontalScrollBar
IsOutlineSymbolsSet
IsValueHighlightingEnabled
OutlineSymbols
SheetTabs
ShowAnchor
ShowCharts
ShowDrawing
ShowFormulas
ShowGrid
ShowHelpLines
ShowNotes
ShowObjects
ShowPageBreaks
ShowZeroValues
SolidHandles
ValueHighlighting
VerticalScrollBar
VisibleArea
ZoomType
ZoomValue


How to use:
**uses functions from libooo.prg
odoc = oooopenurl( "private:factory/scalc" )
ocalcctrl = odoc.getcurrentcontroller()
with ocalcctrl
   .setpropertyvalue( "HasSheetTabs",  .f. )
   .setpropertyvalue( "ShowGrid",  .f. )
   .setpropertyvalue( "showzerovalues",  .f. )
   .setpropertyvalue( "ColumnRowHeaders",  .f. )
   .setpropertyvalue( "hidespellmarks",  .t. )
endwith





How to use "getProperties()" to list these properties (given above)


odoc = oooopenurl( "private:factory/scalc" )
ocalcctrl = odoc.getcurrentcontroller()
with ocalcctrl
   ofg=.getPropertySetInfo()
   ohj=ofg.getProperties()

   for ln=1 to 28
      ?ohj(ln).name
   endfor
endwith



hth
Vivek

ENTIRE THREAD

Open Office Properties Posted by Vivek Deodhar @ 12/28/2010 3:51:32 PM
RE: Open Office Properties Posted by Bhavbhuti Nathwani @ 12/28/2010 5:28:55 PM
RE: Open Office Properties Posted by Yuri Rubinov @ 12/28/2010 7:52:29 PM
RE: Open Office Properties Posted by tushar @ 12/29/2010 5:48:19 AM
RE: Open Office Properties Posted by Cesar @ 12/30/2010 1:42:47 AM