Facing problem in poping up dialog boxes when applcation is running in sevice mode - Programmer

This is a discussion on Facing problem in poping up dialog boxes when applcation is running in sevice mode - Programmer ; Hi, I have a small application which is running in service mode. Its responsible is to provide email configuratio. If it gets a request( eg: Export the file throug email) from the user, first it will check whether any email ...

+ Reply to Thread
Results 1 to 2 of 2

Thread: Facing problem in poping up dialog boxes when applcation is running in sevice mode

  1. Facing problem in poping up dialog boxes when applcation is running in sevice mode

    Hi,

    I have a small application which is running in service mode. Its
    responsible is to provide email configuratio. If it gets a request( eg:

    Export the file throug email) from the user, first it will check
    whether
    any email is account is created or not, if not( here my application
    uses one third party .exe that is IDSMAIL.exe) it will pop up a error
    message dialog and then it shoul display the outlook email acount
    configuration window.

    Everty thing is workig fine if i am running my application in console
    mode.

    Note: I tried setting lpDesktop = "Winstat0\\Defaut" while creating
    the process in startupinfo
    structure in case of service mode, it is able to display the error
    message dialog box but after that it is not displaying the outlook
    email acount configuration window. Just it gives Failed to Login Mail
    server


    Please help me in this regard..


  2. Re: Facing problem in poping up dialog boxes when applcation is running in sevice mode


    "Gouse" wrote in message
    news:1169723460.558393.238840@q2g2000cwa.googlegro ups.com...
    > Hi,
    >
    > I have a small application which is running in service mode. Its
    > responsible is to provide email configuratio. If it gets a request( eg:
    >
    > Export the file throug email) from the user, first it will check
    > whether
    > any email is account is created or not, if not( here my application
    > uses one third party .exe that is IDSMAIL.exe) it will pop up a error
    > message dialog and then it shoul display the outlook email acount
    > configuration window.
    >
    > Everty thing is workig fine if i am running my application in console
    > mode.
    >
    > Note: I tried setting lpDesktop = "Winstat0\\Defaut" while creating
    > the process in startupinfo
    > structure in case of service mode, it is able to display the error
    > message dialog box but after that it is not displaying the outlook
    > email acount configuration window. Just it gives Failed to Login Mail
    > server


    Services should never use the desktop, on Vista it isn't even allowed
    anymore.
    Instead you would have a separate client that you start automatically for
    all users
    which then communicate with the server using named pipe (or mailslot or
    socket).

    If you mean your app runs as "service" without a window, then either it
    works as for your account or the user doesn't have the appropriate
    permission, DSN settings etc to work.

    Also, when running stuff in a real Service, keep in mind that it's
    HKEY_CURRENT_USER is pointing at .Default profile unless you are running it
    as a specific account, load the appropriate hive yourself or refernce it via
    enumeration of HKEY_USERS.

    - Sten



+ Reply to Thread