dbTalk Databases Forums  

Changing Focus on New Record

comp.database.ms-access comp.database.ms-access


Discuss Changing Focus on New Record in the comp.database.ms-access forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Jonathan Upright
 
Posts: n/a

Default Changing Focus on New Record - 10-08-2003 , 08:43 PM






I need to know how to make a particular textbox in a form have the Focus
when I click the > button to start entering a new record.

As it stands now, whatever textbox I end up on maintains the focus when I
click the > button to start a new record.

The name of the textbox I want to get the Focus is "TicketNumber", (no
quotes, of course) just in case you'd like to know...

I found out that the VB equivalent, TicketNumber.SetFocus does not work. I
know a decent amount of VB, but I don't know a whole lot about Access and
how to make correct usage of VB in it. I will happily provide a copy of the
database file upon request if necessary.

Thanx for any help in advance!


Jonathan




Reply With Quote
  #2  
Old   
Bradley
 
Posts: n/a

Default Re: Changing Focus on New Record - 10-08-2003 , 10:34 PM






"Jonathan Upright" <qaesar1 (AT) hotmail (DOT) com> wrote

Quote:
I need to know how to make a particular textbox in a form have the Focus
when I click the > button to start entering a new record.

As it stands now, whatever textbox I end up on maintains the focus when I
click the > button to start a new record.

The name of the textbox I want to get the Focus is "TicketNumber", (no
quotes, of course) just in case you'd like to know...

I found out that the VB equivalent, TicketNumber.SetFocus does not work.
I
know a decent amount of VB, but I don't know a whole lot about Access and
how to make correct usage of VB in it. I will happily provide a copy of
the
database file upon request if necessary.

Thanx for any help in advance!


Jonathan
When are you running the Setfocus method?

If you run it on the OnCurrent event it should work.

Else, perhaps create your own New Record button
--
Bradley
Software Developer www.hrsystems.com.au
A Christian Response www.pastornet.net.au/response




Reply With Quote
  #3  
Old   
Jonathan Upright
 
Posts: n/a

Default Re: Changing Focus on New Record - 10-12-2003 , 08:08 PM



I used the OnCurrent event; that worked, thanx!! :-) However, do you (or
anyone) know why Access XP crashes when I edit code? When I typed the
period after the control name to bring up the little list of properties and
methods (so I could select SetFocus) Access would crash; before the period
or list appeared. I had to reboot into Windows 98SE and use Access 2000 to
add the code. (I have 2 partitions on my HD) After that, I ran the file
again in Access XP and it worked fine. Just something weird with
code-editing. No problem executing already-written code. Any ideas? I am
running WinXP Pro with Office XP Enterprise, all updates installed as of
10/12/2003.

Jonathan

"Bradley" <bradley (AT) REMOVETHIScomcen (DOT) com.au> wrote

Quote:
"Jonathan Upright" <qaesar1 (AT) hotmail (DOT) com> wrote in message
news:q33hb.41330$5r1.22463 (AT) twister (DOT) southeast.rr.com...
I need to know how to make a particular textbox in a form have the Focus
when I click the > button to start entering a new record.

As it stands now, whatever textbox I end up on maintains the focus when
I
click the > button to start a new record.

The name of the textbox I want to get the Focus is "TicketNumber", (no
quotes, of course) just in case you'd like to know...

I found out that the VB equivalent, TicketNumber.SetFocus does not work.
I
know a decent amount of VB, but I don't know a whole lot about Access
and
how to make correct usage of VB in it. I will happily provide a copy of
the
database file upon request if necessary.

Thanx for any help in advance!


Jonathan

When are you running the Setfocus method?

If you run it on the OnCurrent event it should work.

Else, perhaps create your own New Record button
--
Bradley
Software Developer www.hrsystems.com.au
A Christian Response www.pastornet.net.au/response





Reply With Quote
  #4  
Old   
Bradley
 
Posts: n/a

Default Re: Changing Focus on New Record - 10-13-2003 , 06:56 PM



Sorry, no idea... very strange. Probably something is corrupted.

My A2000 help no longer works even after doing a repair install... there's
always something!
--
Bradley
Software Developer www.hrsystems.com.au
A Christian Response www.pastornet.net.au/response

"Jonathan Upright" <qaesar1 (AT) hotmail (DOT) com> wrote

Quote:
I used the OnCurrent event; that worked, thanx!! :-) However, do you (or
anyone) know why Access XP crashes when I edit code? When I typed the
period after the control name to bring up the little list of properties
and
methods (so I could select SetFocus) Access would crash; before the period
or list appeared. I had to reboot into Windows 98SE and use Access 2000
to
add the code. (I have 2 partitions on my HD) After that, I ran the file
again in Access XP and it worked fine. Just something weird with
code-editing. No problem executing already-written code. Any ideas? I
am
running WinXP Pro with Office XP Enterprise, all updates installed as of
10/12/2003.

Jonathan

"Bradley" <bradley (AT) REMOVETHIScomcen (DOT) com.au> wrote in message
news:5H4hb.142494$bo1.134862 (AT) news-server (DOT) bigpond.net.au...
"Jonathan Upright" <qaesar1 (AT) hotmail (DOT) com> wrote in message
news:q33hb.41330$5r1.22463 (AT) twister (DOT) southeast.rr.com...
I need to know how to make a particular textbox in a form have the
Focus
when I click the > button to start entering a new record.

As it stands now, whatever textbox I end up on maintains the focus
when
I
click the > button to start a new record.

The name of the textbox I want to get the Focus is "TicketNumber", (no
quotes, of course) just in case you'd like to know...

I found out that the VB equivalent, TicketNumber.SetFocus does not
work.
I
know a decent amount of VB, but I don't know a whole lot about Access
and
how to make correct usage of VB in it. I will happily provide a copy
of
the
database file upon request if necessary.

Thanx for any help in advance!


Jonathan

When are you running the Setfocus method?

If you run it on the OnCurrent event it should work.

Else, perhaps create your own New Record button
--
Bradley
Software Developer www.hrsystems.com.au
A Christian Response www.pastornet.net.au/response







Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.