Re: qForms - How to maintain selections?

2007-06-11 Thread Will Tomlinson
Oops, here's the link:

http://208.106.220.252/soundings/T8Report.cfm

Thanks,
Will

~|
Macromedia ColdFusion MX7
Upgrade to MX7  experience time-saving features, more productivity.
http://www.adobe.com/products/coldfusion?sdid=RVJW

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


RE: qForms - How to maintain selections?

2007-06-11 Thread Dan G. Switzer, II
You're never calling the setDefault() function...

Call that after your objForm initialization code at the bottom of the script
or during the window.onload event.

-Dan

-Original Message-
From: Will Tomlinson [mailto:[EMAIL PROTECTED]
Sent: Monday, June 11, 2007 4:42 PM
To: CF-Talk
Subject: Re: qForms - How to maintain selections?

Oops, here's the link:

http://208.106.220.252/soundings/T8Report.cfm

Thanks,
Will



~|
Macromedia ColdFusion MX7
Upgrade to MX7  experience time-saving features, more productivity.
http://www.adobe.com/products/coldfusion?sdid=RVJW

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


RE: qForms - How to maintain selections?

2007-06-11 Thread Dan G. Switzer, II
You're never calling the setDefault() function...

Call that after your objForm initialization code at the bottom of the
script
or during the window.onload event.

Better yet, put it in the init() function.

FYI - Used Firebug to add the following HTML code right after the View
Report button:

input type=button onclick=setDefault() value=Defaults/

When I click that button, the defaults get set. Which further proves you're
never calling that code...

-Dan


~|
Create Web Applications With ColdFusion MX7  Flex 2. 
Build powerful, scalable RIAs. Free Trial
http://www.adobe.com/products/coldfusion/flex2/?sdid=RVJS 

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


Re: qForms - How to maintain selections?

2007-06-11 Thread Will Tomlinson

Better yet, put it in the init() function.

FYI - Used Firebug to add the following HTML code right after the View
Report button:

Thanks for helpin' me with this Dan. I'm trying to setDefault() in the init(). 
It still doesn't seem to work. I know I'm not doin' somethin' right here.

This is the end of my JS now:

function init(){
// initialize the qForm object
objForm = new qForm(evalfilterform);

// make these fields required
objForm.required(Tier7,Tier6,Tier5);
// this example shows how you could pre-populate the form

function setDefault(){
cfoutput
objForm.Tier7.setValue(#FORM.tier7#);
objForm.Tier6.setValue(#FORM.tier6#);
objForm.Tier5.setValue(#FORM.tier5#);
objForm.Tier4.setValue(#FORM.tier4#);
objForm.Tier3.setValue(#FORM.tier3#);
objForm.Tier2.setValue(#FORM.tier2#);
objForm.Tier1.setValue(#FORM.tier1#);
/cfoutput 
}


}
//--
/script
!--// [ end ] initialize all default extension libraries  //--


http://208.106.220.252/soundings/T8Report.cfm

Thanks much!

Will

~|
Macromedia ColdFusion MX7
Upgrade to MX7  experience time-saving features, more productivity.
http://www.adobe.com/products/coldfusion?sdid=RVJW

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


RE: qForms - How to maintain selections?

2007-06-11 Thread Dan G. Switzer, II
Will,

Move the function back to where it was and do this:

function init(){
// initialize the qForm object
objForm = new qForm(evalfilterform);

// make these fields required
objForm.required(Tier7,Tier6,Tier5);

// this example shows how you could pre-populate the form
setDefaults();
}

While you're defining the function, you're never actually *executing* the
function...

-Dan

-Original Message-
From: Will Tomlinson [mailto:[EMAIL PROTECTED]
Sent: Monday, June 11, 2007 5:54 PM
To: CF-Talk
Subject: Re: qForms - How to maintain selections?


Better yet, put it in the init() function.

FYI - Used Firebug to add the following HTML code right after the View
Report button:

Thanks for helpin' me with this Dan. I'm trying to setDefault() in the
init(). It still doesn't seem to work. I know I'm not doin' somethin' right
here.

This is the end of my JS now:

function init(){
   // initialize the qForm object
   objForm = new qForm(evalfilterform);

   // make these fields required
   objForm.required(Tier7,Tier6,Tier5);
   // this example shows how you could pre-populate the form

   function setDefault(){
   cfoutput
   objForm.Tier7.setValue(#FORM.tier7#);
   objForm.Tier6.setValue(#FORM.tier6#);
   objForm.Tier5.setValue(#FORM.tier5#);
   objForm.Tier4.setValue(#FORM.tier4#);
   objForm.Tier3.setValue(#FORM.tier3#);
   objForm.Tier2.setValue(#FORM.tier2#);
   objForm.Tier1.setValue(#FORM.tier1#);
   /cfoutput
   }


   }
//--
/script
!--// [ end ] initialize all default extension libraries  //--


http://208.106.220.252/soundings/T8Report.cfm

Thanks much!

Will



~|
Upgrade to Adobe ColdFusion MX7
The most significant release in over 10 years. Upgrade  see new features.
http://www.adobe.com/products/coldfusion?sdid=RVJR

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


Re: qForms - How to maintain selections?

2007-06-11 Thread Will Tomlinson
Dan,

I tried that, but it still wouldn't work. 

Here's what I did that seems to work. I was guessing that because you 
setDefault() in the init() code, the actual setDefault() hasn't run yet? And 
those variables aren't there to poulate the selects. 

So I stuck setDefault() in the code that executes after the form at the bottom. 
Heck, it's workin' now like that! 

script language=JavaScript
!--//

objForm = new qForm(evalFilterForm);
setDefault();

//--
/script

Thanks a ton for your help! I have friggin' 7 related dynamic selects that can 
be configured from the users admin area. All containing dynamic tiers of data. 

qForms rock!

Will

~|
ColdFusion MX7 by AdobeĀ®
Dyncamically transform webcontent into Adobe PDF with new ColdFusion MX7. 
Free Trial. http://www.adobe.com/products/coldfusion?sdid=RVJV

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


Re: qForms - How to maintain selections?

2007-06-11 Thread Will Tomlinson
Dan,

There is one little problem I'm having. I need there to be an All selection 
in each dropdown. If the first dropdown has All selected, the rest of the 
dropdowns should default to All. The problem is, if you make a few selections, 
submit the form, then try and set them back to All, there's no All in the 
data struct that'll set it. 

Even if I manually stick some options in there it won't add them to the sub 
selections.

Is this possible?

The only way I think I can do it is to actually put All in the table data. 
That's kinda tacky tho. 

Thanks much,
Will

~|
Deploy Web Applications Quickly across the enterprise with ColdFusion MX7  
Flex 2
Free Trial 
http://www.adobe.com/products/coldfusion/flex2/?sdid=RVJU

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