Page 1 of 1

Error occured applying the Custom XML definition

PostPosted: Tue May 05, 2015 3:57 pm
by neil.interactit
Sorry, another one happening on site that I cannot reproduce locally ...

image002.jpg
image002.jpg (16.12 KiB) Viewed 18017 times


My guess is the XML definition is in the application folder on site?

Cheers,
Neil

Re: Error occured applying the Custom XML definition  Topic is solved

PostPosted: Tue May 05, 2015 4:24 pm
by Scott.Pearce
When a user right clicks on any grid in Jiwa, they can choose to "Use custom columns" for that grid. This means that the user can move columns around, hide or un-hide columns, change the size of columns, rename columns, etc. and these adjustments will be remembered for that user. When they make such changes, and "Use custom columns" is enabled for that grid, then an xml definition for the grid layout is generated and saved to the database. Such custom layouts can be found in the table SY_UserProfile with an IDKey of "CustomXML" on a per user basis.

I suspect that, for whatever reason, the custom xml definition string for that user, for a grid on whatever form they are attempting to load, has become corrupt/invalid. Jiwa is therefore giving an error and falling back to the standard layout for that grid.

To fix, delete SY_UserProfile entries for that user:

Code: Select all
DELETE FROM SY_UserProfile WHERE UserID = (SELECT TOP 1 StaffID FROM HR_Staff WHERE Username = 'Fred')


Of course, you should replace 'Fred' with the username of the user suffering from the issue. The above will delete *ALL* user profile settings for poor old Fred, so maybe we should be a little more targeted:

Code: Select all
DELETE FROM SY_UserProfile WHERE UserID = (SELECT TOP 1 StaffID FROM HR_Staff WHERE Username = 'Fred') AND IDKey = 'CustomXML'


Above will delete all custom grid information for user Fred. We could still be a little nicer:

Code: Select all
DELETE FROM SY_UserProfile WHERE UserID = (SELECT TOP 1 StaffID FROM HR_Staff WHERE Username = 'Fred') AND IDKey = 'CustomXML' AND Section = 'JiwaFinancials.Jiwa.JiwaPluginMaintenanceUI.frmMain.grdModules.Default'


The above statement only targets custom grid information for user fred, for a particular grid.

Hope this helps!

Re: Error occured applying the Custom XML definition

PostPosted: Tue May 05, 2015 5:04 pm
by neil.interactit
Thanks Scott.

Oh how I wish I had access to the client's live database ... I have bundled up a script with some easy parameters for them to run.

Thanks again,
Neil.