Home All Groups Group Topic Archive Search About
Author
9 Nov 2007 7:19 PM
Bert van den Dongen
Hi All.

This week I ran into a very strange thing.
I used my laptop with a customer of mine to make sure
that in a certain form the focus would be in the first textbox,
so I set the TabStop to True and the TabIndex to 0.
Tried it (in the IDE) and concluded it was OK.

So I compiled the app and saved it to the LAN.
The customer loaded the app and noticed that the
specific form did NOT start with the focus in that textbox.
I loaded the app from the LAN into the laptop and the form
had indeed the focus in the first textbox, as programmed.

My laptop and the workstations of my customer all have XP.

In the evening I transfered the source to my (Vista) PC and
checked again. No problem, focus in the first textbox.

Then I sent the source to my programming partner by email.
He ran the program in his (Vista) PC and he also noted that
the focus was NOT in the first textbox...(like my customer).

Has anyone an idea why some PC's behave differently regarding
the first focus in a form?

Bert.

Author
12 Nov 2007 8:56 AM
Jan Hyde (VB MVP)
"Bert van den Dongen" <bert***@tiscali.nl>'s wild thoughts
were released on Fri, 9 Nov 2007 20:19:14 +0100 bearing the
following fruit:

Show quote
>Hi All.
>
>This week I ran into a very strange thing.
>I used my laptop with a customer of mine to make sure
>that in a certain form the focus would be in the first textbox,
>so I set the TabStop to True and the TabIndex to 0.
>Tried it (in the IDE) and concluded it was OK.
>
>So I compiled the app and saved it to the LAN.
>The customer loaded the app and noticed that the
>specific form did NOT start with the focus in that textbox.
>I loaded the app from the LAN into the laptop and the form
>had indeed the focus in the first textbox, as programmed.
>
>My laptop and the workstations of my customer all have XP.
>
>In the evening I transfered the source to my (Vista) PC and
>checked again. No problem, focus in the first textbox.
>
>Then I sent the source to my programming partner by email.
>He ran the program in his (Vista) PC and he also noted that
>the focus was NOT in the first textbox...(like my customer).
>
>Has anyone an idea why some PC's behave differently regarding
>the first focus in a form?

Are you sure they are copying the file to correct location
AND running that version?

If you are, are they looking at the SAME screen you are?

Setting the tabindex (assuming no code to interfere) should
work absolutely fine.


--
Jan Hyde

https://mvp.support.microsoft.com/profile/Jan.Hyde
Author
12 Nov 2007 7:55 PM
Bert van den Dongen
Hi Jan,

>>Has anyone an idea why some PC's behave differently regarding
>>the first focus in a form?


> Are you sure they are copying the file to correct location
> AND running that version?
Yes, definitely. (I am the one who does the copying.)

> If you are, are they looking at the SAME screen you are?
Well, not the same 'physical' screen, I look at my notebook
and they look at their PC's screen, but surely at the same app
and the same form.

> Setting the tabindex (assuming no code to interfere) should
> work absolutely fine.
I did resolve it by using SetFocus in the Form_Activate, but it
still bugs me why on some PCs just setting TabStop at True
and TabIndex at 0 works fine, while not on others.
Problem solved but still puzzled.

Thanks, Jan.
Bert.

Show quote
>
> --
> Jan Hyde
>
> https://mvp.support.microsoft.com/profile/Jan.Hyde
Author
13 Nov 2007 11:56 AM
Jan Hyde (VB MVP)
"Bert van den Dongen" <bert***@tiscali.nl>'s wild thoughts
were released on Mon, 12 Nov 2007 20:55:56 +0100 bearing the
following fruit:

Show quote
>Hi Jan,
>
>>>Has anyone an idea why some PC's behave differently regarding
>>>the first focus in a form?
>
>
>> Are you sure they are copying the file to correct location
>> AND running that version?
>Yes, definitely. (I am the one who does the copying.)
>
>> If you are, are they looking at the SAME screen you are?
>Well, not the same 'physical' screen, I look at my notebook
>and they look at their PC's screen, but surely at the same app
>and the same form.
>
>> Setting the tabindex (assuming no code to interfere) should
>> work absolutely fine.
>I did resolve it by using SetFocus in the Form_Activate, but it
>still bugs me why on some PCs just setting TabStop at True
>and TabIndex at 0 works fine, while not on others.
>Problem solved but still puzzled.

I would feel uneasy about that and I would definietly want
to get to the bottom of the problem.

If you can reproduce this in a brand new project then
perhaps you'll send it to me so I can investigate for my own
piece of mind.


--
Jan Hyde

https://mvp.support.microsoft.com/profile/Jan.Hyde
Author
13 Nov 2007 4:59 PM
Bert van den Dongen
> I would feel uneasy about that and I would definietly want
> to get to the bottom of the problem.
So do I, Jan.

> If you can reproduce this in a brand new project then
> perhaps you'll send it to me so I can investigate for my own
> piece of mind.
That's the hard part.
I could try doing that (and will, be it not today), but then
I still don't know if it works on your PC or not.
I'll repost as soon as I've setup something.
Might even take a week...
Bert.

Show quote
> --
> Jan Hyde
>
> https://mvp.support.microsoft.com/profile/Jan.Hyde
Author
13 Nov 2007 5:08 PM
Jan Hyde (VB MVP)
"Bert van den Dongen" <bert***@tiscali.nl>'s wild thoughts
were released on Tue, 13 Nov 2007 17:59:13 +0100 bearing the
following fruit:

Show quote
>
>> I would feel uneasy about that and I would definietly want
>> to get to the bottom of the problem.
>So do I, Jan.
>
>> If you can reproduce this in a brand new project then
>> perhaps you'll send it to me so I can investigate for my own
>> piece of mind.
>That's the hard part.
>I could try doing that (and will, be it not today), but then
>I still don't know if it works on your PC or not.
>I'll repost as soon as I've setup something.
>Might even take a week...
>Bert.

No rush.

J

Show quote
>> --
>> Jan Hyde
>>
>> https://mvp.support.microsoft.com/profile/Jan.Hyde

--
Jan Hyde

https://mvp.support.microsoft.com/profile/Jan.Hyde
Author
29 Nov 2007 10:41 AM
Bert van den Dongen
Sorry Jan,

I promised to set up a situation in which one PC
behaves differently from another one with respect to
setting the focus to the control with TabIndex = 0.
But I still haven't found the time.

Moreover it is quite a job because I must test it
on different PCs. I'm afraid I cannot keep my
promis.
I apologize for that, but thank you for your
interest and responses.
Bert.
Author
29 Nov 2007 11:25 AM
Jan Hyde (VB MVP)
"Bert van den Dongen" <bert***@tiscali.nl>'s wild thoughts
were released on Thu, 29 Nov 2007 11:41:13 +0100 bearing the
following fruit:

>Sorry Jan,
>
>I promised to set up a situation in which one PC
>behaves differently from another one with respect to
>setting the focus to the control with TabIndex = 0.
>But I still haven't found the time.
>
>Moreover it is quite a job because I must test it
>on different PCs. I'm afraid I cannot keep my
>promis.
>I apologize for that, but thank you for your
>interest and responses.
>Bert.

No problem.
--
Jan Hyde

https://mvp.support.microsoft.com/profile/Jan.Hyde

AddThis Social Bookmark Button