GP Paste From Excel With Intercompany

As mentioned before, here is my add-in for Microsoft Dynamics GP. The version I use it with is 2013 R2 but I have no reason to believe that it would not work for older or newer versions of GP. While developing it, I made sure to make it conform to the same format as GP’s built-in Paste feature so the order of the columns is typically Description, Account, Debit and Credit. For Intercompany, the company ID is required and for Payables or Sales, the document type is needed. The dll reads the data stored in your Clipboard in the order shown in the examples so you just need to copy data from Excel or any Tab-delimited file.

Installation: Drop the dll into your Microsoft Dynamics installation folder’s Add-In folder and restart GP.

“Paste Entry” is accessible from the “Additional” toolbar at the top of the following windows:
– GL Transaction Entry
– Payables Transaction Entry (Distribution Window)
– Sales Transaction Entry (Distribution Window)

GPPaste(PM) GPPaste(RM) GPPaste(GL)

Features Supported:
– Intercompany
– Multicurrency (values are entered as Originating amounts)

Download: GPPaste.dll (Version 1.0.5578.19478)

Copy template: Paste GL Transaction Example.xlsx

GPPaste(Template)

Enjoy,
~James

Disclaimer: I am very much an amateur programmer. I have never taken an official Microsoft course. I cannot guarantee any code/program that I provide as I only have the ability to test my work on a small sample set. Users accept all the risk of using anything I provide and are encouraged to thoroughly test in a dedicated test environment before moving to production. Files I provide are free for use and are not to be resold. By using my files you agree to not hold me liable for any damages caused by said files.

Advertisements

31 thoughts on “GP Paste From Excel With Intercompany

  1. Great Job to the couple of tools you have made available. I did notice that if you have default purchasing accounts that they will be overwritten by the paste into the journal entry, however you do end up with two Accounts payable lines. A couple of solutions are to paste in just the purchasing accounts or you can click the delete button to delete all distribution accounts and then past in your journal entry.

    I have tested with GP2015 and it appears to work just fine for normal and intercompany transactions.

    Looking forward to reading your blog posts and seeing what other tools you come up with.

    Like

  2. Thanks Paul!
    With respect to the AP pasting, that is *kinda of* by design. It actually starts the paste on the active row and goes down so if you do not have any row activated the default is the top/first row. If you create and select a new blank row below the default AP lines the paste will start there.

    At our company we disabled manual entry to the AP accounts so the default AP account is necessary for us so that’s the way I handled it. I guess I could automatically go to the bottom on the first paste but scroll windows in GP aren’t the friendliest things so I just thought it easier to tell them to select the last row. To take care of the first blank row, just right click and select delete row.

    Like

  3. Hello – we have followed the instructions, unblocked the dll after pasting it in the local Addins folder, we are logged in as Administrator and get the following error – GP Stopped Working, with the following details:
    Problem signature:
    Problem Event Name: CLR20r3
    Problem Signature 01: Dynamics.exe
    Problem Signature 02: 14.0.84.0
    Problem Signature 03: 55510502
    Problem Signature 04: mscorlib
    Problem Signature 05: 4.0.30319.34209
    Problem Signature 06: 534894cc
    Problem Signature 07: 27cb
    Problem Signature 08: 0
    Problem Signature 09: System.IO.FileLoadException
    OS Version: 6.1.7601.2.1.0.256.48
    Locale ID: 1033
    Additional Information 1: 0a9e
    Additional Information 2: 0a9e372d3b4ad19135b953a78882e789
    Additional Information 3: 0a9e
    Additional Information 4: 0a9e372d3b4ad19135b953a78882e789

    Do you know why we can’t this to work (GP 2015 R2).

    Thank you!

    Like

  4. I’m testing it out with my DGP2013 install. I dropped the dll into add-ins, unblocked it, and restarted the app.

    I don’t see the paste option as shown.

    Like

    • Other people have commented that the “Unblock” doesn’t actually work so their work arounds are to either:
      1. Copy the file onto a usb, delete it from the Addins folder, and paste it back from the USB
      or
      2. Zip the file, delete the file from the Addins folder, unzip the file back into the folder

      Is your Dynamics installation local or through remote software such as Citrix?

      Like

  5. Okay. I downloaded and unblocked, copied to usb and then to Add-ins folder.

    PC was restarted.

    No errors, but no listing for the option.

    Like

    • 1. I know this is a simple thing but bare with me. For Sales/Payables, are you in the distributions window and not the document entry window (making sure “Distribution” is in the title bar)? The paste option only appears on specific windows:
      -Manual General Journal Entry
      -The distribution window of sales transaction entries
      -The distribution window of payables transaction entries

      2. Is the “Additional” menu visible at all and are there any other options underneath?

      3. There is another General Journal free paste developed by a dynamics MVP http://di.jo/GPExcelPastePredownload.aspx. If you have the time, see if that one works. If it does then its an issue with my add-in, if not then it has something to do with your system configuration not allowing the add-in to run properly. Either way, both would let us troubleshoot further.

      Like

  6. The Journal Entry already has this option for us and it appears that the other specific windows are not used by us. STE without the “Distribution” is what we would need.

    I did look into the DI version from Mohammad Daoud, but it looks like they have merged it with the paid version. I don’t see that the free version is available.

    Thanks for the help.

    Like

    • Hi Kara,
      The company I worked with did not have/use analytical accounting so I am not sure. Best I can say is try it and test. It will not post the entry by itself so if it does not work as intended, you can always discard the entry.

      Like

  7. James,

    I’m attempting to do a similar project where I have to populate multiple lines of a GP scrolling window. I can’t seem to get the code to advance to the next line though. I don’t see any documentation on how to do this in the MSDN pages for GP Tools for Visual Studio.

    I’ve tried including a reference to the Continuum DLL and using the ExecuteSanscript() method to call the Dex Window_ScrollScrollingWindow() function, but that isn’t working. It keeps returning FOCUS_NOT_IN_SWIN or FOCUS_DIVERTED.

    Can you point me in the right direction?
    thanks!

    Like

    • Is this a stand-alone application or a GP add-in?

      Assuming you’re successfully within the GP instance, I use 4 basic steps to move and populate through fields in a row and then a single command to move to the next line. I do this using Sanscript as I couldn’t get some of the commands to work in the C# libraries:
      1. Focus the field of the window/transaction scroll of the form you are in
      2. Move to the field
      3. Set the data value of the field
      4. Execute the run script for the field (this is the field validation)
      5. Execute the Window_ScrollScrollingWindow command on the Transaction_Scroll with command SCROLLTYPE_NEXT

      Here is a snippet from my add-in: Scroll Sample Code

      Let me know if this helps or if you need me to go more in-depth!

      Like

      • Thanks! Your sample code works for my GP AddIn.

        My original code used the SDK to Focus(), set “field.Value”, and call RunValidate() for each field being populated. But I couldn’t figure out how to advance to the next scrolling window. Using Continuum to call Window_ScrollScrollingWindow() didn’t work.

        But when I use the Continuum library to focus, set the value, and run the change script per your sample code, the subsequent call to Window_ScrollScrollingWindow() works.

        Too bad the SDK is incomplete. Would be much cleaner to code in either C# or Dexterity/Sanscript rather than calling one from the other…

        Like

      • Glad it worked, it took me a long time to find the correct command to get it to work because I ran into the exact problem that you did where the c# library commands wouldn’t work.

        From my understanding, all the SDK does is wrap the Sanscript commands into nice C# commands for you, as GP runs off of Sanscript. They just must have broke some of the commands after a version update or something. I’m just glad they let us execute Sanscript from the library else we would be stuck in these situations 🙂

        Like

  8. I am trying out the AP copy/paste. For each transaction we need the invoice # in the vendor history, but when we put that in the description column it does not show up in vendor history. Also when there are multiple transactions they get lumped together as one amount, 4 invoices of $100 becomes 1 payable of $400 and it should be 4 payables of $100. Is there any way to do this?

    Like

    • Hi Quentin,
      First, I am not sure which field you are referring to when you say “vendor history”. Anything in my description column when you copy should be pasted into the description of each distribution line.
      When you say they get lumped together as one amount, do you mean entries to the same GL account get posted as the $400?
      The idea of my add-on is not to paste multiple invoices at once. It is for one invoice that needs to be posted across many different GL accounts in the distribution window. If you are trying to post multiple invoices at once, I would suggest you use Integration Manager as it is already built into Dynamics GP.
      James

      Like

  9. Hello James,
    I’ve attempted to use the GPpaste.dll, however, in a GL batch, when I check the Intercompany box prior to pasting the paste function goes away. I have done some investigation and it seems since we dont use currency that this might be the issue. Can you offer any insight?

    ~Allen

    Dynamics GP 2016 R2 16.00.0552

    Like

    • Hi Allen,
      Just to make sure, are you referring to the Paste button on the tool bar or my paste option under the Additional menu? My option will appear under the Additional menu where as Microsoft’s paste will go away if you try to use intercompany/multicurrency.

      Like

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s