|
inner wrote:
may take to stop like 5-10 minutes for example, will system kill it anyway on its own at some point or it will wait infinitely for it to stop?
Depends on how you write the service. You must report the status of your service at regular intervals to inform the SCM of your state. When you receive a request to stop, you set the service status to stopping. Then every few seconds you update the SCM and let it know you are still stopping. If the SCM does not receive an update within a reasonable amount of time it will assume you have stopped responding.
The same would be true during startup, pause, and continue. Just provide updated every few seconds. If you need to perform a really long operation that cannot be broken down into smaller portions then run that work in a seperate thread. Then in the main thread you wait a limited time for the worker thread to complete. If it does not finish you report your status and then wait again.
--
"The money power of the country will endeavor to prolong its rule by preying upon the prejudices of the people until all wealth is concentrated in a few hands and the Republic destroyed."
-- Abraham Lincoln
|
|
|
|
|
Hmmmm... Ok. I always thought that SCM makes calls to a service and not the other wayt around. How do you send anything back from service to SCM? Even would be a lot better is you know how to do that in C# service. Thanks a lot.
|
|
|
|
|
Well using C# I am not sure. I've seen C# and that is about it. In C++ using Win32 you would do something like this.
SetServiceStatus(m_tSvcStatusHandle, &m_tSvcStatus);
Do a search on MSDN for SetServiceStatus.
SetServiceStatus[^]
--
"The money power of the country will endeavor to prolong its rule by preying upon the prejudices of the people until all wealth is concentrated in a few hands and the Republic destroyed."
-- Abraham Lincoln
|
|
|
|
|
Also do you know how ro "register" or "re-register" a "source" to "log" for event logging?
I keep getting this
"The source 'MyService' is not registered in log 'Application'. (It is registered in log 'MyServiceLog'.) " The Source and Log properties must be matched, or you may set Log to the empty string, and it will automatically be matched to the Source property." exception after I tried to change the log to standard "application".
|
|
|
|
|
I have a clean fresh install of Windows XP and I have an ASUS video card with which came PowerDVD (renamed AsusDVD).
Previously with the same exact computer also running WinXP (corp version), it was working very fine. Now I install WinXP off a copy I bought and AsusDVD does not want to play DVDs, complaining about an winaspi.dll missing.
But I have no SCSI driver. I have done some searches on the problem on the Internet but the solutions are very confusing.
Can anybody help me here?
|
|
|
|
|
hi, i'm new to linux. I currently need to explore the linux platform for my project. i'm using Mandrake.
i would like to know:
- how to run .exe file on linux.
- how to compile java on linux platform. There are a few jdk for linux( e.g. blackdown JDK, IBM JDK, Sun J2SE and Kaffe). May i know which to choose? Is it all of them are mostly the same, and i can pick anyone of them?
thanks in advance.
|
|
|
|
|
|
@n!e wrote:
- how to run .exe file on linux.
As Uma mentioned, you can use Wine. For stuff in which you absolutely need a Windows environment, but don't want to reboot into Windows, there's VMWare: http://www.vmware.com/[^]
@n!e wrote:
- how to compile java on linux platform. There are a few jdk for linux( e.g. blackdown JDK, IBM JDK, Sun J2SE and Kaffe). May i know which to choose? Is it all of them are mostly the same, and i can pick anyone of them?
I mainly use the Sun J2SE for my projects for the JRE (since it's the standard), but use IBM's free Jikes compiler (which is many times faster than Sun's javac). The downside to Jikes is that the error output can be downright cryptic at times, which is when I'll fall back to javac.
- Mike
|
|
|
|
|
|
hi, i'm new to linux.
I'm trying to run a java program on a linux with jdk 1.2.2.
But i got the following error:
Font specified in font.properties not found [--symbol-medium-r normal--*-%d-*-*-p-*-adobe-fontspecific]
Warning: Cannot convert string "<key>Home,_Key_Begin"
to type VirtualBinding
Warning: Cannot convert string "<key>F1,_Key_Help" to
type VirtualBinding
Warning: Cannot convert string
"Shift<key>F10,_Key_Menu" to type VirtualBinding
Warning: Cannot convert string
"<key>F10,Shift_Key_Menu" to type VirtualBinding
Warning: Cannot convert string
"<key>KP_Enter,_Key_Execute" to type VirtualBinding
Warning: Cannot convert string
"Alt<key>Return,Alt_Key_KP_Enter" to type
VirtualBinding
Exception in thread "main"
java.lang.NullPointerException
at javax.swing.ImageIcon.<init>(ImageIcon.java:99)
at SplashScreen.<init>(MainFrame.java:528)
at Client.main(Client.java:124)
can anyone of you tell me what is it?
Thanks in advance.
|
|
|
|
|
Hi.
I need to set up an SQL server on a linux machine and use Windows 2000 as a SQL client.
Would MyODBC / MySQL be the best way about this?
Cheers
|
|
|
|
|
I found a neat shortcut and was wondering if anyone else saw this before. If you have a folder in any Windows taskbar toolbar (Desktop or "Quick Launch" ...), you can show the contents of the folder as a menu if you hold the control key while clicking it. This means that you can organize you desktop into folders while still accessing the shortcuts without opening a new explorer window. I can't find this tip listed anywhere on the internet. I found it because my KVM got the control key stuck. The only other thing like it is a "ShortPopUp" program which I found just hours before discovering this neat built-in OS feature. I tried it on a Windows 98 machine and it worked so it looks like this was probably added as part of the Active Desktop.
Vern
|
|
|
|
|
Hi
I keep on getting this error when accessing a page that gets information from the SQL 2000 DB. The system is XP Pro with latest MDAC installed after reading various technet articles on microsoft which seemed to say install the latest one.
I tried changing between ODBC and OLEDB DSN-less connectionm strings without success. Also tried creating a System DSN for the database, still no luck.
here is the error and then the versions:
--Error-------------------------
HTTP 500.100 - Internal Server Error - ASP error
Internet Information Services
--------------------------------------------------------------------------------
Technical Information (for support personnel)
Error Type:
Microsoft OLE DB Provider for ODBC Drivers (0x80004005)
[Microsoft][ODBC SQL Server Driver]Timeout expired
/CMSAPI.asp, line 1301
Browser Type:
Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)
Page:
GET /admin_categories.asp
Time:
15 June 2003, 19:50:00
More information:
Microsoft Support
--------------------------------
SQL2000 Personal edition, 10 users lic. SP1
Win XP Prof SP1
MDAC Ver2.7 (Updated this today), updated it on SQL I think.
Strange thing is if I have only one browser open I can quite happily go about my business, but as soon as I open a second one to view the website I am working on, it all falls over with the above error.
Line 1301 above is simply a call to a SQL statement which is a simple "SELECT * FROM C_CAT WHERE ID = " & pgID
Argh, if anyone can clue me in on how to resolve this issue I'd really be grateful
Ta
John
|
|
|
|
|
How can I reconfigure VNC to use KDE. If I start vncserver it starts a vnc session that is an X session with only a console window. I've never had to reconfigure vnc to work with KDE. Can anyone help me?
FreeBSD 4.8 (Custom Kernel), KDE 3.1
Matt Newman
|
|
|
|
|
I need to reset an ata/ide device, but don't know how to do this. Anyone knows how to do this?
|
|
|
|
|
Maybe this can help:
Devcon[^]
The source should be available in the Windows XP DDK
Wout
|
|
|
|
|
Dear All,
I am encountering a major problem in my "Windows NT Server Version 4"
"It restarts and boots when logon screen comes".
I tried to start the system again but no use. As soon as the log-on scree comes (Ctrl-Alt-Del Screen), the systems restarts itself.
Can any body explain where is the problem and How can this problem be solved ?
Thanks in advance.
Rohit
|
|
|
|
|
Dear All,
I am encountering a major problem in my "Windows NT Server Version 4"
"It restarts and boots when logon screen comes".
I tried to start the system again but no use. As soon as the log-on scree comes (Ctrl-Alt-Del Screen), the systems restarts itself.
Can any body explain where is the problem and How can this problem be solved ?
Thanks in advance.
Rohit
|
|
|
|
|
Hi,
Can you please tell how we can get a file from linux machine to a windows machine.Suppose there
is a file called /home/rohit/myapp.exe of size 50MB. How can I get the file to my windows
machine. I think I should be using telnet and ftp but what are the commands.
Actually i downloaded a application from internet to my linux machine and now i want to transfer
it to my windows machine.
Please comment
Thanks in advance.
|
|
|
|
|
If both machines are in a network you have several possibilities. You can use Samba to mount a Windows network share in Linux or to share a Linux directory to Windows machines. For FTP, you must run a FTP server program in one machine and a FTP client in another.
|
|
|
|
|
If you are running sshd you should be able to secure ftp to your home directory. Some of the nicer windows ssh clients have sftp integrated.
Matt Newman
|
|
|
|
|
Over the last week or so, clicking on a zip link in IExplorer downloads and opens the zip file directly in Winzip, As opposed to downloading and saving the file (after prompting).
Does anyone know what has happened to my IE settings and how to change this back to the original action?
cheers.
"..Even my comments have bugs!"
Inspired by Toni78
|
|
|
|
|
In IE6, open the Tools menu and select Folder Options. Click the File Types tab, then scroll down the list of types to ZIP. Select it, then click the Advanced button. Select the "Confirm open after download" checkbox, then OK twice to close the dialogs. In earlier versions of IE the Folder Options function is located in the View menu, I believe. In versions 4 and earlier you have to edit the registry - check the Knowledge Base at Technet for info on this.
"Ask not for whom the bell tolls; It tolls for thee..."
|
|
|
|
|
Thanks. I have this problem too, so I'll use this fix.
One more thing - it's not in IE , it's in Explorer.
"Blessed are the peacemakers, for they shall be called sons of God." - Jesus
"You must be the change you wish to see in the world." - Mahatma Gandhi
|
|
|
|
|
jdunlap wrote:
it's not in IE , it's in Explorer.
Too right... My mistake. They all look alike after a while, you know.
"Ask not for whom the bell tolls; It tolls for thee..."
|
|
|
|