Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. Windows Service

Windows Service

Scheduled Pinned Locked Moved Visual Basic
helpcsharpsysadmindata-structures
5 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • H Offline
    H Offline
    H is here
    wrote on last edited by
    #1

    Hello I' have a problem with starting a windows service programmed in VB.Net In all OS (win2000 and upper) the service runs sucessfully ,but in one specific computer with (win2000 Server) the service give's me this error: Service cannot be started. System.InvalidCastException: Cast from string "4/" to type 'Integer' is not valid. ---> System.FormatException: Input string was not in a correct format. at Microsoft.VisualBasic.CompilerServices.DoubleType.Parse(String Value, NumberFormatInfo NumberFormat) at Microsoft.VisualBasic.CompilerServices.IntegerType.FromString(String Value) --- End of inner exception stack trace --- at Microsoft.VisualBasic.CompilerServices.IntegerType.FromString(String Value) at RufosFileWatcher.RufosFileWatcher.OnStart(String[] args) at System.ServiceProcess.ServiceBase.ServiceQueuedMainCallback(Object state) Can someone help me on this ?? Thanks

    D 1 Reply Last reply
    0
    • H H is here

      Hello I' have a problem with starting a windows service programmed in VB.Net In all OS (win2000 and upper) the service runs sucessfully ,but in one specific computer with (win2000 Server) the service give's me this error: Service cannot be started. System.InvalidCastException: Cast from string "4/" to type 'Integer' is not valid. ---> System.FormatException: Input string was not in a correct format. at Microsoft.VisualBasic.CompilerServices.DoubleType.Parse(String Value, NumberFormatInfo NumberFormat) at Microsoft.VisualBasic.CompilerServices.IntegerType.FromString(String Value) --- End of inner exception stack trace --- at Microsoft.VisualBasic.CompilerServices.IntegerType.FromString(String Value) at RufosFileWatcher.RufosFileWatcher.OnStart(String[] args) at System.ServiceProcess.ServiceBase.ServiceQueuedMainCallback(Object state) Can someone help me on this ?? Thanks

      D Offline
      D Offline
      Dave Kreskowiak
      wrote on last edited by
      #2

      It looks like the command line arguments you supplied to start the service don't have a space in them where one should be. Mind you, this is a wild guess based soley on the stack trace you posted. RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

      H 1 Reply Last reply
      0
      • D Dave Kreskowiak

        It looks like the command line arguments you supplied to start the service don't have a space in them where one should be. Mind you, this is a wild guess based soley on the stack trace you posted. RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

        H Offline
        H Offline
        H is here
        wrote on last edited by
        #3

        Thanks for your reply OK but I don´t pass any arguments to start the service. Do you mean OnStart(String[] args)? I just use the installutil -i (Service name) and to start the service I use the serviceController: Dim Myservice as new ServiceController("Name of the service") Myservice.start MyService.Refresh But if I use the start in the services panel it give´s me the same error. Thanks

        D 1 Reply Last reply
        0
        • H H is here

          Thanks for your reply OK but I don´t pass any arguments to start the service. Do you mean OnStart(String[] args)? I just use the installutil -i (Service name) and to start the service I use the serviceController: Dim Myservice as new ServiceController("Name of the service") Myservice.start MyService.Refresh But if I use the start in the services panel it give´s me the same error. Thanks

          D Offline
          D Offline
          Dave Kreskowiak
          wrote on last edited by
          #4

          It looks like it's complaining about something in your OnStart code. Is this .EXE known to be exactly the same as the copies on the other machines? Does the machine have the correct version of the .NET Framework and any service packs on it? RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

          H 1 Reply Last reply
          0
          • D Dave Kreskowiak

            It looks like it's complaining about something in your OnStart code. Is this .EXE known to be exactly the same as the copies on the other machines? Does the machine have the correct version of the .NET Framework and any service packs on it? RageInTheMachine9532 "...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome

            H Offline
            H Offline
            H is here
            wrote on last edited by
            #5

            Yes it is the same deployment cd of the other machines. About the .Net Framework: That is what i am suspecting. The framework installed is the 1.1 but I don´t know if it has any service packs. I will try that! Thanks Dave

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups