Tuesday, August 11, 2009

Fixing Microsoft Dynamics GP Toolbar erratic behavior

A few months aback, I blogged about a case where the Microsoft Dynamics GP toolbar menu would reorganized itself erratically even with the Lock Toolbar option activated. Back then, I alluded to the Script Debugging Tool being activated via the DEX.INI. Since then, I have also found that this may (or may not) be the case when returning from Modifier or Report Writer.

If you do happen to experience this issue and do not use the Script Debugging Tool, you can run the following T-SQL script in SQL Server Management Studio to correct the problem:


USE DYNAMICS;
GO

UPDATE SY07121
SET Visible = 0, ROWNMBR = 1, RowSequence = 1
WHERE CmdBarDictID = 3830
AND CmdBarFormID = 22006
AND CmdBarWindowID = 22003
AND USERID <> ''


UPDATE SY07121
SET Visible = 1, ROWNMBR = 1, RowSequence = 4
WHERE CmdBarDictID = 0
AND CmdBarFormID = 1568
AND CmdBarWindowID = 294
AND USERID <> ''


UPDATE SY07121
SET Visible = 1, ROWNMBR = 1, RowSequence = 3
WHERE CmdBarDictID = 0
AND CmdBarFormID = 1568
AND CmdBarWindowID = 295
AND USERID <> ''


UPDATE SY07121
SET Visible = 0, ROWNMBR = 99, RowSequence = 0
WHERE CmdBarDictID = 0
AND CmdBarFormID = 1568
AND CmdBarWindowID = 231
AND USERID <> ''


UPDATE SY07121
SET Visible = 0, ROWNMBR = 99, RowSequence = 0
WHERE CmdBarDictID = 0
AND CmdBarFormID = 1568
AND CmdBarWindowID = 223
AND USERID <> ''


UPDATE SY07121
SET Visible = 0, ROWNMBR = 99, RowSequence = 0
WHERE CmdBarDictID = 0
AND CmdBarFormID = 1568
AND CmdBarWindowID = 230
AND USERID <> ''


UPDATE SY07121
SET Visible = 0, ROWNMBR = 99, RowSequence = 0
WHERE CmdBarDictID = 0
AND CmdBarFormID = 1568
AND CmdBarWindowID = 228
AND USERID <> ''


UPDATE SY07121
SET Visible = 0, ROWNMBR = 99, RowSequence = 0
WHERE CmdBarDictID = 0
AND CmdBarFormID = 1568
AND CmdBarWindowID = 225
AND USERID <> ''


UPDATE SY07121
SET Visible = 0, ROWNMBR = 99, RowSequence = 0
WHERE CmdBarDictID = 0
AND CmdBarFormID = 1568
AND CmdBarWindowID = 224
AND USERID <> ''


UPDATE SY07121
SET Visible = 0, ROWNMBR = 99, RowSequence = 0
WHERE CmdBarDictID = 0
AND CmdBarFormID = 1568
AND CmdBarWindowID = 226
AND USERID <> ''


UPDATE SY07121
SET Visible = 0, ROWNMBR = 99, RowSequence = 0
WHERE CmdBarDictID = 0
AND CmdBarFormID = 1568
AND CmdBarWindowID = 227
AND USERID <> ''


UPDATE SY07121
SET Visible = 0, ROWNMBR = 99, RowSequence = 0
WHERE CmdBarDictID = 0
AND CmdBarFormID = 1568
AND CmdBarWindowID = 192
AND USERID <> ''
GO

The above script is applicable ONLY to Microsoft Dynamics GP v10. Make a backup of your DYNAMICS database before executing this script.

If the above fails to correct the issue, then you will need to remove the records for the user in question:


USE DYNAMICS;
GO
DELETE FROM SY07121 WHERE USERID = 'theUserID';

The scripts were originally provided by Sarah Purdy on the Dynamics GP Partner Technical Community and must be executed without any users in the system.

Until next post!

MG.-
Mariano Gomez, MVP
Maximum Global Business, LLC
http://www.maximumglobalbusiness.com/

8 comments:

Anonymous said...

Is this fix true in a Citrix environment? Or if multiple users share one machine that have different menus?

sherlene said...

can you please provide an updated script or let us know if this script is valid for GP2010?

Also, it appears this script would affect all users. what is it actually doing?

Thanks!

Mariano Gomez said...

@Anonymous:
Because the menu items are stored in the DYNAMICS database, it really does not matter how you have deployed the client application (Citrix, desktop deployment, or otherwise).

MG.-
Mariano Gomez, MVP

Mariano Gomez said...

@Sherlene:
The script still applies to GP2010. Please execute the scripts in a test environment to evaluate the results and determine whether you should execute in production.

All scripts can be narrowed down to 1 user if needed.

MG.-
Mariano Gomez, MVP

Anonymous said...

This is still happening in GP 2013 R2 and in GP 2015. Can you ask David Musgrave to add something to SDT to lock this down better, or at least implement a reset on (all or specific) user logons?

Mariano Gomez said...

Anonymous:

We've had several exchanges with David Musgrave about this topic and this is not something that can be addressed with the Support Debugging Tool.

MG.-
Mariano Gomez, MVP

David M said...

What about putting a fix or workaround in the support debugger tool?

Rachel Nigon said...

We just updated to GP2015 R2. Will the script work for this version?