I have a Windows Service that should pop a windows form right before logoff,
for the user to enter some information.
I got things working fairly well except that the user does not get to see
the form before logoff. But I know that it run properly because when I log
back in the form is there and works fine.
So the form opened and run, but windows was already in the "logoff" screen
with no desktop showing, so I missed the form.
Is there any way for a Service to capture the logoff before windows actually
logsoff? Or is there any better way to pop a form that the user needs to fill
out before they logoff?
Thanks 3 2277
"fhunter" <fh*****@discus sions.microsoft .comwrote in message
news:3C******** *************** ***********@mic rosoft.com...
>I have a Windows Service that should pop a windows form right before logoff,
for the user to enter some information.
I got things working fairly well except that the user does not get to see
the form before logoff. But I know that it run properly because when I log
back in the form is there and works fine.
So the form opened and run, but windows was already in the "logoff" screen
with no desktop showing, so I missed the form.
Is there any way for a Service to capture the logoff before windows
actually
logsoff? Or is there any better way to pop a form that the user needs to
fill
out before they logoff?
This link may give an example to implement something. http://www.codeproject.com/csharp/sy...ntshandler.asp
The Windows application should be doing this if possible to prevent logoff,
until data has been entered in the application.
Maybe you can do something with the Windows O/S Group Policy to run the
program during logoff. I think you can run a logoff script using a Group
Policy, use Google look it up.
A Windows Service application popping-up some Windows form should not be in
the picture, IMHO.
I think that article might help. Thanks.
I did try this as a script and I got the same problem. That is why I gave
the service a try. It seemed easier to install and uninstall.
I am curious, why do you think that: "A Windows Service application
popping-up some Windows form should not be in the picture" ?
"Mr. Arnold" wrote:
>
"fhunter" <fh*****@discus sions.microsoft .comwrote in message
news:3C******** *************** ***********@mic rosoft.com...
I have a Windows Service that should pop a windows form right before
logoff,
for the user to enter some information.
I got things working fairly well except that the user does not get to see
the form before logoff. But I know that it run properly because when I log
back in the form is there and works fine.
So the form opened and run, but windows was already in the "logoff" screen
with no desktop showing, so I missed the form.
Is there any way for a Service to capture the logoff before windows
actually
logsoff? Or is there any better way to pop a form that the user needs to
fill
out before they logoff?
This link may give an example to implement something.
http://www.codeproject.com/csharp/sy...ntshandler.asp
The Windows application should be doing this if possible to prevent logoff,
until data has been entered in the application.
Maybe you can do something with the Windows O/S Group Policy to run the
program during logoff. I think you can run a logoff script using a Group
Policy, use Google look it up.
A Windows Service application popping-up some Windows form should not be in
the picture, IMHO.
"fhunter" <fh*****@discus sions.microsoft .comwrote in message
news:AB******** *************** ***********@mic rosoft.com...
>I think that article might help. Thanks.
I did try this as a script and I got the same problem. That is why I gave
the service a try. It seemed easier to install and uninstall.
I am curious, why do you think that: "A Windows Service application
popping-up some Windows form should not be in the picture" ?
This is my take on a NT Service application, below. But that's not to say
that a Windows application cannot communicate with a NT Service
application.. But have a NT service application that it's sole purpose is to
pop a screen to the user, which in your case, may be too late, I would find
other means.
That's just me. It's your solution and you do what you have to do to make it
work. http://www.commsoft.com/services.html This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Reader |
last post by:
I have an application that allows a user to enter a user name, user password, and the domain or machine name. From this information I would like to verify the user account and password is valid. This must work for either a domain or a local machine account. I have tried to find examples from the web and it seems every example that I have found does not work or produces odd results.
I have tested each of these on Windows 2000, Windows XP,...
|
by: Brad Jones |
last post by:
Hello, I'm hoping someone can give me some help or guidance here. I'm not
sure if this is even the best group to post to for this.
Our OEM equipment's software architecture relies heavily on a "master"
windows service. This responsibility of this service is to launch 10 or so
other applications, some of which have GUI's. These applications need to be
running whether somebody is logged in or not. There is no communication
required between...
|
by: Mullin Yu |
last post by:
if i put the same code at the windows application or console, i can logon to
the computer. but, if i put the same code at the windows service and start
it, i still can't logon to the machine.
the return value is TRUE.
i tested it by going to windows explorer and then click that computer.
my coding at windows service:
|
by: deko |
last post by:
When to use a privileged user thread rather than a windows service?
That's the question raised in a previous post . It was suggested that if the service needs to interact
with a WinForms app (which is the UI used to adjust the actions taken by,
and the schedule of the service), then a privileged user thread should be
used in the UI - no service required.
But...
"A windows service enables the creation of long-running executable
|
by: Eduard Witteveen |
last post by:
Dear list,
In the corporation, we want to know who is using which computer, and do
some phone routing based upon this information.
When a user log's uses it's account to login, the phone on the desk
should also ring on the same desk. When the user leave's / sleeping, we
dont want the phone to ring, so we want to detect this also.
By using a service i can keep a program running, without irritating the
users with icon's / message's at...
| |
by: tshad |
last post by:
What would be a good way to check programmatically whether a service was
running?
We have a service that dies periodically and I need to check to see if this
service is running. I know how to check to see if the status is in stopped
or running mode. But that doesn't tell me if it is actually running.
I need to know this so that if it happens I can programmatically start the
same service on another machine.
|
by: =?Utf-8?B?TVNU?= |
last post by:
To demonstrate my problem, I have a very simple VB Windows application. It
has a text box that is used to display a counter, a button to reset the
counter, and a timer that increments the counter every second.
I remote desktop to the computer hosting this application and run the
application. It starts up and displays the counter incrementing every
second. If I disconnect the network cable between the two computers for 10
seconds and...
|
by: roberth |
last post by:
Hi,
I've created a simple Windows Service that starts an .exe with
Process.Start(). However, I've noticed that when I logoff from one
user account to another the child process (.exe) is shutdown (although
the service is still running). This behaviour makes my Windows service
useless, as all the hard work is done by the .exe (not written in C#).
Is there a way to prevent this from happening?
Cheers,
|
by: CyberSoftHari |
last post by:
I want to get applications running (Showing) in Task bar (and show those applications running) and Cancel windows LogOff, Shutdown, Restart when user try to Click windows LogOff, Shutdown, Restart
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: isladogs |
last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM).
In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules.
He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms.
Adolph will...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: TSSRALBI |
last post by:
Hello
I'm a network technician in training and I need your help.
I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs.
The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols.
I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |