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

getFocus - where is the mistake

 
Post new topic   Reply to topic    OOoForum.org Forum Index -> OpenOffice.org Macros and API
View previous topic :: View next topic  
Author Message
flex
OOo Enthusiast
OOo Enthusiast


Joined: 06 Jul 2004
Posts: 122
Location: Vienna | Austria

PostPosted: Tue Jul 06, 2004 11:40 pm    Post subject: getFocus - where is the mistake Reply with quote

I want the TextBox 'txtpassword' to get the Focus, but it does not work.
why?

Dim ochkpassword as Object
Dim otxtpassword as Object

ochkpassword = odlgoptions.getControl("chkpassword")
otxtpassword = odlgoptions.getControl("txtpassword")

If ochkpassword.State = 1 then
otxtpassword.Model.Enabled = True
otxtpassword.getFocus() 'this line does not work!
else
otxtpassword.Model.Enabled = False
end if
Back to top
View user's profile Send private message
verflixtnix
Power User
Power User


Joined: 11 May 2004
Posts: 79
Location: Germany, Hamburg

PostPosted: Wed Jul 07, 2004 12:45 am    Post subject: Reply with quote

Am I'm right, that you want to set the focus?

otxtpassword.setFocus()
_________________
Jan Lüdtke

SuseLinux9.0 - OOo1.1.2 / Win2000 - OOo1.1.2
Back to top
View user's profile Send private message
flex
OOo Enthusiast
OOo Enthusiast


Joined: 06 Jul 2004
Posts: 122
Location: Vienna | Austria

PostPosted: Wed Jul 07, 2004 12:48 am    Post subject: Reply with quote

yeah, now it works.

otxtpassword.setFocus()
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