|
|
Weird. I'm not sure what happened there. My subject line indicates that I replied to the correct post (which I can't even find now)...
|
|
|
|
|
let's say i have an image that says "Hey" on it, how can i recognize it? i looked through some articles but haven't found anything useful.
|
|
|
|
|
|
The key word here is OCR (optical character recognition).
Try searching for it and you should come up with some ideas on how to start...
Regards,
mav
--
Black holes are the places where God divided by 0...
|
|
|
|
|
I am writing an app in this app it runs the same process over and over. but I want to wait in between it running the process. what i have is. I can not get this to wait for osql.exe to quit. if i run it like this it sends an out of bounds error. how can i easily make it wait for osql.exe to quit before it starts the next instance???? BTW i need to put that i did not start this process in the program it is being started by a script. the script does not show up as a process.
if(checkbox1 == true)
{
//it will run this process in this case it is osql.exe
}
Process p = Process.GetProcessByName("osql.exe")[0];
p.waitForExit();
if(checkbox2 == true)
{
//it runs osql.exe again but with different parameters
}
|
|
|
|
|
If get process by name returns an array you should check for null and the length of the array before assuming that an element exists. I call them row zero assumptions and lately they have become the bane of my existence.
File Not Found
|
|
|
|
|
i dont want it to go into an array though it was just the only thing i can find
i want to assign the process and wait for it to close then complete the rest of the program. I would think it would be easy enough but i cant find out how to do it.
if osql.exe is running wait for it to stop before continuing. thats all i want to do.
|
|
|
|
|
Hello,
The proplem is that you have to set the Process property "EnableRaisingEvents" to true, if you whant to use "waitforExit". It's somewhere written in the documentation on msdn.
You really should make a checkup on the length of the process array to prevent Exceptions.
All the best,
Martin
|
|
|
|
|
how do i use EnableRaisingEvents if I didnt start the process?
|
|
|
|
|
Hello,
Process[] processes = Process.GetProcessByName("osql.exe");
if(processes.Length>0)
{
processes[0].EnableRaisingEvents = true;
processes[0].WaitForExit();
}
foreach(Process p in processes)
{
p.Dispose();
}
All the best,
Martin
|
|
|
|
|
I'm trying to measure TimeSpans < 15ms on Windows XP. I recall hearing somewhere that windows won't return anything accurate under 15ms. Is that correct? Is there a way to measure down to the ms level?
Thx
|
|
|
|
|
|
Hi, may I suggest you read my timer article ?
|
|
|
|
|
Need software engineers and developers to create a Point of sale software for a restaurant and coffee shop. Willing to pay in canadian dollars, also may consider sponsorship
Regards,
Gary Sandhu
|
|
|
|
|
As much as I hate to say it MS offers a POS solution. It would be much more cost effective that having custom software made. Custom software for this application would run you between 30 and 120 grand for a decent system and then you would run the risk of project failure.
And while I do custom work you would freak at my rate.
File Not Found
|
|
|
|
|
Please don't cross post.
---
single minded; short sighted; long gone;
|
|
|
|
|
i've been looking for a project like this. will do for a lot less give me the specs.
I am a SysAdmin, I battle my own daemons.
|
|
|
|
|
Hello
I have been trying to make a directory on a server. I can make the directory but if the directory exists it gives me an error. I have been searching the net for information on how to check if the directory exists. The only thing I could find is that I need to set FtpWebRequest.Method to "NLST" and I don't understand what that means
My code so fare:
<br />
Uri adresse = new Uri("ftp://" + "/" + sMappe);<br />
<br />
FtpWebRequest req = (FtpWebRequest)WebRequest.Create(adresse);<br />
req.Method = WebRequestMethods.Ftp.MakeDirectory;<br />
req.Credentials = new NetworkCredential("login name", "password");<br />
FtpWebResponse response = (FtpWebResponse)req.GetResponse();<br />
<br />
Console.WriteLine("Status for mkdir: {0}", response.StatusDescription);<br />
response.Close();<br />
<br />
Console.WriteLine("Tryk enter for at slutte");<br />
Console.Read();<br />
<br />
Got more code doing other things on the local computer but haven't worked with FTP before.
Hope you can help me.
Regards
Morten
|
|
|
|
|
Hi,
how to monitor the status of the service from a utility developed in c#,I came to know that we can use either System.ServiceProcess.ServiceController class or WMI.Which is more robust,and feasible way.....I have to start,Stop and pause a service ,the App.config file has settings like polling time...I am not able to modify the service during runtime if i make change to the App.config after installing the service.So is it Feasible to modify the Application.exe.config file during runtime to make the changes take effect during runtime...
|
|
|
|
|
Unless you are doing something custom your windows service will load the app.config on start. You can make changes to the app.config while the window service is running, but they will not take affect until the service is stopped and re-started. If you have some custom code that re-reads the app.config file every time, then you might be able to get that to work. Otherwise you will need to stop and restart the service.
Ben
|
|
|
|
|
hi,
The changes made in the App.config will not take effect even ater stopping and starting the service , not untill you recompile the solution....
people laugh at me because they say im different and I laugh at them because they are all the same.
|
|
|
|
|
No that is not true. When you stop the service and start it again the app.config is read again. Now if you mean literally that if you make changes to the app.config file, then yes you need to recompile. But you should be changing the programname.exe.config file. where programname is replaced with what ever you call your service. When you change that file and stop and start the service it will pick up the change. Just make sure you update the app.config in your project as well.
Ben
|
|
|
|
|
Thanks,
After the service is installed it is not going to be recompiled in any way..So why do i at all make changes to the App.config file...Please clarify..
people laugh at me because they say im different and I laugh at them because they are all the same.
|
|
|
|
|
When you install your service, you need to have at least two files. One is the exe file. The other is the exe.config file. The exe.config file is created when you compile your project from the app.config. You can update the exe.config file directly and stop and start the service and it will use the new config settings. So if you service is called MyService the exe would be MyService.exe and the config file would be MyService.exe.config.
Hope that helps.
Ben
|
|
|
|