On 11 June 2010 16:07, Walter Lee Davis <wa...@wdstudio.com> wrote:
> One question though -- is there only ever one $('requestVehicle') in the
> page? If you use the ID method to call an object like this, you are making
> that contract with the browser -- only one thing will ever match that
> selector.
>
> If there are many such, then don't give them IDs, or be sure to give them
> unique IDs, and then use a 'relative' lookup like maybe
>
> $('vsContainer').down('input.someClass').focus();
>
> As long as it's inside an anonymous function, that selector won't fire until
> the outer function is called, so it will be correctly populated (since
> you're in afterFinish and you know the div has been made visible).
>
> Walter
>
> On Jun 10, 2010, at 5:07 PM, Gregory Nicholas wrote:
>
>> it should be as follows:
>>
>> new Effect.Parallel(    [
>>       new Effect.Appear('banner',      {duration : 1.00, delay :
>> 0.50}),
>>       new Effect.Appear('vsContainer', {duration : 2.00, delay :
>> 0.50})
>>       ],
>>       {
>>               sync: true,
>>               afterFinish: function() {
>>                       $('requestVehicle').focus();
>>               }
>>       }
>> );
>>
>> --
>> You received this message because you are subscribed to the Google Groups
>> "Prototype & script.aculo.us" group.
>> To post to this group, send email to
>> prototype-scriptacul...@googlegroups.com.
>> To unsubscribe from this group, send email to
>> prototype-scriptaculous+unsubscr...@googlegroups.com.
>> For more options, visit this group at
>> http://groups.google.com/group/prototype-scriptaculous?hl=en.
>>
>
> --
> You received this message because you are subscribed to the Google Groups
> "Prototype & script.aculo.us" group.
> To post to this group, send email to
> prototype-scriptacul...@googlegroups.com.
> To unsubscribe from this group, send email to
> prototype-scriptaculous+unsubscr...@googlegroups.com.
> For more options, visit this group at
> http://groups.google.com/group/prototype-scriptaculous?hl=en.
>
>

The afterFinish is what I needed. Thanks.

The form in question has 2 inputs and it is the first one that I want
to get the focus on.

Thank you.

I didn't see anything in the scripy docs, but I've probably missed it.
-- 
-----
Richard Quadling
"Standing on the shoulders of some very clever giants!"
EE : http://www.experts-exchange.com/M_248814.html
EE4Free : http://www.experts-exchange.com/becomeAnExpert.jsp
Zend Certified Engineer : http://zend.com/zce.php?c=ZEND002498&r=213474731
ZOPA : http://uk.zopa.com/member/RQuadling

-- 
You received this message because you are subscribed to the Google Groups 
"Prototype & script.aculo.us" group.
To post to this group, send email to prototype-scriptacul...@googlegroups.com.
To unsubscribe from this group, send email to 
prototype-scriptaculous+unsubscr...@googlegroups.com.
For more options, visit this group at 
http://groups.google.com/group/prototype-scriptaculous?hl=en.

Reply via email to