NetTalk Central

Author Topic: intermittent update when returning to browse  (Read 3271 times)

kingja

  • Sr. Member
  • ****
  • Posts: 261
    • View Profile
    • Email
intermittent update when returning to browse
« on: September 30, 2014, 07:11:04 PM »
I have a small NT 8.23 app (C9.1.11242) that seems to update intermittently.  That is, when I go to the form, make a change and then save, sometimes the change is made when retuning to the browse, other times it is not.  I can click on a header field to cause the browse to update or click on close.  I expect the browse to reflect the updated data when I return to it.  Any thoughts?

Thanks,

Jeff

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: intermittent update when returning to browse
« Reply #1 on: September 30, 2014, 08:58:03 PM »
Nothing springs to mind Jeff.

the first debugging step to make though is to check the Firebug console to see if any errors are being reported there.

You say it's a small app? Maybe you can send it to me here (with instructions) and I can take a look?

Cheers
Bruce


kingja

  • Sr. Member
  • ****
  • Posts: 261
    • View Profile
    • Email
Re: intermittent update when returning to browse
« Reply #2 on: October 01, 2014, 06:12:46 AM »
Bruce,

     I have attached a zip file containing the app and dct files, as well as two tps files.  To repeat what I see, go to the Browse menu item and select Demographics.  Click change to open an existing record.  Add a character or two to a field like last name.  Click on Save to return to the browse.  The browse should reflect the change.  Now go back in immediately and remove one of the newly added characters and save again.  The browse does not update to reflect the changed data.  You may have to repeat this a number of times as sometimes it works as expected.  Other times it does not.
     I'm running this as an exe on a Win 7 Pro VM (VMware 10) for testing but the app is meant to be run as a dll with the Host.exe app.  This app was created with the wizard and I added some code to the browse setqueue embed.  I have tested with this code removed and still see the issue.

Thanks,

Jeff

[attachment deleted by admin]

Bruce

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 11250
    • View Profile
Re: intermittent update when returning to browse
« Reply #3 on: October 05, 2014, 11:49:47 PM »
Hi Jeff,

>> You may have to repeat this a number of times as sometimes it works as expected.  Other times it does not.

this is the biggest clue. It means you're doing something that is likely dependent on the "order' things are happening, or whether 2 things are happening at once and so on.

While I didn't duplicate the effect you are seeing, I noticed you are using 2 global variables (glo:mrn and glo:Patient). This is verboten. All users will end up sharing these global variables, and hence what one user is doing can affect another user.

So first step - make these go away completely. Use SessionValues to store data related to a user. That will likely make the problem go away.

cheers
Bruce