NewForm.aspx With Multi-Select Column - Add New Value From NewForm.aspx and Refresh Page Issue
-
2012年5月4日 17:42
Hello All - I have a custom NewForm.aspx in SP 2010 Foundation that has several lookup columns that are allowing multi-select. I am allowing the user to add a new value to the list that generates the lookup column via a piece of javascript (see below). When they click the link the newform.aspx for the lookup column list appears in a modal window.
All is well except I did not take into consideration when the user has entered values in other fields, and when they close the lookup column newform.aspx modal window, that the "location.reload(true);" I am using refreshes the entire page and wipes the values they have in the other fields.
Any suggestions on the best way to handle this?
Thanks and appreciate your help!
<script type="text/javascript"> var options = { url: "/Lists/MyMSDNExampleLookupList/NewForm.aspx", title: "Add New Category", allowMaximize: true, showClose: true, width: 625, height: 255, dialogReturnValueCallback: silentCallback}; function open() {SP.UI.ModalDialog.showModalDialog(options);} function silentCallback(dialogResult, returnValue) { location.reload(true); ; } </script> <a href="javascript:open()">Add Category</a>
すべての返信
-
2012年5月4日 20:10
Hi
check this post
http://antoniolanaro.blogspot.com/2011/04/open-sharepoint-2010-modal-dialog-and.html
Romeo Donca, Orange Romania (MCSE, MCTS, CCNA) Please Mark As Answer if my post solves your problem or Vote As Helpful if the post has been helpful for you.
- 回答としてマーク Emir LiuMicrosoft Contingent Staff, Moderator 2012年5月11日 6:06

