close ad
 
Important WebAssist Announcement
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

Dependent Dropdowns - updating records

Thread began 9/02/2010 10:25 am by sandy170299 | Last modified 9/13/2010 1:40 pm by Jason Byrnes | 2947 views | 9 replies |

sandy170299

Dependent Dropdowns - updating records

I have a PDF table which stores information from a PDF category and a PDF sub category table in main PDF table. I cannot find a tutorial on how to update a record using dynamic dropdowns. I went through the PDF that is on your web site, but found it to be incomplete. Where can I go for help? At one point, was there a movie that showed how to do exactly what I'm describing? Using the dependent dropdowns in update mode?

Sign in to reply to this post

Jason ByrnesWebAssist

the key to using dynamic dropdowns on an update page is to add the Populate List from array behavior to the Onload event of the body tag.


you will also need to add the set selected in list behavior to select the correct value based on the recordset.

For each dynamic dropdown on the page, you will need to add the Populate list from array and set selected behaviors to the body's onload event.

Sign in to reply to this post

sandy170299

Jason, can you post a link to an example of this - on update, please? Thanks!

Sign in to reply to this post

Jason ByrnesWebAssist

Sorry, we do not have an example of this being used on update.
You will only need to add the Populate list from array and set Selected in List behaviors to the OnLoad action of the body tag.

Sign in to reply to this post

sandy170299

Jason, on my update page, that option (WA Dynamic Dropdowns > Populate List From Array) is grayed out. I cannot apply it to the <body> tag.

Sign in to reply to this post

Jason ByrnesWebAssist

Have you added the Create Dynamic Array behavior to the page?

Can you send a copy of the page so I can take a look at the code.

Sign in to reply to this post

sandy170299

Jason, I'm attaching the actual page that I'm working with. I'm not sure what I've missed seeing that the documentation doesn't exist for the update mode. Thank you!

Attached Files
WA.txt
Sign in to reply to this post

Jason ByrnesWebAssist

In design view, click the pdfCatID select list, then clic kthe dynamic button in the property inspector, In the Select value Equal to section, click the lightning bolt and select the pdfID column from the WADApdfarticles recordset.


On you body tag, you have the Poiulate list from array behavior set correctly, but you dhave set the Set Selected In List behavior to use the pdfCatID list instead of the pdfSubCatID list, edit that so it is using the child list.

Sign in to reply to this post

sandy170299

The first list box is working now, but the 2nd is not.

<body onload="WA_FilterAndPopulateSubList(Recordset2_WAJA,MM_findObj('pdfCatID'),MM_findObj('pdfSubCatID'),0,0,false,': ');WA_setSelectionsInChildList(MM_findObj('pdfSubCatID'),<?php echo $row_WADApdfarticles['pdfSubCatID']; ?>)">

My 2nd listbox includes the following:

<select id="pdfSubCatID" name="pdfSubCatID" onchange="pdfCatID_reload(this)">
<?php
do {
?><option value="<?php echo $row_Recordset2['pdfSubCatID']?>"><?php echo $row_Recordset2['pdfSubCatName']?></option>
<?php
} while ($row_Recordset2 = mysql_fetch_assoc($Recordset2));
$rows = mysql_num_rows($Recordset2);
if($rows > 0) {
mysql_data_seek($Recordset2, 0);
$row_Recordset2 = mysql_fetch_assoc($Recordset2);
}
?>
</select>

Thanks!

Sign in to reply to this post

Jason ByrnesWebAssist

the onchange event may be causing the issue:
<select id="pdfSubCatID" name="pdfSubCatID" onchange="pdfCatID_reload(this)">

change that to:
<select id="pdfSubCatID" name="pdfSubCatID">

If your still having issues, I'll need to see it in the browser, let me know and I'll start a private ticket.

Sign in to reply to this post
loading

Build websites with a little help from your friends

Your friends over here at WebAssist! These Dreamweaver extensions will assist you in building unlimited, custom websites.

Build websites from already-built web applications

These out-of-the-box solutions provide you proven, tested applications that can be up and running now.  Build a store, a gallery, or a web-based email solution.

Want your website pre-built and hosted?

Close Windowclose

Rate your experience or provide feedback on this page

Account or customer service questions?
Please user our contact form.

Need technical support?
Please visit support to ask a question

Content

rating

Layout

rating

Ease of use

rating

security code refresh image

We do not respond to comments submitted from this page directly, but we do read and analyze any feedback and will use it to help make your experience better in the future.

Close Windowclose

We were unable to retrieve the attached file

Close Windowclose

Attach and remove files

add attachmentAdd attachment
Close Windowclose

Enter the URL you would like to link to in your post

Close Windowclose

This is how you use right click RTF editing

Enable right click RTF editing option allows you to add html markup into your tutorial such as images, bulleted lists, files and more...

-- click to close --

Uploading file...