Type: info
         Title: LoadComponentFromURL now allows to specify templates for new 
documents
     Posted by: [email protected]
      Affected: -,-
         TaskId: i82287
<http://www.openoffice.org/issues/show_bug.cgi?id=82287>
Effective from: DEV300m60


*Summary*
--------
LoadComponentFromURL now allows to specify templates for new documents

*Description*
-------------
Until now a template could be used only by its file name, but not by
the logical names we have in the template component. The documentation
of the MediaDescriptor in the DevGuide mentioned two properties called
"TemplateName" and "TemplateRegionName", but they never workrd. Now it
is possible to create a new document from a template using these
properties. Example in Basic:

Sub createNewDoc
    Dim md(2) as New com.sun.star.beans.PropertyValue
    md(0).Name="TemplateName"
    md(0).Value="some_template"
    md(1).Name="TemplateRegionName"
    md(1).Value="My Templates"
    md(2).Name="AsTemplate"
    md(2).Value=TRUE
   
StarDesktop.loadComponentFromURL("private:factory/swriter","_blank",0,md)
End Sub




Send feedback to [email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to