Skip to content
+1-888-319-3663

EONE BLOG

Tech Tuesday – Calling the SmartConnect Web Service



For this week we have a little more content than normal for our tech article. Chris Dew has put together a couple of Visual Studio projects along with a map so developers can take a look at how to run maps from our web service in their own programs:
We are seeing more developers wanting to use SmartConnect and eConnect and they are finding the use of our webservice one of the best ways to quickly roll out solutions that need to push instead of pull when it comes to integration with Dynamics GP and CRM.
Last month we introduced the new Excel GL Template that calls our web service from VBA. This week we will explore calling two methods of our web service from C# or VB.NET. I won’t go into the specifics of the code here because you can download the code as Visual Studio projects that will work on Visual Studio 2010 or Visual Studio 2012 from the link below:
There are two main methods that you will want to use, RunMap and RunMapWithDataTable. The RunMap method of the web service is very simple, the only parameter it accepts is a SmartConnect Map ID. This will then run the specified map with whatever the data source was configured (ie. Excel Sheet, Text File, SQL table). The second function, RunMapWithDataTable, accepts two parameters. The first parameter is the SmartConnect Map ID like the previous method but the second parameter is the XML representation of the data you want. What does this mean? Well, now you can overwrite the data source for the map and use your own. This means that even a map that was configured to use a data source of Excel can now push data from a website. The main requirement is that the columns you pass in must match the originally configured data source.
We will have a new web service coming out next year that will have some additional features on requesting information and returning it to your application so stay tuned for that.
Again, we always appreciate your feedback on what we are providing so let me know!
Thanks,
Chris Dew
chris.dew@eonesolutions.com

Update: 9/29/2020 PTR fix broken link

5 Comments

  1. john steve on December 4, 2012 at 12:38 am

    The information is very useful!Thank you for sharing the information!Keep up the great works !
    Business Planning Brisbane

  2. Adriaan Davel on May 22, 2015 at 12:35 am

    Hi,

    Is it possible to expose your web service as a data source? So one could call the service and get mapped data out of GP.

  3. Geoff James on October 10, 2016 at 12:02 am

    Hi Chris,

    Do you have an answer on the question from Adriaan? I have the same question, where a client wants to use SmartConnect version 20.13.1.89 to export data to the SmartConnect Web Service.
    Can I just create a XML map and use the RunMapwith DataTable on the web service site?
    Thanks
    Regards,
    Geoff James

  4. Patrick Roth on October 10, 2016 at 10:19 am

    In regards to Adriaans question you wouldn’t get ‘mapped’ data out of GP. “Mapped” implies destination.

    For Geoff’s question, you ask “Can I just create a XML map and use the RunMapwith DataTable on the web service site?”

    This is about the same – not sure what you mean here because if you use RunMapWithDataTable, you are _sending_ the data to the map to process.

    But assuming both questions are “i want to get data OUT of the eOne web service”, you can’t do that directly with the asmx service.

    But the REST service has this.

    http://www.eonesolutions.com/Manuals/SmartConnect/SmartConnect%202016/?page=gp_get_data

    This is, I believe, the same method that the Excel Addin uses to pull data into Excel from a map. It calls the method which then invokes the Source Data routine of the map and sends the data back to Excel.

    patrick

  5. Arthur on December 4, 2017 at 8:18 pm

    In regards to Adrian’s question and assuming you want to pull data from GP you can be creative in doing so.

    Create a map that exports to excel text or whatever and call it using RunmapwithDatatable. Add a Task to the map to call another map and use the data from the original map to push data back to your site.

Leave a Comment





RECENT POSTS


2021 Q4 Promotions
Connect with us at Directions EMEA 2021 in Milan!
eOne at Summit North America 2021
Employee Spotlight: Megan Tripp, Business Development Representative
eOne is now compatible with Microsoft Dynamics GP October 2021 Release

POPULAR POSTS


2016 SmartConnect Integration Bootcamps
Tech Tues: Automatically refreshing Pivot Tables in Excel Refreshable Reports
Happy Thanksgiving from the eOne team!
2017 SmartConnect Integration Bootcamps
New Releases of Extender and SmartList Builder

CATEGORIES

TAGS

Business Central CRM D365 Business Central Dynamics 365 dynamics crm Dynamics GP Dynamics NAV Econnect Employee Spotlight eone eOne News error Error Message Events Excel Excel Report Builder Extender Flexicoder GP integration Map Meet the Team Microsoft dynamics crm Microsoft Dynamics GP Navigation List Builder Office Relationships partners Popdock release Reporting SalesForce SalesForce.com SmartConnect SmartConnect.com SmartConnect Bootcamp SmartConnect Maps SmartConnect Office Hours SmartList SmartList Builder SmartPost SmartView SQL Tech Tuesday Templates training

Integrate & Automate without Any Code.

SmartList Data has Never Been Faster.

The Easiest Way to Report on GP Data.