web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

File transfer between Ax and SFTP server

(0) ShareShare
ReportReport
Posted on by 781

Hello Experts,

I have a requirement to transfer files between SFTP server and Ax. Please let me know how to approach this.

I've gone through some articles

* one of that saying it is not possible in Ax and .net

* other saying we can do it using  one of these

WinSCP dll / PuTTY/ SSH.Net / SharpSSH

But I don't know how to take step on this.

So if any one knows the approach please let me know.

Thanks & Regards,

Johnkrish

*This post is locked for comments

I have the same question (0)
  • Martin Dráb Profile Picture
    237,978 Most Valuable Professional on at

    It definitely is possible - use one of .NET libraries for SFTP. If you don't know how to use these libraries, look into documentation or find examples on internet. Here is one for SSH.NET.

  • Johnkrish Profile Picture
    781 on at

    Hi Martin,

    Thank you for the response, but all the codes they mentioned in the links are .Net C# codes. So how I can implement in Ax.

    ? Do I need to create a class in Visual studio as Class library with all the code, sftp .dll and .exe file and I need to add as a reference in AOT then call that class.

    ? otherwise, Shall I write the code  directly into Ax ? if yes please give me some X++ code example.

    Thanks & Regards,

    Johnkrish

  • Suggested answer
    Vilmos Kintera Profile Picture
    46,149 on at

    Yes, you could use a C# wrapper and import it in AX 2009 as a reference once packaged as a DLL.

  • Martin Dráb Profile Picture
    237,978 Most Valuable Professional on at

    You can call .NET objects directly in X++ using .NET Interop. Nevertheless creating a class library and doing most of the work there is often a good idea, because .NET Interop has some limitations and it's easier to have just a limited number of calls through it.

    Yes, you need to add a reference to the assembly you're going to use from X++. If you create your wrapper assembly, you'll add a reference to that. If you use another assembly directly, you'll add a reference to that assembly.

    Don't forget that the process must be able to find physical DLLs to run code inside, therefore you'll need them in the application bin folder on AOS, if your code will run on server. And you'll need them in client bin folder to compile your code, because compilation runs on client.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Dráb Profile Picture

Martin Dráb 4 Most Valuable Professional

#1
Priya_K Profile Picture

Priya_K 4

#3
MyDynamicsNAV Profile Picture

MyDynamicsNAV 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans