Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6874765
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T04:14:07+00:00 2026-05-27T04:14:07+00:00

Working in SharePoint 2010, with SharePoint Designer 2010, I have a DispForm to which

  • 0

Working in SharePoint 2010, with SharePoint Designer 2010, I have a DispForm to which I’ve added a DVWP that displays a filtered view of another relative list. The DVWP has a ‘New’ link which opens the NewForm for that list in a modal dialog, using OpenPopUpPage (http://msdn.microsoft.com/en-us/library/ff410825.aspx).

After 5 – 12 seconds, the blinking cursor disappears from the first control and the focus switches to the ‘Close’ button. If the user was trying to type and happens to hit the Enter key when the focus switches to the ‘Close’ button, the background is no longer darkened and the ‘Cancel’ button no longer works. The form is still displayed on the screen, and the user can ‘Save’ but the modal never goes away until the page is refreshed.

If the user notices that the modal has lost focus and clicked back on the form, everything works as it should and all is well.

Observations:

When the control/modal loses focus, the ‘Close’ button does not trigger a ‘focusin’ event. But, $(document.activeElement).attr(“value”) displayed in the console shows that it’s the active element.

Questions:

  1. Why is the modal losing focus?
  2. Does anyone have a Javascript/jQuery workaround to capture the event and set the focus back where it was?
  3. Alternately, what if I lock the form and wait for this focus-change to complete, then unlock it and set the focus on the first field? Ideas?
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-27T04:14:07+00:00Added an answer on May 27, 2026 at 4:14 am

    I figured out the problem: the DVWP was using Auto-Refresh with the Async Update. This was running every 15 secs, taking the focus away from the modal, then not returning it to the last control.

    So, we turned of the auto-refresh and used the callback from the modal close to trigger a click on the manual refresh button instead.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am working with SharePoint 2010 and ECMAScript. I have added a customaction to
I have three lists on Sharepoint 2010 and I have working code that gets
Working with Sharepoint 2010, I have a class that inherits SPPersistedObject with various settings:
I have a workflow that I'm working on SharePoint 2010 and I've built a
I have an html question. I'm using sharepoint - working on Sharepoint Designer. I'm
I am working with SharePoint 2010 form library. I have a drop down column
I have just started working with SharePoint 2010(you could say a bit of a
I am working on a SharePoint 2010 integration that has an SPItemEventReceiver for handling
I am working on a SharePoint 2010 Server and i have following items in
I have been working on some customisation for SharePoint 2010 using Visual Studio. My

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.