Jump to content

Service Not Starting


Recommended Posts

I'm trying to create a service so if the selected program crashes it will be auto restarted

The code creates the service but it does not start it. When I try to start it from Services it gives me

Error 1053: The service did not respond to the start or control request in a timely fashion.

Heres the code

If(Not _Service_Exists(ServiceName())) Then
        _Service_Create(ServiceName(), ServiceName(), $FileLocation & " " & $CommandLine)
    EndIf

    Sleep(1000)
    
    MsgBox(16, "", _Service_Start(ServiceName())) ;This returns 1oÝ÷ Øw«zËay'«¾'
·µâ7ök¬xºÚ"µÍ[ÈÔÙXÙWÐÜX]J  ÌÍÜÔÙXÙS[YK ÌÍÜÑÜ^S[YK   ÌÍÜÐ[T]   ÌÍÜÑØÜ[ÛHY][   ÌÍÛÙXÙUHHY][ ÌÍÛÜHHY][ ÌÍÛÝHHY][ ÌÍÜÑÚÝÜ[XÝHY][    ÌÍÜÔÙXÙUÙHY][  ÌÍÜÔÜÝÛÜHY][  ÌÍÜÓØYÜÜÝHY][ ÌÍÜÓØYÜÜÝ[[ÚYÈHY][  ÌÍÜÑ[[ÚYÈHY][   ÌÍÐÛÛ]HÛÛ][YHÂ
BØØ[  ÌÍÔÙXÙHHØÙ]
    ][ÝÝÚ[YÛ]Î][ÝÈ   [È ][ÝÞÒ[ÛÛ][Û][Z[ÛÛ]_IÌÌÎÉÌLÉÌLÉ][ÝÈ    [È ÌÍÐÛÛ] [È ][ÝÉÌLÜÛÝ ÌLØÚ[]][ÝÊBØØ[   ÌÍÛØÙXÙHH ÌÍÔÙXÙKÙ]
    ][ÝÕÚ[ÌÔÙXÙI][ÝÊBØØ[ ÌÍÙÜH   ÌÍÛØÙXÙKÜX]J   ÌÍÜÔÙXÙS[YK ÌÍÜÑÜ^S[YK   ÌÍÜÐ[T]   ÌÍÛÙXÙUK ÌÍÛÜK ÌÍÛÝK ÌÍÜÑÚÝÜ[XÝ    ÌÍÜÔÙXÙUÙ  ÌÍÜÔÜÝÛÜ  ÌÍÜÓØYÜÜÝ ÌÍÜÓØYÜÜÝ[[ÚYË  ÌÍÜÑ[[ÚYÈÂ
BY  ÌÍÙÜH[Y ÌÍÜÑØÜ[Û ÉÝÈY][[YÕÜ]J   ][ÝÉÌLÉÌLÉ][ÝÈ  [È ÌÍÐÛÛ] [È ][ÝÉÌLÒÓIÌLÔÖTÕSIÌLÐÝ[ÛÛÛÙ] ÌLÔÙXÙÉÌLÉ][ÝÈ [È ÌÍÜÔÙXÙS[YK   ][ÝÑØÜ[Û][ÝË ][ÝÔQ×ÔÖ][ÝË ÌÍÜÑØÜ[ÛB[Y]B[Y]Ù]Ü    ÌÍÙÜ
B[[ÈÉÏOIÝÈÔÙXÙWÐÜX]J

Any Ideas about this?

Link to comment
Share on other sites

From what I understand AutoIt EXEs cannot be run as services due to their structure. This is because the compiled code also includes a compressed version of the source code which results in a wrapper for your program that is not compatible with the Services Manager. Try converting your AutoIt code into C++ or an equivalent language to resolve this issue.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...