j'essai d'implementer un service windows avec C# , tout a l'aire de bien
fonctionner , sauf une petite chose .
lorsque j'envoi une commande au service via un autre programme , comme ceci
TheController.ExecuteCommand (command) ;
l'argument "command" est un int32 , mais cela ne fonctionne que pour
certaines valeurs du parametre "command"
par exemple ca fonctionne tres bien pour des valeurs 200 , 201 , 210, 220
etc ... , par contre
ca genere un exception "InvalidArgument" pour des valeurs comme 0, 1, 700,
755 etc
si quelqu'un a deja implementer un service windows et qui s'y connait un peu
, ca serais sympa de m'eclairer ,
Cette action est irreversible, confirmez la suppression du commentaire ?
Signaler le commentaire
Veuillez sélectionner un problème
Nudité
Violence
Harcèlement
Fraude
Vente illégale
Discours haineux
Terrorisme
Autre
Paul Bacelar
"Jean yves" wrote in message news:
Bonjour ,
j'essai d'implementer un service windows avec C# , tout a l'aire de bien fonctionner , sauf une petite chose . lorsque j'envoi une commande au service via un autre programme , comme
ceci
TheController.ExecuteCommand (command) ;
l'argument "command" est un int32 , mais cela ne fonctionne que pour certaines valeurs du parametre "command"
par exemple ca fonctionne tres bien pour des valeurs 200 , 201 , 210, 220 etc ... , par contre
ca genere un exception "InvalidArgument" pour des valeurs comme 0, 1, 700, 755 etc
si quelqu'un a deja implementer un service windows et qui s'y connait un
peu
, ca serais sympa de m'eclairer ,
Restez dans les clous ;-) (entre 128 et 255)
Instead, a Windows Service's standard interface allows for a "custom command." This is a command sent to the Windows Service in the form of a numeric code. The code can be any number between 128 and 255. (The operating system reserves numbers under 128.) A custom command is sent to a service with the ServiceController's ExecuteCommand method. The command is then received in an event inside the service called the OnCustomCommand event.
-- Paul Bacelar
"Jean yves" <akdimo@yahoo.fr> wrote in message
news:O4AM0FAqFHA.2416@TK2MSFTNGP10.phx.gbl...
Bonjour ,
j'essai d'implementer un service windows avec C# , tout a l'aire de bien
fonctionner , sauf une petite chose .
lorsque j'envoi une commande au service via un autre programme , comme
ceci
TheController.ExecuteCommand (command) ;
l'argument "command" est un int32 , mais cela ne fonctionne que pour
certaines valeurs du parametre "command"
par exemple ca fonctionne tres bien pour des valeurs 200 , 201 , 210, 220
etc ... , par contre
ca genere un exception "InvalidArgument" pour des valeurs comme 0, 1, 700,
755 etc
si quelqu'un a deja implementer un service windows et qui s'y connait un
peu
, ca serais sympa de m'eclairer ,
Restez dans les clous ;-) (entre 128 et 255)
Instead, a Windows Service's standard interface allows for a "custom
command." This is a command sent to the Windows Service in the form of a
numeric code. The code can be any number between 128 and 255. (The operating
system reserves numbers under 128.) A custom command is sent to a service
with the ServiceController's ExecuteCommand method. The command is then
received in an event inside the service called the OnCustomCommand event.
j'essai d'implementer un service windows avec C# , tout a l'aire de bien fonctionner , sauf une petite chose . lorsque j'envoi une commande au service via un autre programme , comme
ceci
TheController.ExecuteCommand (command) ;
l'argument "command" est un int32 , mais cela ne fonctionne que pour certaines valeurs du parametre "command"
par exemple ca fonctionne tres bien pour des valeurs 200 , 201 , 210, 220 etc ... , par contre
ca genere un exception "InvalidArgument" pour des valeurs comme 0, 1, 700, 755 etc
si quelqu'un a deja implementer un service windows et qui s'y connait un
peu
, ca serais sympa de m'eclairer ,
Restez dans les clous ;-) (entre 128 et 255)
Instead, a Windows Service's standard interface allows for a "custom command." This is a command sent to the Windows Service in the form of a numeric code. The code can be any number between 128 and 255. (The operating system reserves numbers under 128.) A custom command is sent to a service with the ServiceController's ExecuteCommand method. The command is then received in an event inside the service called the OnCustomCommand event.
-- Paul Bacelar
Jean yves
ah ok ok ok :-)
"Paul Bacelar" a écrit dans le message de news: #
"Jean yves" wrote in message news: > Bonjour , > > j'essai d'implementer un service windows avec C# , tout a l'aire de bien > fonctionner , sauf une petite chose . > lorsque j'envoi une commande au service via un autre programme , comme ceci > TheController.ExecuteCommand (command) ; > > l'argument "command" est un int32 , mais cela ne fonctionne que pour > certaines valeurs du parametre "command" > > par exemple ca fonctionne tres bien pour des valeurs 200 , 201 , 210,
220
> etc ... , par contre > > ca genere un exception "InvalidArgument" pour des valeurs comme 0, 1,
700,
> 755 etc > > si quelqu'un a deja implementer un service windows et qui s'y connait un peu > , ca serais sympa de m'eclairer , > >
Restez dans les clous ;-) (entre 128 et 255)
Instead, a Windows Service's standard interface allows for a "custom command." This is a command sent to the Windows Service in the form of a numeric code. The code can be any number between 128 and 255. (The
operating
system reserves numbers under 128.) A custom command is sent to a service with the ServiceController's ExecuteCommand method. The command is then received in an event inside the service called the OnCustomCommand event.
-- Paul Bacelar
ah ok ok ok :-)
"Paul Bacelar" <paul.bacelar@PASDESPAMlaposte.net> a écrit dans le message
de news: #GAB6iorFHA.3228@TK2MSFTNGP11.phx.gbl...
"Jean yves" <akdimo@yahoo.fr> wrote in message
news:O4AM0FAqFHA.2416@TK2MSFTNGP10.phx.gbl...
> Bonjour ,
>
> j'essai d'implementer un service windows avec C# , tout a l'aire de bien
> fonctionner , sauf une petite chose .
> lorsque j'envoi une commande au service via un autre programme , comme
ceci
> TheController.ExecuteCommand (command) ;
>
> l'argument "command" est un int32 , mais cela ne fonctionne que pour
> certaines valeurs du parametre "command"
>
> par exemple ca fonctionne tres bien pour des valeurs 200 , 201 , 210,
220
> etc ... , par contre
>
> ca genere un exception "InvalidArgument" pour des valeurs comme 0, 1,
700,
> 755 etc
>
> si quelqu'un a deja implementer un service windows et qui s'y connait un
peu
> , ca serais sympa de m'eclairer ,
>
>
Restez dans les clous ;-) (entre 128 et 255)
Instead, a Windows Service's standard interface allows for a "custom
command." This is a command sent to the Windows Service in the form of a
numeric code. The code can be any number between 128 and 255. (The
operating
system reserves numbers under 128.) A custom command is sent to a service
with the ServiceController's ExecuteCommand method. The command is then
received in an event inside the service called the OnCustomCommand event.
"Jean yves" wrote in message news: > Bonjour , > > j'essai d'implementer un service windows avec C# , tout a l'aire de bien > fonctionner , sauf une petite chose . > lorsque j'envoi une commande au service via un autre programme , comme ceci > TheController.ExecuteCommand (command) ; > > l'argument "command" est un int32 , mais cela ne fonctionne que pour > certaines valeurs du parametre "command" > > par exemple ca fonctionne tres bien pour des valeurs 200 , 201 , 210,
220
> etc ... , par contre > > ca genere un exception "InvalidArgument" pour des valeurs comme 0, 1,
700,
> 755 etc > > si quelqu'un a deja implementer un service windows et qui s'y connait un peu > , ca serais sympa de m'eclairer , > >
Restez dans les clous ;-) (entre 128 et 255)
Instead, a Windows Service's standard interface allows for a "custom command." This is a command sent to the Windows Service in the form of a numeric code. The code can be any number between 128 and 255. (The
operating
system reserves numbers under 128.) A custom command is sent to a service with the ServiceController's ExecuteCommand method. The command is then received in an event inside the service called the OnCustomCommand event.