Call running EXE application and simulate its functions [closed] - c#

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 9 years ago.
Improve this question
I have an Windows Application running on my PC , this application list all connected servers on our farm .
This application have manual process (more than one step ) to do one action per server ,,
The steps are as the following (These steps are done for each one of the servers listed) :
Select one server then click right on the mouse then choose one option.
The selected option will open a new window above the parent application window.
Then click on button.
What I need is to build a new C# application that acts/simulate as the above application with ability to do that action automatic for all select servers from the list ..
I hope its clear now ,,
Please help me ..

If the application you want to attach has a UI, You can use UI Automation and Win32 API to manipulate some functinallity.
Try this starting points:
How to I get the window handle by giving the process name that is running?
Get the handle of a window with not fully known title. (C#)
http://www.csharphelp.com/2006/08/get-current-window-handle-and-caption-with-windows-api-in-c/
using C# and UI Automation to grab contents of unknown control-type
Good luck

Related

How do run a task in background and even if app terminated in xamarin forms? [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 3 years ago.
Improve this question
I need to run a task at a specified time even if my app in the background or terminated in Xamarin Forms(Android and iOS). Please suggest me the best way to do it.
If your application is in the background you can run background services and let do whatever whenever,
If your application is totally terminated you cannot do anything.
The only way to do it if your application is terminated by push notification when your application receive the notification you can run your code but the user have to click on the notifications.
TYou can't write, Because each platform has their own way and rules for background services. You have to make services for each platform.
I don't want to be that guy that says "Google it" - but there are a number of tutorials directly from Xamarin that explain backgrounding. Have you looked? Getting your information directly from Xamarin is always the first place to start.
docs - https://learn.microsoft.com/en-us/xamarin/ios/app-fundamentals/backgrounding/
video - https://www.youtube.com/watch?v=Z1YzyreS4-o

Open popup from service [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 4 years ago.
Improve this question
I have created a windows service that checks a new release of an application. And if there is a new release then it will show an alert or message to the user saying that "A new release is available. Do you want to install it?".
My service is ready but I am not able to show this message to the user from Windows Service.
TL;DR: you cannot.
Longer version: a few years ago the use of highly privileged processes (services showing UI) opened up vulnerabilities where user processes could be elevated to gain those higher privileges. Therefore the capability was blocked.
Instead you need a completely separate user process to provide the UI and some form of inter-process communication (like a named pipe with a carefully chosen ACL) to connect to the service. This also allows you to handle the case where no one (via make the connection work across the network) or multiple users are logged in (and none on the console).

Alternative way for Background Process [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 6 years ago.
Improve this question
I've created a simple application in C# which purpose is to have a Windows Service running on Background in the whole time the computer is alive and which I know is a non-GUI process.
I want the Service to execute some command like, programmatically lock the computer, send data to one of my Windows Form Application, show Windows Form Application etc. which will not work because it is Windows Service. I found it really hard for me to work with this.
Now, my question is, is there any alternative way for what I want to achieve?
I mean other solution for running background process in the whole time and do the GUI job?
I am really out of ideas, anyone can suggest/help will be very appreciated!
You can always write a winforms application that will run a background thread listening for commands and executing tasks. Then all you need to do is register this executable to be started when a session is started. The application could be minimized to the tray so that the user could still manipulate it.

Winform app with loaded DB connection [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 8 years ago.
Improve this question
I have a question regarding problem i am solving. I am editing an old Winform app; currently the only part I need does not take input from the user(automated program). However the form contains database connection settings that program uses. Currently the program needs the user to press a button to start the process (code is associated with the button). Do i need to convert whole app to Console App or is there an easier way to automate this process without messing with the database connection settings.
Right now, you have a WinForm that runs code on a button press. You need to turn this into a "headless" or automatic process. Here is what I think based on your description would be the best things to do:
Remove the button, and have the code that was being ran by the button be called by a more "automatic" process, such as "Form_Load" or a timer.
Take the code and move it into a console app. As long as you don't ask for user input within the logic, it will run and close itself when it's done.
However, this is just some broad and generic suggestions. You need to look at your code and decide for yourself what to do.

Retrieve the user requests from a website using a desktop application [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
I had made a site for client in which users can make request for songs, there's a database having songname, by whom, written by, sang at etc. The site is hosted and working fine.
The way the admin gets to know what is asked for is by using the website but now he wants that there be a desktop application which displays all the requests so he does not have to log in and use the website
I do have an idea to get this done, but I am hoping for a well known established way. I am using C# asp.net.
I think you can create an Http Handler. This handler will listen to the request and you can log them in a database, and the windows application will read from the database.
You can simply use Timer in windows application.
Set your Timer to either 1 min or 2 min as per your need.and on its Tick event you check the live database whether is there any new request come or not..
If new request come then you can show some notification or something like this...

Categories