Hi,
I have been searching for a .NET (Visual Studio Tools) or VBA (Modifier) Code example which demonstrates how to export SmartList Data into a CSV File, but without success. Would anyone know where to find such an example? Otherwise, would someone know how to loop through the records found in a specific SmartLit?
Thank you for your time.
Regards,
Joseph
*This post is locked for comments
Thank you again Joshua. We are currently still on Version 10 with no access to SSRS. We could use your suggested SSRS option once we have upgraded to the latest Version. Meanwhile, the difference between SSRS Reports and SmartLists, is that users can add columns in SmartLists, which would be automatically included in the Export (contrary to SSRS Reports, which would need to be modified, unless there is a functionality with which I am not familiar). The requirement from users is to have the ability to export directly to csv files, without having to go through Excel.
Thank you.
Regards.
Joseph
Joseph,
Using a SaaS model deployment with GP is common, and SSRS reports (built into GP) have access to the database, and they use both the GP security model and SQL security. These can be limited to specific company databases, and the user (or group) security policies can be managed on the SQL side to prevent access to unauthorized tables.
If this is not a viable solution, the easiest way to get a CSV file from Smartlist is to export it to Excel and save it as a CSV.
You could even use an Excel macro to perform a Save As CSV using VBA code, and assign this macro to run on the Smartlist report after export. This is in Smartlist under the menu option SmartList > Export Solutions.
Thanks,
Joshua Pelkola
Hi Joshua,
Thank you for your reply. We have deployed Dynamics GP in a Hosted Environment, in which each legally independent entity has its own Company Database (but using a common unique Dynamics Database for all the Organizations). The Organizations do not have, and cannot be granted, access to the Databases directly, but must use the Dynamics GP Client, for security reasons and as a policy. Also, if one would connect directly to the Database, one would not have the ability to use Dynamics GP’s Security Model. The SmartLists used are the default ones, eventually customized using the built-in functionality, but not the Builder. Some Organizations would like to have the SmartList Data exported to a csv file.
Thank you again.
Regards,
Joseph
Hi Joseph,
Curious to know why you want to export via Smart List when there are much faster options available. If you are looking for a quick way to do this, write a SQL query for the data you are exporting, and create an Excel Builder report. You can easily make this csv data, and it can be automated. Another way is to use SSRS reports to retrieve data which can be exported to many data types.
Smart List is a good tool for users to get data, but it is not good for developing data farming with .net or vba modifier. Is the Smart List report you need a default report, or is it a custom built report using Smart List Builder? If it is the latter, you can basically copy the query used to get the data, and use this with a simple .net call to the GP database to get the same info directly to a collection, dataset, table, entity, csv, xml, json, etc..
HTH,
Joshua Pelkola
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,240 Super User 2024 Season 2
Martin Dráb 230,149 Most Valuable Professional
nmaenpaa 101,156