1

I have added a search box for a SharePoint List I have created and I want to be able to save the filter when I edit an item.

For Example, I find my name, edit that item and when I save that item I want to be able to go back and see the same filtering being done?

Is there anyway I can get this done for my team as I have a huge list that is frustrating to do every single time once I edit, save, etc.

I am new to coding so if there is any background coding needed I would appreciate a simple code or an explanation of what is going on in the code.

3
  • Can you use filter columns ? Aug 8 '16 at 14:19
  • You can use the filtering columns but it does not save the filter after going into an item within that page.... Aug 8 '16 at 14:21
  • But you can share the resulting URL, book mark it and share it, or create the filtered view as it's own view and share that URL Aug 8 '16 at 14:23
1

In the list you can enable Dialogs so the list filtering will get persisted. After editing you can close the dialog which will not reload the page.

Second option is to handle the keypress event of the searchbox and pass the value back and forth using querystring or by placing the values in cookie. You can attach the value as below

$('.ms-InlineSearch-SearchBox-Baseline').bind('keypress', function(e){
    if((e.keyCode || e.which) == 13) {alert($(this).val())};
});
1
  • Amal - I think your dialog box option might be the best. I have tested it out in our list and it's working exactly how I need it to work. Option 2 will be my last resort! Thank you for the help. Aug 8 '16 at 14:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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