OpenOffice.org Forum at OOoForum.orgThe OpenOffice.org Forum
 
 [Home]   [FAQ]   [Search]   [Memberlist]   [Usergroups]   [Register
 [Profile]   [Log in to check your private messages]   [Log in

how to close input textfields dialogs?

 
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Macros and API
View previous topic :: View next topic  
Author Message
paulag
General User
General User


Joined: 25 Aug 2004
Posts: 6

PostPosted: Thu Sep 09, 2004 4:38 am    Post subject: how to close input textfields dialogs? Reply with quote

Hi!

My problem: I have one office template (.dot) with formfields. I open it from OpenOffice with one macro doing:

Url = "file:///c:/MyFile.Dot"
Doc = StarDesktop.loadComponentFromURL(Url, "_blank", 0, Dummy())

and I access to the content of the input textfields (it seems that my original formfileds are now input text fields... ok, no problem for me) with:

EnumCamposTexto = Doc.getTextFields.createEnumeration
While EnumCamposTexto.hasMoreElements()
CampoTexto = EnumCamposTexto.nextElement()
If CampoTexto.supportsService("com.sun.star.text.TextField.Input") Then
CampoTexto.Content ="hola"
End If
Wend
Doc.getTextFields().refresh()

And that woks fine... My problem is that when I open the document, it displays the input text dialog asking for the content. How can I close it from the macro? Or can I do anything for not let it open?

Sorry for my english (...I'm spanish, yes)

Paulaq
Back to top
View user's profile Send private message
paulag
General User
General User


Joined: 25 Aug 2004
Posts: 6

PostPosted: Tue Sep 14, 2004 12:57 am    Post subject: Reply with quote

I finally did it with:

Doc = StarDesktop.loadComponentFromURL(Url, "_blank", 0, NoArgs())
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Macros and API All times are GMT - 8 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group