Cannot update Grid Control

The attached program contains a Grid and code to fill cells in the Grid. That code, which should run when the Form containing the Grid is ‘shown’ (it does ‘show’) does not fill the cells as it used to in an earlier version.

This is the dump of the Console log report immediately after the app started (the Grid DID load but the updates provided in the code did not occur)…

_Document was loaded from Application Cache with manifest http://127.0.0.1:51326/SMNMeetingWorkingAgendaFormat/OfflineApp.appcache_
(index):1 Application Cache Checking event
(index):1 Application Cache NoUpdate event
ajax-loader.gif Failed to load resource: the server responded with a status of 404 (File not found)

I do not know what ‘resource’ is ‘missing’, and would have no idea how to get it/load it…

I’ve reloaded AppStudio and get the same error.

I deleted the previous Grid and replaced it and got the same error.

SMNMeetingWorkingAgendaFormat.nsx (30.5 KB)

This is the smallest program I have that demonstrates the problem.

Several things here:

  1. Your ajax-loader.gif error is likely due to a bug in AppStudio related to jQM’s collapsible control. The same error appears when opening the Collapsible sample project. George will be able to address that issue.
  2. Your grid is not updating because you need to use ChangeForm() to get the Form1.onshow() event to fire. Change your Header_onshow() code like the example below and the grid should update:
Function Header_onshow()
  ChangeForm(Form1)
End Function
  1. You needn’t wrap your Project CSS rulesets in <style> tags. Just type in your CSS directly.

Kind regards,
Doug

Hey, Doug… thanks for the input… If I use your suggestion:

Function Header_onshow()
  ChangeForm(Form1)
End Function

The Grid DOES update… However, the Header Form disappears since the ChangeForm reeplaces it…
What I did was to add Header.show() to your code so that it reads:

Function Header_onshow()
ChangeForm(Form1)
Header.show()
End Function

Now the Grid updates AND both forms show… Again, thanks for your help…

Best regards,
Tom

Very good. Also, since you mention wanting the header to show up on another form, I’ll just mention George’s blog post here about making any control global across all your forms. It can be a handy solution since you don’t need to create a special form for them.

Kind regards,
Doug

Hey Doug… In another app, I have the Header that appears in all Forms… only need one copy of Header, while the rest of the display is a separate form for each ‘page’ of the app… The header contains the controls used on every ‘page’ of the app… works perfectly…

Best regards,

Tom

PS… George has not responded to your post concerning what you feel is an NSB issue in not enabling Grid changes… do you want to bring this up (which I would prefer since I’m not sure what the issue is) or do I bring it up… your call.

This is fixed in the next build. Not to worry though - this message doesn’t change anything in how your app executes.