VB6 Service Running On Windows 2000, Icon In Tray
I have VB6 program running as a Service on Windows 2000, I also have a Icon in the System Tray... If I log off, the service craps out with an error, which is not a real problem, because it is just set to restart itself after a minute. (I'll look into the crashing later)..
If I log back in, how can I have the service put the Icon back into the System Tray?
View Complete Forum Thread with Replies
See Related Forum Messages: Follow the Links Below to View Complete Thread
Service And Sys Tray Icon
I have an application that i have finally been able to get to run as a service and also have an icon in the system tray. The only problem is that it will not start as a service correctly. I get the following error in the event log:
The description for Event ID ( 105 ) in Source ( ATRN Client) cannot be found. The local computer may not have the necessary registry information or message DLL files to display messages from a remote computer. The following information is part of the event: .
The program will start as a service correctly with the icon in the system tray if I start it manualy but not automatically on boot.
Does any one have any ideas on how I can fix this. Other than this, the app runs exactly as expected and there are no other problems.
-Korendir
Tray Icon & Service
Hello gurus,
I've written a service, which needs to get informed, when a user logs on, so that I can put my icon into the systray. Is there any Win Message I can look for, or has anybody a better idea, how I can put my icon into the systray, if the user logs on? At the moment I'm using an API Timer function, which tests every XY seconds, if the icon can be installed, but that's a quite dumb method.
NT Service Works But Task Tray Icon Disappears?
I have created a VB program that works great as a service. I starts automatically and stays running when a user logs off and back on again, and restarts when the system is rebooted.
The only problem that I am having is making sure that the tray icon returns after a reboot or if one user logs off and another logs on. When I log on (as administrator) and start the service the tray icon appears like it should. When I log off and another user logs on (or I log back on) the tray icon doens't come back. The service remains running but no tray icon??? I want the tray icon to be there for all users?
Any ideas?
Thanks!
VB6 Service On Windows 2000, Sending/recieving Mail Via Outlook 2000
I have a service running, when I try to connect to a MAPI Session it gives me an "-2147221231 Collaboration Data Objects - [MAPI_E_LOGON_FAILED] (80040111)" error.
If I run it as just a regular Executable and NOT a service it connects fine...
I pass the profile on the .login line....
Any Ideas?
Icon Behaviour With VB App Running As NT Service
Hello,
My question concerns convincing my System Tray icon to behave elegantly.
I have written a VB6 app that I need to run as a NT Service; as such, I've made use of the Microsoft NT Service Control Component provided by Ntsrv.ocx. This approach has worked like a charm and I'm very happy with the results except for one thing: If I log out and back in again my service is still running, and that's all well and good, but my application's icon no longer appears in the System Tray.
I have set up a timer firing every second that calls Shell_NotifyIcon and of course this works. However, I don't want to have this timer continuing to operate once the icon is successfully added to the tray. Now you might say I should disable the timer when Shell_NotifyIcon returns <> 0 and you'd be right, except for the folowing little problem.
The Problem: My service starts manually by design so of course when the app adds the icon to the tray on startup it works just fine, but I can't disable my timer at this point because I'll need it running if a user logs out and back in again. I could use a "hook" to catch messages like "WM_QUERYENDSESSION" and start the timer, but again I don't want the thing running the entire time someone is logged out.
So I believe I need a way of knowing when someone is logging back in, I could start my timer at this point and then disable it when Shell_NotifyIcon returns successfully.
If anyone out there has had some experience with these issues, or has anything insightful for me I'd sure appreciate it.
Oh, this is my first post, so sorry if I was too long-winded.
Thanks in advance!
Running A Service To Automate Repetitive Actions - With A Taksbar Icon If Possible
Hi guys,
i am looking into developing an application that let's repetitive tasks to be automated, of possible with a taskbar icon or so..
Meaning this should be a service or so... dunno..
the application should run in the background and send text strings to another application for pasting text in a form...
Any ideas would be appreciated..
--
Lobo
There are 10 ways of doing things.. Right or wrong.
Windows 2000 Service
Anyone know how to create a service on an nt2000 system? Or register their standard exe as a service?
System Tray Icon For Windows XP SP3
I need to have a system tray icon placed in the system tray, everytime the computer is logged onto the Internet or something online and using a modem or network as such as that.
Also how do you place ToolTipTexts for a program in the system tray.
Also I need to have a context menu placed on the icon as well. I require the following Restore, About, Exit (Logout). Which is to close off the program that the icon is assoicated with. And not to log off the internet or anything like that.
I have seen on some Windows Forms that they can minimise to system tray. I also need that on the Form that is in the System Tray.
Windows Service Running
How can I verify if a Windows Service such as Telnet is up and running on a remote server using a VB Script?
Windows 2000 System Tray
Hey,
I upgraded to Windows 2000 from 98 and I noticed that
system tray icons have a really SHlTTY resolution like on
the taskbar. This was not the case in win 98.
I guess it's because NT was like that and win2k is
based on NT. Correct me if I'm wrong. Is there a way
to fix this?
Windows Crash = No Mo Monkey Icon In Sys Tray!!!
and frankly, it makes me sad =(how might i go about checking to see if my icon is there or not and put it back if it's gone?
i'm thinking i have to check to see if it's there, blow it up if it aint then re-create it or something, cause updating doesn't work =P
Getting Windows User While Running App As Service
Hi,
I have always been able to get the current Windows XP user using API. But now I have changed my app to run as a system service and it always returns SYSTEM as the current user. Does anyone know how to get the current user logged on even with my app as a system service? Does it write to the registry the current user logged on so i can just read that possibly?
Thanks!
Creating Windows 2000 Startup Service
I want to create a windows 2000 stratup service for an application exe. How to do that? Please tell me as early as possible.
I am developing an application for in out of employees using barcode. If i scan the barcode the data should be stored in the database. But at that time the computer should be with Ctrl+Alt+Del screen i.e no one is logged on that computer.
Running MySql Connection As A Windows Service
I have been given an exercise to design a simple form in which the user enter 2 SQL queries. The queries are executed displaying the results and time it took to execute. This would be fairly simple apart from the fact that the DB connection and execution time need to be run as a windows service.
I have no idea where to start when it comes to windows services. Can anybody point me in the right direction
Winsock Running From Windows Service Problem
Hi all,
I am writting some VB6 code using winsock to connect to an external ip address. The code works fine when I run it from VB or as an EXE. But when I install it and run as a service on Windows 2000 it errors with '10049 : Address is not available from the local machine'
I am using the svcit.ocx to make my vb code a windows service.
Please help!
Thanks in advance.
10Leo
Creating A Windows 2000 Service Using Visual Basic
Hi All
I got a exe which i want to make it a Windows 2000 service can any body tell me how to write a service in Visual Basic.Help very much appreciated and if u can give me any links that is going to be great.
Thanks in Advance
Madhu
System Tray (SysTray) Icon Does NOT Show In Windows VISTA
Hello... I've been using the Shell_NotifyIcon API's in VB 6.0 as demonstrated in this forum. It works perfectly well on Win2K, XP, 2003, Terminal Server and even Citrix. But the Icon will NOT appear in Windos VISTA. I would appreciate any help. I've tried everything I can think of with no results.
Jacob
Imaging101, Inc.
http://www.imaging101.com
Edited by - JacobRusso on 5/17/2007 1:33:54 PM
System Tray && Running Program When Logging On To Windows
Ok, here's my dilemma. My program appears in the system tray, and i have the form's windowstate property set to 1-minimized because the program starts up when you log on to windows, and I do not want the main screen of my program to appear everytime the user starts a Windows session. Unfortunately, this means that when the user double clicks the icon to open the program, only the program's icon will appear in the system tray and the user has to double click it to open my program. I'm worried that the user will not see the icon in the system tray.
How could I get my program to open in it's normal windowstate when the user double clicks its icon and for it to open minimized in the system tray when the user starts a Windows session and hasn't clicked on the icon?
VB6 Program Running As Windows Service Interfering With MS Office
Hi there,
I have written a program which uses NTSVC.ocx to run the program as a service. My program simply checks a folder every x seconds to see if a new input file has arrived, processed this file and from that file determines which rule set is required, which is then read from an excel file.
The input data and the rules are then passed to a C++ dll which attempts to find a solution and then returns the solution, if found.
When I install the program as a service and run it, all is well. But when the program finds a file to process, the windows office installer activates. A user has a slightly different problem in that when the service is running they can't open an Excel file from Windows Explorer, but they can by opening Excel and then using File > Open.
Has anyone seen a problem like this before? I have just tried removing the MS Excel reference from the project and the interference no longer appears to occur. Is there a way to prevent this?
Balloon-style Tooltips For Windows 2000 System Tray
I am having trouble adding a balloon tooltip (win2k only) with its stem pointing to the icon in the system tray. I found new NOTIFYICONDATA type, but I have trouble getting it to work in Visual Basic. Any ideas?
File Read Code Not Working While Running As Windows Service.. Pls Help Me Out
Hi , please help. I have done a small application to read a xml file and copy the requirement contents to another text file in a fixed format. all these need to be run as a windows service during specfic intervals.
the code is working when it is executed separately with out making as service. but when i place that code in a timer function and make the application as service, the file read code is not working. please help me out ... i need to submit this assigment today.
MS Knowledge Base Bugs Fixed In Windows 2000 Service Pack 3 (SP3) List
Can anyone suggest from where these Hotfixes can be downloaded before the release of SP3!!
For problems relating to COM+, Memory leakages ...etc..some of the bugs are identified and fixed and are ready to be released with windows SP3. List of some of the bugs and Fixes :
1) 283106 FIX: Aggregating ADO Recordsets or Commands May Cause Memory Leak
2) 289118 FIX: Audit Failures in Security Event Log When You Call Component Services Objects
3) 289782 INFO: Post Windows 2000 Service Pack 2 COM+ Rollup Hotfix 8 Is Available
4) 289821 FIX: COM+ Application Proxy Does Not Register CLSID After You Install COM+ Rollup Hotfix 5
5) 291244 INFO: Post Windows 2000 Service Pack 2 COM+ Rollup Hotfix 9 Is Available
6) 291557 FIX: Remote Transient COM+ Event Subscription Does Not Work
7) 292039 FIX: Unable to Replicate COM+ Package Due to Path Not Found 0x80070003
8) 292804 FIX: Transactions May Not Be Aborted for Some Exceptions
9) 293340 FIX: MS DTC May Reject Legal End Tag "
" for PULL and PUSH Messages
10) 293344 FIX: MS DTC Sends Inappropriate Responses to QUERY Message
11) 293646 FIX: Memory Leak When Security Is Enabled on COM+ Component
12) 294510 INFO: Post Windows 2000 Service Pack 2 COM+ Rollup Hotfix 10 Is Available
13) 295549 INFO: Post Windows 2000 Service Pack 2 COM+ Rollup Hotfix 11 Is Available
14) 296397 FIX: MS DTC Fails to Handle the "COMMITTED
PULL
" TIP Pipelining Command
15) 296775 FIX: COM+ User Events Are Lost with Multiple Subscriber Clients
16) 297146 FIX: Event System Stops Responding When COM+ LCE Transient Subscriber Is Disconnected
17) 297536 INFO: Availability of Windows 2000 Post-Service Pack 2 COM+ Hotfix Rollup Package 12
18) 298012 Malformed RPC Request Can Cause Service Problems
19) 298127 FIX: New STA Object Cannot Join Caller's STA If the Caller Is Not Configured
20) 299407 INFO: Post Windows 2000 Service Pack 2 COM+ Rollup Hotfix 13 Is Available
21) 300367 DCOM Authentication May Induce Delays and Potentially Put Memory on the Wire
22) 300408 LDAP Errors Are Returned Under Combination of Load and Duration
23) 301117 Slow Performance Transferring Large Data Blocks with RPC
24) 302845 INFO: Availability of Windows 2000 Post-Service Pack 2 COM+ Hotfix Rollup Package 14
25) 303685 FIX: COM+ Leaks Memory When Security Check Fails
26) 303890 INFO: Application Startup and Shutdown Events Are Now Available in COM+
27) 306414 FIX: ODBC Connection from COM+ Component May Connect to Wrong Database
28) 306417 INFO: Availability of Windows 2000 Post-Service Pack 2 COM+ Hotfix Rollup Package 15
29) 306483 Access Violation in LSASS When There Are Low-Memory Conditions
30) 307383 Memory Usage Increases When Microsoft Distributed Coordinator (Msdtc.exe) Runs Under Stress
Running Setup In Windows 2000
hi i have developed the application in vb and access in xp o/s.
and i have also created a setup.
when i run setup in WINDOWS2000 it gives the error c:program filesprojectfolder could not be created.
i have 2 operating system xp and 2000.
so please help me in this regard
with regards
ashok
Running Visual Basic 3 On Windows 2000
We have an application that is written in Visual Basic 3.0 with quite a number of Third Party software. When we run the application on workstations that are using Windows 2000, it runs correctly but the error messages are unreadable. Is there a simple solution to this problem?
Combobox Text All Selected When Running Under Windows 2000
I have a form with a number of comboboxes all bound to a recordset. When the form is displayed on a system running Windows 98 everything works ok, but when running on a system with Windows 2000 all the text in all the comboboxes is selected. Also sometimes on the Windows 2000 machine some of the text in the textboxes doesn't display even though it's in the recordset and always displays when running under Windows 98.
Anyone run into this problem before and/or any solutions?
Thanks!
Problem Running Ucase, Mid And Date Functions In VB 6 Under WIndows 2000
I have a problem running my program in Windows 2000. I develop the source in Visual basic 6.0 under Windows XP. I install Visual Basic 6 in Windows 2000 and copy the source program onto the computer with the Windows 2000 as the OS. the problem is the mid, ucase and date functions don't run in the computer with Windows 2000. What might be the problem? I am suspecting that VB 6 did not properly install in Windows 2000 , perhaps I might first login with administrator account or account that can write to the registry...Is my guess correct??
Stop Running Windows Installer And Microsot Office 2000
Hi
I have placed a editor ie DHTMlEdit control in my form when i run the form it asks for Microsoft Office 2000 premium cd if i click cancel then it goes in to the form.This happens before the form is about to load.My requirement is anycode to automatically cancel this dialog box but this dialogbox appears before the form load where to insert the code to cancel the dialogbox automatically.I tried to create the Editor control at runtime so that we can trap the error after the formload but in vain iam not able to get the code for creating Editor at runtime..
Any solutions will be appreciated..
Thanks in advance
VB 6 Application Running On French Windows With English SQL 2000 Server
Hi, all,
I have this VB 6 application developed on English Windows 2000. It runs
against an English SQL 2000 server. When the application is installed on
a French Windows XP, I have an ODBC problem. The application is doing a
date search and the error message says "[ODBC Server Driver][SQL Server]
Syntax
error converting datetime from character string.." I figure it is
because the SQL server does not recognize the French date string but how
do I resolve this problem?
Thanks!
Jonathan
What's In The System Tray (Not Putting A Icon In The Tray)
Does anyone know of a way to find out what icons are registered and retrieve their NOTIFYICONDATA. Or if you can't find out which ones are already in the tray do you know of a way to be notified when new icons are added using Shell_NotifyIcon?
*Resolved* Removing Taskbar Icon In Run-time (NOT System Tray Icon)
I wrote my own mp3 player ('cause Winamp sucks ), and one of the features is a very small, unobtrusive window:
I need to remove the taskbar icon, 'cause it looks dumb with a blank icon among the others.
Anyone have any ideas? All searches keep pointing to system tray icons
___________________________
Dave Applegate
Microsoft VB MVP, ACE [FAQs]
My friend has a trophy wife, but apparently she wasn't in first place.
Edited by - Metallisoft on 3/15/2004 1:39:05 PM
Updating Icon In Icon Tray ( The One Next To The Clock) *RESOLVED*
Hey all!
I have an icon of my app loaded in the icon tray ( Is the one next to the clock... isnt it? ) So... I need to update the icon sometimes, as ICQ does. I am using the delete/insert method to do this... But I would like to avoid this kind of method cause it makes the icon tray "shake". I did read sometime ago, a code that adds to the api code of icon tray the function to update the icon, without deleting it. But I am not finding it anymore.
Someone have this code to give to me please?
Thanks in advance,
Elminster
Hot To Put The Application Icon On The Icon Tray
Hi guys! I'm new here and I am currently finishing an application and I don't want it to appear on the task bar instead I want it to appear on the Icon tray. Can anyone help me with my delema?
Running As Application Vs. Running As A Service
How do I tell an existing application to run as a service over there on the taskbar next to the system time? Would I be introducing any limitations by converting a program from running as a program to a service? Thank you.
Please Help Me To Implement RunAs In Windows Service On Windows 2003 Server ...
Hello to all Forum Members;
Currently I'm working on a Monitoring Service which is intended to monitor the status of configured Applications and other Windows Services and restart if any of those are found not running. It works smooth with Windows Services; however I'm facing some problems while making the Service to start the third party Applications that have Database backend via ODBC or ADO.
I register my Windows Service as "Interactive with Desktop" under "LocalSystem" account on Windows 2003 Server. If I configure an Application such as Notepad or similar then there is no problem; but if there any application that has Database backend then the problem starts! These applications are not getting started properly. One of such applications is VoIPSwitch which says that it failed to connect to Database as either database drivers are not found or database does not exists! Both reasons are wrong as I can start the same application with the double click on same Executable file; it's just my Windows Service that's not able to start the application.
I received a suggestion to implement the RunAs for starting such applications with User Name and Password passed to it. So, for my quick testing I quickly searched for RunAs code module and found two examples on Planet Source Code, one of which I'm currently implementing in my code, too. You can download it for your reference from following URL:
http://www.orbitfiles.com/download/id1291685973
When I implemented it in my Monitoring Service and checked my Service Log (which I have coded to be written to ServiceLog.log file; this is not Windows Event Log), I got to see the error as returned by RunAs code: Access Denied!
I specified the same User Name and Password that I give while logging to my Windows 2003 Server (on which this Service is running) for RunAs and still I'm getting this error! The interesting thing is ... when I executed the RunAs VB code (the link above points to the same code) on the same Server by double-click it's icon and then with same User Name and Password, then it started the specified application without any problem! I feel there is no problem in the RunAs code; but it's the Windows Service (which is under Local System account) is not getting permission from Windows 2003 Server!
Am I missing something here? What's going wrong? Why Access Denied error is giving by Windows 2003 when Service attempts to start the application? I'm absolutely clueless right now; please give me some suggestion/solution to resolve this error!
Waiting for your valuable reply ...
Regards,
Ruturaaj.
Please Help Me To Implement RunAs In Windows Service On Windows 2003 Server ...
Hello to all Forum Members;
Currently I'm working on a Monitoring Service which is intended to monitor the status of configured Applications and other Windows Services and restart if any of those are found not running. It works smooth with Windows Services; however I'm facing some problems while making the Service to start the third party Applications that have Database backend via ODBC or ADO.
I register my Windows Service as "Interactive with Desktop" under "LocalSystem" account on Windows 2003 Server. If I configure an Application such as Notepad or similar then there is no problem; but if there any application that has Database backend then the problem starts! These applications are not getting started properly. One of such applications is VoIPSwitch which says that it failed to connect to Database as either database drivers are not found or database does not exists! Both reasons are wrong as I can start the same application with the double click on same Executable file; it's just my Windows Service that's not able to start the application.
I received a suggestion to implement the RunAs for starting such applications with User Name and Password passed to it. So, for my quick testing I quickly searched for RunAs code module and found two examples on Planet Source Code, one of which I'm currently implementing in my code, too. You can download it for your reference from following URL:
http://www.orbitfiles.com/download/id1291685973
When I implemented it in my Monitoring Service and checked my Service Log (which I have coded to be written to ServiceLog.log file; this is not Windows Event Log), I got to see the error as returned by RunAs code: Access Denied!
I specified the same User Name and Password that I give while logging to my Windows 2003 Server (on which this Service is running) for RunAs and still I'm getting this error! The interesting thing is ... when I executed the RunAs VB code (the link above points to the same code) on the same Server by double-click it's icon and then with same User Name and Password, then it started the specified application without any problem! I feel there is no problem in the RunAs code; but it's the Windows Service (which is under Local System account) is not getting permission from Windows 2003 Server!
Am I missing something here? What's going wrong? Why Access Denied error is giving by Windows 2003 when Service attempts to start the application? I'm absolutely clueless right now; please give me some suggestion/solution to resolve this error!
Waiting for your valuable reply ...
Regards,
Ruturaaj.
Tray Icon
I have an app that resides in the systray and it works fine. However when Explorer has an error and has to "restart", my tray icon dissapears but my app is still running. Other programs such as aim and msn still have there icons in the tray. What is the best way to keep my icon in the systray when explorer fails? -Thanks
Tray Icon
I have an app that I have built with a tray icon. I want to have the graphics switch when my program is in certain functions. I need to know how to go about doing this. Thanks in advance for all replies.
Tray Icon ?
say..i wanna make an app that will appear as a tray icon if i minimize it
help me pls
Tray Icon
Hi. i already know how to create a tray icon but the program im writing now runs at startup as Administrator. when i logon as Administrator the icon isnt in the systray. How can i fix this?
I think a possible way would be to make it run on logon and if app.previnstance then talk to the first instance and tell it to add the icon again. im not sure how that would work tho
Tray Icon
I have an app that puts an icon in the system tray. But when there is an error in Explorer(when it has to be closed and restarted), my icon in the system tray has gone but the program is still running. Other apps like AIM and MSN are still in the tray. How can i keep my icon in the system tray after Explorer crashes?
Tray Icon
I have an application that minimizes to the system tray.On unloadibg the icon stays there until the cursor is moved over the tray, then it disapears...
the unload cade is
Shell_NotifyIcon NIM_DELETE, TrayI
any ideas on why it persists?
"No one can know everything, only so much as to drive us to look for the rest." -PrOpHeT-
|