Take the 2-minute tour ×
SharePoint Stack Exchange is a question and answer site for SharePoint enthusiasts. It's 100% free, no registration required.

I'm back with another problem. ;)

I managed to create a list with a multi lookup to another list, containing some labels. I added a webpart to list A's edit form to allow direct adding of labels to List B, with the intention of the added values showing up in the lookup immediatly.

First, I try to add a new label by filling in the textbox and clicking Create, as shown here: http://imgur.com/2duDbM3,hB8OCFo#2

However, the page then reloads, showing the lookup columns to be both empty, like here: http://imgur.com/2duDbM3,hB8OCFo#1

Is there anyway I can force a full refresh of the page via C# code behind the Create button that will make this page show up correctly?

Thanks in advance! David

share|improve this question

1 Answer 1

You can always hook to a button press event via JavaScript\JQuery and refresh your page.

Example:

Hook to a click event and refresh the page:

$("#target").click(function() {
  location.reload();
}); 
share|improve this answer
    
Hi Alex, thanks for the tip. However, the reload() function gives the user a dialog asking to resend the information. In this case, they'd create the new label twice, while they're supposed to be unique. I've tried using "window.location.href=window.location.href;", that does give me the same page with the controls filled, but in the state that is was -before- adding the new label. The created label doesn't show up in the available labels column yet. :( –  David Apr 3 '13 at 10:10

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.