Hello,
Is it possible to make a file watching code from an external C# DLL initialsed once with Epicor 10 on the server or the client ?
use the FileSystemWatcher class
I’m not sure what you mean by Initialized Once within Epicor…
Again back to the drawing board, what’s the end goal?
I already have a program that is running on the server which monitors a folder that receives an XML generated by my external DLL that is linked to a Data Directive after a product configuration in an Order or Quote. This XML file is used for calculations then generates a PDF that I want to attach the the same Order or Quote. I want to watch that folder from my external DLL to use the current Session of the Epicor user to attach it to the order or quote.
I cannot execute a the file watcher on that trigger. I’m looking for a place where I can attach my code to be runned once.
Do you have service connect? This sounds like a job for Service Connect.
Are you able to change the program that generates the PDF? It might be better to attach the PDF via REST at the time of generation instead of using a folder watcher.
I haven’t explored yet the Service Connect option. I’m actually new to Epicor. I’ll give it a look! thanx for the feedback 
What are you trying to do?
I have found things like a SQL Job/PowerShell to suit my needs to check a file folder for a certain file(s) exists. If nothing exists, it just exits the Job. If it does, then proceeds to the next step – import data via DMT, send emails/notifications, other processes, etc.
(BTW, if you are new to SC…just to let you know the learning curve is steep).
@tomdomurat I’m trying to integrate a Driveworks with Epicor in order to dynamically create methods for custom products. When the user creates a quote or an order and use the configuration window for a product, an XML with the custom parameters is placed in a folder that is watched by Driveworks. (this part is working well). Calculations are made the program generates the numbers needed for the custom product in XML format in another folder.
At this point, I don’t want to use another program that checks that folder and connect to Epicor(which I have). I want to be able to do it directly from Epicor.
I dont have access to the driveworks program yet. But once I do, I’ll check if I can connect to Epicor directly from it. For now, I’m exploring the possibilites. So even if I want to do a simple post with SC, its learning curve is steep? 
Were you able to get this working?
I didnt waste time with writing code in epicor. all I do is communicating with epicor through BOs and Api calls when stuff get triggered in epicor.