Thursday, May 30, 2013

Negative Payroll Transactions 2013 and Integration Manager 12.0


In order to get Integration Manager to import Negative Pay Code Hourly Transactions in Dynamics GP 2013, a few changes must be made to the integration.

A script must be placed on the “Amount” field in Destination Mapping:


SourceField = SourceFields("PR Trx Temp.Units")
SetVariable "Units", CStr(SourceField * 100)
If SourceField  < 0 Then
            SetVariable "NegativeTRX", "TRUE"
            CurrentField.Value = 9999.99
Else
            CurrentField.Value = SourceField
End If
This script sets the value of the hours for the imported transaction to 9999.99 and saves the original value in a variable.

NOTE: “PR Trx Temp.Units” will need to be set to the Source Field name from your integration.

Next a script must be placed on the “After Document” event within the Integration Properties:

 

NegativeTrx = GetVariable("NegativeTrx")
Units = GetVariable("Units")
 
If NegativeTrx = "TRUE" then
            UpdateStatement = "UPDATE " + GPConnection.GPConnInterCompanyID + ".dbo.UPR10302 SET TRXHRUNT = '" + Units + "' WHERE TRXHRUNT = '999999' AND BACHNUMB = '" + SourceFields("BatchID") + "' "
            Set MyCon = CreateObject("ADODB.Connection")
            MyCon.ConnectionString = "database=" &     GPConnection.GPConnInterCompanyID
            GPConnection.Open(MyCon)
            Call MyCon.Execute(UpdateStatement)
            Call MyCon.Close
            Set MyCon = nothing
End If
 
ClearVariables
This script checks to see if the current record being imported was a negative hours transaction.  If so, it sets the hours back to the original negative amount from the amount previously stored in a variable.

Saturday, March 2, 2013

Meet me at Convergence 2013 in New Orleans!

Wish you could determine the next big Dynamics feature?  Here is your chance! 

Integrity Data’s Product Manager, that's me by the way, is hosting a Partner/Customer Advisory Luncheon at Convergence for the sole purpose of hearing your ideas.  We want to hear what YOU want to see in the product and how YOU believe the product can be improved.  Do NOT miss this opportunity to have direct input and influence into the future of Dynamics software! Contact me (tfranz@integrity-data.com) for an official invite – space is limited - you won't regret it!

Wednesday, January 16, 2013

Convergence 2013

Just got the word ... heading to Convergence 2013 in New Orleans in March!  Looking forward to meeting up with our Partners and Customers and meeting new ones!  #CONV13