Comments on: SharePoint: Extending the DVWP – Part 5: Doing Stuff Before Save on Submit – PreSaveAction() http://www.endusersharepoint.com/2010/05/27/sharepoint-extending-the-dvwp-%e2%80%93-part-5-doing-stuff-before-save-on-submit-presaveaction/ No GeekSpeak on SharePoint 2007 WSS and MOSS Fri, 22 Apr 2011 21:46:47 -0500 http://wordpress.org/?v=2.8.6 hourly 1 By: ahmed http://www.endusersharepoint.com/2010/05/27/sharepoint-extending-the-dvwp-%e2%80%93-part-5-doing-stuff-before-save-on-submit-presaveaction/comment-page-1/#comment-105849 ahmed Sun, 17 Oct 2010 09:33:19 +0000 http://www.endusersharepoint.com/?p=8028#comment-105849 In order to fire PreSaveAction upon user click "Complete Task" button, I had modified as shown below: The "task" is created by "collect data from user" activity in SPD. value="Complete Task" onclick="javascript: if(PreSaveAction()) Function has been fired with my user name (moss admin). However, function has not got fired with other user’s login!!! Any ldea? In order to fire PreSaveAction upon user click “Complete Task” button, I had modified as shown below: The “task” is created by “collect data from user” activity in SPD.

value=”Complete Task” onclick=”javascript: if(PreSaveAction())

Function has been fired with my user name (moss admin). However, function has not got fired with other user’s login!!!

Any ldea?

]]>
By: SharePoint: Extending the DVWP – Part 35: Putting it All Together, or | EndUserSharePoint.com http://www.endusersharepoint.com/2010/05/27/sharepoint-extending-the-dvwp-%e2%80%93-part-5-doing-stuff-before-save-on-submit-presaveaction/comment-page-1/#comment-99638 SharePoint: Extending the DVWP – Part 35: Putting it All Together, or | EndUserSharePoint.com Tue, 14 Sep 2010 14:35:23 +0000 http://www.endusersharepoint.com/?p=8028#comment-99638 [...] we have them looking the way we want them, we’ll open them up, see how they work, add a PreSaveAction(), add a  workflow, rearrange some things, and then fix what we [...] [...] we have them looking the way we want them, we’ll open them up, see how they work, add a PreSaveAction(), add a  workflow, rearrange some things, and then fix what we [...]

]]>
By: SharePoint: Extending the DVWP – Part 25: Using an Audit Trail by Creating List Items with SPServices | EndUserSharePoint.com http://www.endusersharepoint.com/2010/05/27/sharepoint-extending-the-dvwp-%e2%80%93-part-5-doing-stuff-before-save-on-submit-presaveaction/comment-page-1/#comment-92586 SharePoint: Extending the DVWP – Part 25: Using an Audit Trail by Creating List Items with SPServices | EndUserSharePoint.com Mon, 09 Aug 2010 15:40:20 +0000 http://www.endusersharepoint.com/?p=8028#comment-92586 [...] the Form Action buttons have been modified to call PreSaveAction(), this script will cause the changes to be saved to the audit list. Here’s a breakdown of how [...] [...] the Form Action buttons have been modified to call PreSaveAction(), this script will cause the changes to be saved to the audit list. Here’s a breakdown of how [...]

]]>
By: Jim Bob Howard http://www.endusersharepoint.com/2010/05/27/sharepoint-extending-the-dvwp-%e2%80%93-part-5-doing-stuff-before-save-on-submit-presaveaction/comment-page-1/#comment-92560 Jim Bob Howard Mon, 09 Aug 2010 13:32:43 +0000 http://www.endusersharepoint.com/?p=8028#comment-92560 Dear Tyler, Oh yes! I'm still in WSS, too... and I do all of this in the CEWP. Blessings, Jim Bob Dear Tyler,

Oh yes! I’m still in WSS, too… and I do all of this in the CEWP.

Blessings,
Jim Bob

]]>
By: tyler http://www.endusersharepoint.com/2010/05/27/sharepoint-extending-the-dvwp-%e2%80%93-part-5-doing-stuff-before-save-on-submit-presaveaction/comment-page-1/#comment-92558 tyler Mon, 09 Aug 2010 13:31:08 +0000 http://www.endusersharepoint.com/?p=8028#comment-92558 Excuse my ignorance here, as I'm still in WSS.. but can this be done in a CEWP? Excuse my ignorance here, as I’m still in WSS.. but can this be done in a CEWP?

]]>
By: Jim Bob Howard http://www.endusersharepoint.com/2010/05/27/sharepoint-extending-the-dvwp-%e2%80%93-part-5-doing-stuff-before-save-on-submit-presaveaction/comment-page-1/#comment-92549 Jim Bob Howard Mon, 09 Aug 2010 12:40:09 +0000 http://www.endusersharepoint.com/?p=8028#comment-92549 Great questions, Greg. I look forward to your article with the answers! ;) Blessings, Jim Bob Great questions, Greg.

I look forward to your article with the answers! ;)

Blessings,
Jim Bob

]]>
By: Greg http://www.endusersharepoint.com/2010/05/27/sharepoint-extending-the-dvwp-%e2%80%93-part-5-doing-stuff-before-save-on-submit-presaveaction/comment-page-1/#comment-92054 Greg Sat, 07 Aug 2010 20:31:20 +0000 http://www.endusersharepoint.com/?p=8028#comment-92054 Hi Jim, So, the PreSaveAction() function: * is there by default in an 'OK' button in a SharePoint form * can be added to the nifty 'save' (and other links in a DVWP when inserting items as multiple items and using the 'edit' options like Laura demonstrated in her article) That trick in itself is worth is weight in gold since it gives you the option to hijack the SP default functions until PreSaveFunction() evaluates to TRUE. If I recall, Marc A even used it to create folders with unique names making great use of SPServices requireunique utility functionand UpdateLIstItems http://sympmarc.com/2009/12/08/a-jquery-library-for-sharepoint-web-services-wss-3-0-and-moss-real-world-example-part-1/ Can you use the same tricks when: #1 using the DVWP and inserting items as multiple items forms (ref. Laura's article 1st part) #2 the user decides to bulk create items using the DataSheet view? Many thanks for sharing! Greg Hi Jim,
So, the PreSaveAction() function:
* is there by default in an ‘OK’ button in a SharePoint form
* can be added to the nifty ’save’ (and other links in a DVWP when inserting items as multiple items and using the ‘edit’ options like Laura demonstrated in her article)

That trick in itself is worth is weight in gold since it gives you the option to hijack the SP default functions until PreSaveFunction() evaluates to TRUE.
If I recall, Marc A even used it to create folders with unique names making great use of SPServices requireunique utility functionand UpdateLIstItems
http://sympmarc.com/2009/12/08/a-jquery-library-for-sharepoint-web-services-wss-3-0-and-moss-real-world-example-part-1/

Can you use the same tricks when:
#1 using the DVWP and inserting items as multiple items forms (ref. Laura’s article 1st part)
#2 the user decides to bulk create items using the DataSheet view?

Many thanks for sharing!

Greg

]]>
By: Jim Bob Howard http://www.endusersharepoint.com/2010/05/27/sharepoint-extending-the-dvwp-%e2%80%93-part-5-doing-stuff-before-save-on-submit-presaveaction/comment-page-1/#comment-91458 Jim Bob Howard Thu, 05 Aug 2010 18:21:32 +0000 http://www.endusersharepoint.com/?p=8028#comment-91458 On the surface, it sure sounds like something that would be doable with the PreSaveAction() on a Task list's EditForm.aspx. But, yeah, let's flip it over to STP to work out the details. (You may find yourself posting an article from the results. :) ) Blessings, Jim Bob On the surface, it sure sounds like something that would be doable with the PreSaveAction() on a Task list’s EditForm.aspx.

But, yeah, let’s flip it over to STP to work out the details. (You may find yourself posting an article from the results. :) )

Blessings,
Jim Bob

]]>
By: Robin Witcher http://www.endusersharepoint.com/2010/05/27/sharepoint-extending-the-dvwp-%e2%80%93-part-5-doing-stuff-before-save-on-submit-presaveaction/comment-page-1/#comment-91457 Robin Witcher Thu, 05 Aug 2010 18:11:22 +0000 http://www.endusersharepoint.com/?p=8028#comment-91457 Jim Bob, Just now getting a chance to read this section and fired some thoughts. Advise if I'm way off base here. Could the Edit Forms in a Task list (generated from an existing workflow) use the PreSaveAction?? Here's the scenario. We've deployed several InfoPath forms which have SPD workflows (Sharepoint 2007). Three of these workflows move forms to an "approved" or "rejected" library (different document library in the same site route). I've recently written secondary workflows to manually move these forms, because the managers often forget to close the InfoPath forms before approving. When this happens, the workflow with either record Stopped or Error Occurred and show that the form is checked out/locked for editing by the manager. I have a wait for Checked Out to To Be Empty step in the workflow in one of them, in others I've got a pause for 15 minutes (waiting for form to be closed)... neither one seems to prevent all of these errors. So I was wondering after reading your post here if it would be possible to pop up a message to the managers to close the InfoPath form before they hit "Complete Task". If there's an easier way to do this, please advise. As a one-woman Sharepoint team of an organization with 500 users, it's difficult to keep all of these forms where they need to go. The other possible solution I've thought of (but don't know how to implement) is to have the task email (customized) actual display the content of the form instead of a link to the form. The InfoPath forms can contain attachments (word, excel, pdf, jpg, etc) that would need to be viewable as well for this work. But I haven't figured out a way to do that. I need a solution that does not require Visual Studio (I am NOT a programmer, nor do I have one at my disposal). Thanks in advance for any advice you can give me on this. If I need to post this in Stump the Panel, just let me know where, and I'll gladly do so. Jim Bob,

Just now getting a chance to read this section and fired some thoughts. Advise if I’m way off base here.

Could the Edit Forms in a Task list (generated from an existing workflow) use the PreSaveAction??

Here’s the scenario. We’ve deployed several InfoPath forms which have SPD workflows (Sharepoint 2007). Three of these workflows move forms to an “approved” or “rejected” library (different document library in the same site route). I’ve recently written secondary workflows to manually move these forms, because the managers often forget to close the InfoPath forms before approving. When this happens, the workflow with either record Stopped or Error Occurred and show that the form is checked out/locked for editing by the manager. I have a wait for Checked Out to To Be Empty step in the workflow in one of them, in others I’ve got a pause for 15 minutes (waiting for form to be closed)… neither one seems to prevent all of these errors.

So I was wondering after reading your post here if it would be possible to pop up a message to the managers to close the InfoPath form before they hit “Complete Task”. If there’s an easier way to do this, please advise. As a one-woman Sharepoint team of an organization with 500 users, it’s difficult to keep all of these forms where they need to go.

The other possible solution I’ve thought of (but don’t know how to implement) is to have the task email (customized) actual display the content of the form instead of a link to the form. The InfoPath forms can contain attachments (word, excel, pdf, jpg, etc) that would need to be viewable as well for this work. But I haven’t figured out a way to do that.

I need a solution that does not require Visual Studio (I am NOT a programmer, nor do I have one at my disposal).

Thanks in advance for any advice you can give me on this. If I need to post this in Stump the Panel, just let me know where, and I’ll gladly do so.

]]>
By: SharePoint: Extending the DVWP – Part 13: Putting PreSaveAction() to Work – Creating Variables | EndUserSharePoint.com http://www.endusersharepoint.com/2010/05/27/sharepoint-extending-the-dvwp-%e2%80%93-part-5-doing-stuff-before-save-on-submit-presaveaction/comment-page-1/#comment-77019 SharePoint: Extending the DVWP – Part 13: Putting PreSaveAction() to Work – Creating Variables | EndUserSharePoint.com Thu, 24 Jun 2010 14:01:47 +0000 http://www.endusersharepoint.com/?p=8028#comment-77019 [...] in this series, we talked about the basics of Doing Stuff Before Save on Submit by using the PreSaveAction() function, which is called by default from the OK button on the NewForm [...] [...] in this series, we talked about the basics of Doing Stuff Before Save on Submit by using the PreSaveAction() function, which is called by default from the OK button on the NewForm [...]

]]>