close ad
WARNING: Do Not Install the DREAMWEAVER CC 2017 or 2018 Update »
open ad
View Menu

Technical Support Forums

Free, outstanding support from WebAssist and your colleagues

rating

multiple update & delete on one page

Thread began 9/06/2009 1:03 am by office377308 | Last modified 10/20/2009 2:26 pm by Eric Mittman | 1611 views | 9 replies |

office377308

multiple update & delete on one page

I got it to work but only after tweaking. so I 'd like to ask if I did something wrong.
I created a recordset and a form (POST) for updating a mysql table and bound the field names to the recordset fields.
Then I added a checkbox in the form for "delete multiple" server behaviour and added a name and id to it.
Next I added DA's repeat behaviour within the form for multiple action.
Next I applied DA "update multiple" and started to bind the form fields. I realized that the behaviour not only added "_<?php echo $RepeatSelectionCounter_1; ?>" to each field's name and id but also to the checkbox (which I wanted to use for the multiple delete behaviour).
So the problem was:
After adding DA's multiple delete server behaviour, the checkbox name did not appear in the list of form fields anymore. I had to manually delete the above mentioned part of the checkboxes name and id to make it visible again in the list of form fields in order to be able to bind it to the multiple delete sb.

After I had done this it was working again.

Did I miss something in the adding sequence ?

Sign in to reply to this post

Eric Mittman

I think you may be experiencing a problem with the order you are applying the server behaviors. Once you have the form elements on the page this is when you apply the repeat selection server behavior. Once that is applied you should then be able to add in the multiple delete and update and work within that repeat selection for both of these. If you have any problems with this approach or get the same result let us know and I can look into this further.

Sign in to reply to this post

office377308

This is exactly what I did:

* I created a recordset and a form (POST) for updating a mysql table and bound the field names to the recordset fields.
* Then I added a checkbox in the form and added a name and id to it.
* Next I added DA's repeat behaviour within the form for multiple action. with the submit button outside the repeat area but within the form
* Next I applied DA "update multiple" and started to bind the form fields. I realized that the behaviour not only added "_<?php echo $RepeatSelectionCounter_1; ?>" to each field's name and id but also to the checkbox (which I wanted to use for the multiple delete behaviour).

Is it better to apply the delete behaviour first?

Sign in to reply to this post

Eric Mittman

It should not matter the order that you put these server behaviors on the page. Once you have added the DataAssist Repeat Selection the names of the form elements will change to be based on the counter.

This is what makes this the repeated form on the page. Both the Update and Delete server behaviors rely on this repeated entry to work. You should be able to apply the multiple update and delete server behavior on this page without issue. In the multiple delete you just specify which field the id comes from, a checkbox in my case. Then in the update you just specify what elements are bound to what columns by using the dropdown options of the value select list next to the lightning bolt.

I'm including some screen shots of what the interfaces should look like so you can compare with what you have in yours.

Sign in to reply to this post

office377308

Thank you

I will try it again, one last question: Does it matter if I use Dreamweaver's repeat Region behaviour or must it be the one from DA?

Thank you for your quick answer.

Sign in to reply to this post

Eric Mittman

You must make sure that you use the DataAssist Repeat Selection server behavior and not the repeat region DW server behavior. Let us know how it works for you.

Sign in to reply to this post

office377308

Still no joy

Whatever I try, it does not work. I have spent 3 days with this now.
Originally I wanted to integrate this into a page with more functions. Now I tend to put this functions (update&delete) to a separate file and include it via php in order to keep the code chunks small.
But nothing works as expected. I can select the checkbox for further deletions -> does not work.
I want to update the txt fields -> does not work.

I attach the whole code as a zipped .doc

Thanks for any hint

Attached Files
UpdateDeleteNotWorking.zip
Sign in to reply to this post

Eric Mittman

I have opened a ticket for you on this issue. Please login and visit your support history to update the ticket with the requested information.

Sign in to reply to this post

office377308

Finally found the mistake

Originally Said By: Eric Mittman
  I have opened a ticket for you on this issue. Please login and visit your support history to update the ticket with the requested information.  



Hi Eric,
found the mistake, and as it seems it has been on my side: I forgot to select the key column in the Recordset, but it needs to be selected - of course!

It is not enough to select it in Data Assist's multiple update and/or multiple delete server behaviour, you also needs to select it in the adjacent recordset! Thats where my misunderstanding happened.

Thank you for your patience!

Sign in to reply to this post

Eric Mittman

Ok, so the column you were using as the key column in the update and delete server behaviors was not a part of the original recordset that was selecting the records. That makes sense about the result you were getting given that. Hopefully someone else will see this and realize they have the same problem. Thanks for posting back about it.

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...