iSeller Commerce
iSeller POS Retail
iSeller POS F&B
iSeller POS Express
Crosslight
WebUI
ClientUI
What's New
Download Trial
Web Solution
Mobile Solution
Enterprise Solution
Custom Development
Blog
Community
Latest Development Blogs
ForumPostTopic
Browse By Tag
WebGrid 10
IE 11
Right-clicked on a grid cell causes an error opening context menu if language XML hasn’t fully loaded yet. The h string is null because the GetString(…) call returned null in WGMenuEngine.GetBasicFilterColumns
From the screenshot, the error happen on GetTranslatedString function of WebGrid_Context.js. One of the events that trigger this function is: when AutoFilterSuggestion is enabled (WebGrid - LayoutSettings - AutoFilterSuggestion) and user right-click on WebGrid column header.
The error happen because h is undefined or null. Since h is the parameter passed by following expression (from GetBasicFilterColumns): d.GetString(b + f[e].Name.substring(3))
The above should expression should return something like: "Equals {0}".
In my opinion, the error might happen if ISGetObject("WebGrid1").GetString("ContextMenu/FilterSuggest/ET") returns undefine or null.*Please note that the "ET" in string "ContextMenu/FilterSuggest/ET" might vary with: ET, NET, Contain, NotContain, LTET, GTET, and so on.
If you are using custom localization for your WebGrid, please ensure that the xml node under "FilterSuggest" is not left empty/blank.
<Localization culture="default" description="Default Language"> ... <ContextMenu> ... <FilterSuggest> <ET>Equals {0}</ET> <NET>Does Not Equal {0}</NET> <Contain>Contains {0}</Contain> <NotContain>Does Not Contain {0}</NotContain> <LTET>Less Than or Equal To {0}</LTET> <GTET>Greater Than or Equal To {0}</GTET> <OnBefore>On or Before {0}</OnBefore> <OnAfter>On or After {0}</OnAfter> <Checked>Is Checked (True)</Checked> <NotChecked>Is Not Checked (False)</NotChecked> <Tomorrow>Tomorrow</Tomorrow> <Today>Today</Today> <Yesterday>Yesterday</Yesterday> <NextWeek>Next Week</NextWeek> <ThisWeek>This Week</ThisWeek> <LastWeek>Last Week</LastWeek> <NextMonth>Next Month</NextMonth> <ThisMonth>This Month</ThisMonth> <LastMonth>Last Month</LastMonth> <Past>Past</Past> <Future>Future</Future> <Blank>Blank</Blank> </FilterSuggest> ... </ContextMenu> ... </Localization>
Hope this helps.
We aren't customizing the localization files. Yes, the root cause seems to be that if the internal GetString call returns null/undefined, then other functions will fail. From what I could tell, this issue can occur if the grid's context menu opens before the default.xml localization file is fully loaded. So it doesn't have the string to use yet.
Mike
or
Choose this if you're already a member of Intersoft Community Forum. You can link your OpenID account to your existing Intersoft Social ID.
Choose this if you don't have an Intersoft account yet. Your authenticated OpenID will be automatically linked to your new Intersoft account.
Enter your Wordpress Blogname