Developing for Dynamics GP

by David Musgrave (Perth, WA, Australia) and the Microsoft Dynamics GP Developer Support Team (Fargo, ND, USA)

How to access a Third Party Table Buffer on a Cross Dictionary Procedure Trigger

How to access a Third Party Table Buffer on a Cross Dictionary Procedure Trigger

  • Comments 0

Dave DusekThis particular situation has come up in a number of support incidents and I also run into this myself on occasion.  The situation is that you have a cross dictionary procedure or function trigger on a script and one of the parameters is a third party table buffer. 

According to KB Article 861788 Secure Link, you can transfer third party table definitions into your own dictionary and then you have direct access to those table definitions.  However, that strategy does not work in the case of a table buffer parameter.  If you transferred the table definition into your own dictionary and then tried to access the table buffer in the trigger processing procedure, the table buffer would always be empty.  The issue is that your table has it's own buffer and is not using the buffer on the procedure/function.  The reason for this is because the resource id of the third party table in your dictionary doesn't match the resource id of the table in the third party dictionary. 

In this situation, instead of transferring the table definition, you need to change the table
buffer parameter to anonymous and then use the column function to access the data.  Now you
will be accessing the table buffer that is passed in the parameters list.

Example Dexterity Code - This is the trigger processing procedure on a cross dictionary procedure trigger.  This is the correct way to access a third party table buffer:

For more information on how to create a combined dictionary and working with Cross Dictionary Development see the following articles:

Cross Dictionary Dexterity Development

How to combine the Dynamics.dic core dictionary and an extracted dictionary by using Dexterity Utilities in Microsoft Dynamics GP (KB 930350) Secure Link

Dave Dusek
Dynamics GP Developer Support

// Copyright © Microsoft Corporation.  All Rights Reserved.
// This code released under the terms of the
// Microsoft Public License (MS-PL, http://opensource.org/licenses/ms-pl.html.)

Comments Information

PLEASE READ BEFORE POSTING

Please only post comments relating to the topic of this page.

If you wish to ask a technical question, please use the links in the links section (scroll down, on right hand side) to ask on the Newsgroups or Forums. If you ask on the Newsgroups or Forums, others in the community can respond and the answers are available for everyone in the future.

Leave a Comment
  • Please add 1 and 1 and type the answer here:
  • Post