CodeCharge Studio
search Register Login  

Visual Web Reporting

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> Archive -> CodeChargeStudio.Discussion

 CCS - Dependent Listboxes - Needed.

Print topic Send  topic

Author Message
BradS
Posted: 06/13/2002, 7:27 PM

One of the constant needs in our database work is dependent listbox
controls. It 's essential in at least 80% of Search forms and easily 50% of
record forms.

With the much awaited CCStudio, I'd expected this functionality to have been
provided, but alas, nothing found.
This is a serious lack folks, and it's REALLY disappointing.

There are snippets in the Tips area for CC2 that allow dependent listboxes
down to
4 levels, but nothing for CCstudio..
Is this functionality a possible/planned enhancement for CCS1.01?? Can some
Javascript/CCS guru provide a method for we lesser learners?

Sadly, CCstudio will not get much of a workout in this shop if this is not
built-in - it is just SO necessary.

What's the score folks?

.





Mr. Mike M.
Posted: 06/14/2002, 9:15 AM

Brad-

I just went through the same problem, but I gutted it out and found a
solution to my dependent problem. I'll contact you off-list.

-regards,
Mike M.

"BradS" <brads@onetech.com> wrote in message
news:aebkbb$d6v$1@news.codecharge.com...
> One of the constant needs in our database work is dependent listbox
> controls. It 's essential in at least 80% of Search forms and easily 50%
of
> record forms.
>
> With the much awaited CCStudio, I'd expected this functionality to have
been
> provided, but alas, nothing found.
> This is a serious lack folks, and it's REALLY disappointing.
>
> There are snippets in the Tips area for CC2 that allow dependent listboxes
> down to
> 4 levels, but nothing for CCstudio..
> Is this functionality a possible/planned enhancement for CCS1.01?? Can
some
> Javascript/CCS guru provide a method for we lesser learners?
>
> Sadly, CCstudio will not get much of a workout in this shop if this is not
> built-in - it is just SO necessary.
>
> What's the score folks?
>
> .
>
>
>
>
>
>



Robert Rodgers
Posted: 06/14/2002, 9:42 AM

Please share with everyone. I am looking for this information also.

Thanks.

--
Robert Rodgers
Robert@SylvanComputing.com
Ph: 509.531.4351
Fax: 503.961.0317
Text Message: mailto:5095314351@mobile.att.net
--


"Mr. Mike M." <vze23x2n@verizon.net> wrote in message
news:aed4rm$i5n$1@news.codecharge.com...
> Brad-
>
> I just went through the same problem, but I gutted it out and found a
> solution to my dependent problem. I'll contact you off-list.
>
> -regards,
> Mike M.
>
> "BradS" <brads@onetech.com> wrote in message
>news:aebkbb$d6v$1@news.codecharge.com...
> > One of the constant needs in our database work is dependent listbox
> > controls. It 's essential in at least 80% of Search forms and easily
50%
> of
> > record forms.
> >
> > With the much awaited CCStudio, I'd expected this functionality to have
> been
> > provided, but alas, nothing found.
> > This is a serious lack folks, and it's REALLY disappointing.
> >
> > There are snippets in the Tips area for CC2 that allow dependent
listboxes
> > down to
> > 4 levels, but nothing for CCstudio..
> > Is this functionality a possible/planned enhancement for CCS1.01?? Can
> some
> > Javascript/CCS guru provide a method for we lesser learners?
> >
> > Sadly, CCstudio will not get much of a workout in this shop if this is
not
> > built-in - it is just SO necessary.
> >
> > What's the score folks?
> >
> > .
> >
> >
> >
> >
> >
> >
>
>
>
>

Mr. Mike M.
Posted: 06/14/2002, 11:02 AM

OK - But this may get somewhat involved....
This is working with a combination of javascript and ASP.

Preliminary items: My database has 3 tables. the "list" table, a "class"
table to populate the first list box, and a "subclass" table to populate the
second listbox. The "id" field from the class and subclass tables are
related to fields in the list table. The subclass table has a field that
relates to the "class" table. That's so I know which subclass(es) goes with
each class.

Ideally, if I'm editing my record on the web page, I change the "class"
listbox, and the "subclass" listbox will update itself and only allow items
pertaining to what "class" has selected.

1. I made my record edit page in CCS, complete with all the fields I needed,
including my two dependent listboxes.
2. Next, I got this: http://www.aspfree.com/authors/salimn/optionex.asp
It is a tutorial on aspfree.com about doing dependent listboxes in
javascript. I copied the class library to the web server.
3. I needed to dynamically create and load the javascript array from my
database with the items that get changed in the second listbox depending on
what's selected in the first.
4. To accomplish #3, I created an ASP file that created the necessary
javascript on the fly.
< ... BEGIN ASP CODE>
<%
Sub LoadSelect()
dim rs
response.write "<script language=javascript src=""optionex.js""></script>
// load the optionex functions
response.write "<script language=javascript>"
response.write "<var SubClass = new optionCollection();" //
optionCollection from the optionex functions

set rs = server.createobject("adodb.recordset");
rs.open "Select * from your_subclass_table order by
your_subclass_text_field", "DSN=yourDSNconnection;"

while not rs.EOF
Response.write "SubClass.add(""" & rs("subclass_id_field") & """, """ &
rs("subclass_text_field") & """, """ & rs("class_id_field") & """)
rs.movenext
WEND
rs.close
response.write "<script>"
end sub
%>
</...end ASP CODE >

I called this file "LoadSelect.asp" and copied it to my webserver.

5. In CCS, I opened my record "Edit" (or Maint) form, and switched to the
"CODE" tab to edit the ASP code.
6. In the INCLUDE Common Files area, I added my LoadSelect.Asp include <!--
#INCLUDE FILE=".\loadselect.asp" -->
7. Switch to the HTML tab, locate the listbox control that., when changed,
will update the second listbox.
8. Add an "ONCHANGE" event to that listbox. Mine reads:
onchange="UpdateSelect('frm_subclass',
'Tickets',this.options[this.selectedIndex].value, SubClass);

The UpdateSelect function is from the optionex library noted above.
FRM_SUBCLASS is my second listbox that will be changed.

9. I think, that's it.






"Robert Rodgers" <Robert@SylvanComputing.com> wrote in message
news:aed6dj$l1a$1@news.codecharge.com...
> Please share with everyone. I am looking for this information also.
>
> Thanks.
>
> --
> Robert Rodgers
>Robert@SylvanComputing.com
> Ph: 509.531.4351
> Fax: 503.961.0317
> Text Message: mailto:5095314351@mobile.att.net
> --
>
>
> "Mr. Mike M." <vze23x2n@verizon.net> wrote in message
>news:aed4rm$i5n$1@news.codecharge.com...
> > Brad-
> >
> > I just went through the same problem, but I gutted it out and found a
> > solution to my dependent problem. I'll contact you off-list.
> >
> > -regards,
> > Mike M.
> >
> > "BradS" <brads@onetech.com> wrote in message
> >news:aebkbb$d6v$1@news.codecharge.com...
> > > One of the constant needs in our database work is dependent listbox
> > > controls. It 's essential in at least 80% of Search forms and easily
> 50%
> > of
> > > record forms.
> > >
> > > With the much awaited CCStudio, I'd expected this functionality to
have
> > been
> > > provided, but alas, nothing found.
> > > This is a serious lack folks, and it's REALLY disappointing.
> > >
> > > There are snippets in the Tips area for CC2 that allow dependent
> listboxes
> > > down to
> > > 4 levels, but nothing for CCstudio..
> > > Is this functionality a possible/planned enhancement for CCS1.01??
Can
> > some
> > > Javascript/CCS guru provide a method for we lesser learners?
> > >
> > > Sadly, CCstudio will not get much of a workout in this shop if this is
> not
> > > built-in - it is just SO necessary.
> > >
> > > What's the score folks?
> > >
> > > .
> > >
> > >
> > >
> > >
> > >
> > >
> >
> >
> >
> >
>
>

Robert Rodgers
Posted: 06/14/2002, 12:25 PM

Very nice. This should give me something to play with this weekend<g>

--
Robert Rodgers
Robert@SylvanComputing.com
Ph: 509.531.4351
Fax: 503.961.0317
Text Message: mailto:5095314351@mobile.att.net
--


"Mr. Mike M." <vze23x2n@verizon.net> wrote in message
news:aedb3c$21t$1@news.codecharge.com...
> OK - But this may get somewhat involved....
> This is working with a combination of javascript and ASP.
>
> Preliminary items: My database has 3 tables. the "list" table, a "class"
> table to populate the first list box, and a "subclass" table to populate
the
> second listbox. The "id" field from the class and subclass tables are
> related to fields in the list table. The subclass table has a field that
> relates to the "class" table. That's so I know which subclass(es) goes
with
> each class.
>
> Ideally, if I'm editing my record on the web page, I change the "class"
> listbox, and the "subclass" listbox will update itself and only allow
items
> pertaining to what "class" has selected.
>
> 1. I made my record edit page in CCS, complete with all the fields I
needed,
> including my two dependent listboxes.
> 2. Next, I got this: http://www.aspfree.com/authors/salimn/optionex.asp
> It is a tutorial on aspfree.com about doing dependent listboxes in
> javascript. I copied the class library to the web server.
> 3. I needed to dynamically create and load the javascript array from my
> database with the items that get changed in the second listbox depending
on
> what's selected in the first.
> 4. To accomplish #3, I created an ASP file that created the necessary
> javascript on the fly.
> < ... BEGIN ASP CODE>
> <%
> Sub LoadSelect()
> dim rs
> response.write "<script language=javascript src=""optionex.js""></script>
> // load the optionex functions
> response.write "<script language=javascript>"
> response.write "<var SubClass = new optionCollection();" //
> optionCollection from the optionex functions
>
> set rs = server.createobject("adodb.recordset");
> rs.open "Select * from your_subclass_table order by
> your_subclass_text_field", "DSN=yourDSNconnection;"
>
> while not rs.EOF
> Response.write "SubClass.add(""" & rs("subclass_id_field") & """, """ &
> rs("subclass_text_field") & """, """ & rs("class_id_field") & """)
> rs.movenext
> WEND
> rs.close
> response.write "<script>"
> end sub
> %>
> </...end ASP CODE >
>
> I called this file "LoadSelect.asp" and copied it to my webserver.
>
> 5. In CCS, I opened my record "Edit" (or Maint) form, and switched to the
> "CODE" tab to edit the ASP code.
> 6. In the INCLUDE Common Files area, I added my LoadSelect.Asp include
<!--
> #INCLUDE FILE=".\loadselect.asp" -->
> 7. Switch to the HTML tab, locate the listbox control that., when changed,
> will update the second listbox.
> 8. Add an "ONCHANGE" event to that listbox. Mine reads:
> onchange="UpdateSelect('frm_subclass',
> 'Tickets',this.options[this.selectedIndex].value, SubClass);
>
> The UpdateSelect function is from the optionex library noted above.
> FRM_SUBCLASS is my second listbox that will be changed.
>
> 9. I think, that's it.
>
>
>
>
>
>
> "Robert Rodgers" <Robert@SylvanComputing.com> wrote in message
>news:aed6dj$l1a$1@news.codecharge.com...
> > Please share with everyone. I am looking for this information also.
> >
> > Thanks.
> >
> > --
> > Robert Rodgers
> >Robert@SylvanComputing.com
> > Ph: 509.531.4351
> > Fax: 503.961.0317
> > Text Message: mailto:5095314351@mobile.att.net
> > --
> >
> >
> > "Mr. Mike M." <vze23x2n@verizon.net> wrote in message
> >news:aed4rm$i5n$1@news.codecharge.com...
> > > Brad-
> > >
> > > I just went through the same problem, but I gutted it out and found a
> > > solution to my dependent problem. I'll contact you off-list.
> > >
> > > -regards,
> > > Mike M.
> > >
> > > "BradS" <brads@onetech.com> wrote in message
> > >news:aebkbb$d6v$1@news.codecharge.com...
> > > > One of the constant needs in our database work is dependent listbox
> > > > controls. It 's essential in at least 80% of Search forms and
easily
> > 50%
> > > of
> > > > record forms.
> > > >
> > > > With the much awaited CCStudio, I'd expected this functionality to
> have
> > > been
> > > > provided, but alas, nothing found.
> > > > This is a serious lack folks, and it's REALLY disappointing.
> > > >
> > > > There are snippets in the Tips area for CC2 that allow dependent
> > listboxes
> > > > down to
> > > > 4 levels, but nothing for CCstudio..
> > > > Is this functionality a possible/planned enhancement for CCS1.01??
> Can
> > > some
> > > > Javascript/CCS guru provide a method for we lesser learners?
> > > >
> > > > Sadly, CCstudio will not get much of a workout in this shop if this
is
> > not
> > > > built-in - it is just SO necessary.
> > > >
> > > > What's the score folks?
> > > >
> > > > .
> > > >
> > > >
> > > >
> > > >
> > > >
> > > >
> > >
> > >
> > >
> > >
> >
> >
>
>

BradS
Posted: 06/16/2002, 11:45 PM

Thanks a lot - This is a good find and may well solve my immediate needs.
Sorry for late thanks - but PC down over last 3 days.

Brad

"Mr. Mike M." <vze23x2n@verizon.net> wrote in message
news:aedb3c$21t$1@news.codecharge.com...
> OK - But this may get somewhat involved....
> This is working with a combination of javascript and ASP.
>
> Preliminary items: My database has 3 tables. the "list" table, a "class"
> table to populate the first list box, and a "subclass" table to populate
the

<snipped>


   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

MS Access to Web

Convert MS Access to Web.
Join thousands of Web developers who build Web applications with minimal coding.

CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.