We need to upgrade a current Windows application that extracts data from a remote Oracle database and writes it to a text file on the local disk. This application will be scheduled to run at specific time. Right now we have a Windows forms application with config file and using ADO.net and direct sql statements in the code first built using VS 2005. What is the optimal upgrade path given we have Visual Studio 2015 and Windows server 2016. Can this be accomplished using other than Windows form Application? Thankyou!
Asked
Active
Viewed 91 times
2
-
How easy would it be to move the logic to a Windows service or a console application? If you moved it to a console application, you could use the Windows Task Scheduler to do this. – EJoshuaS - Stand with Ukraine Mar 04 '20 at 14:48
-
The typical way on windows would be a service as explained here: https://learn.microsoft.com/en-us/dotnet/framework/windows-services/walkthrough-creating-a-windows-service-application-in-the-component-designer – Christoph Lütjen Mar 04 '20 at 14:55
1 Answers
0
One way to do this would be to try to move the logic to a console application and then use the Windows Task Scheduler.
You could also use a Windows Service for this: Windows Service to run a function at specified time
Personally, I think that the Windows Task Scheduler with a console application would likely be easier. (That's just my opinion, though).
Otherwise, you could use UI Automation for this, but it would be a little annoying. (There are other ways of doing this kind of automation that can be found on Google; I suggest searching on "how to automate a Windows Forms application" if you'd prefer to use a different way to do this).
A couple other references:

EJoshuaS - Stand with Ukraine
- 11,977
- 56
- 49
- 78