I finally worked this out. Been driving me nuts!

        function sessionEdit() {
                ColdFusion.Window.create('sessionWin', 'Sessions',
'SessionsEdit.cfm?mode=edit&sessionId='+sessionId,
{x:250,y:200,width:450,height:180,resizable:false,modal:true});
        
ColdFusion.navigate('SessionsEdit.cfm?mode=edit&sessionId='+sessionId,
'sessionWin', sessionWinLoaded);
                ColdFusion.Window.onHide('sessionWin', sessionSuccess);    }
        
        function sessionWinLoaded() {
                document.forms['frmSessionEdit']['name'].select();
        }

Note, the navigate function takes a success function, and on success I can
focus to the element in the form by referencing it by name.

I have no idea why the onload in <cfform doesnt fire, even when not in a
CFWINDOW.

Regards
Dale Fraser

http://learncf.com

-----Original Message-----
From: Dale Fraser [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, 17 October 2007 8:41 AM
To: CF-Talk
Subject: CFWINDOW Input Focus

I'm having trouble trying to focus to a form field that is contained in a
CFWINDOW.

 

Is there a trick to this. I've tried lots of combos with no luck

 

Regards

Dale Fraser

 

http://learncf.com

 





~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Enterprise web applications, build robust, secure 
scalable apps today - Try it now ColdFusion Today
ColdFusion 8 beta - Build next generation apps

Archive: 
http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:291299
Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

Reply via email to