How to launch program without opening dialog

Discussion in 'ASP General' started by SK, Jan 14, 2004.

  1. SK

    SK Guest

    I am calling an exe thru' href, but when it executes,
    I get the message if I want to open the file(exe file).
    Is there any way I can suppress this from appearing
    and open the program?

    Thank you,
    SK
     
    SK, Jan 14, 2004
    #1
    1. Advertising

  2. SK

    ljb Guest

    Probably not an ASP question...

    <script language="vbscript">
    function RunFile(TheFile)
    CreateObject("WScript.Shell").Run """" & TheFile & """, 0, False"
    end function
    </script>
    <body>
    <A href='vbscript:RunFile("\\server\path\program.exe")'>Run this program</A>
    </body>

    "SK" <> wrote in message
    news:023301c3dac8$13173bf0$...
    > I am calling an exe thru' href, but when it executes,
    > I get the message if I want to open the file(exe file).
    > Is there any way I can suppress this from appearing
    > and open the program?
    >
    > Thank you,
    > SK
     
    ljb, Jan 14, 2004
    #2
    1. Advertising

  3. SK

    Curt_C [MVP] Guest

    No, thank heavens....
    It's a HUGE security risk. The user will have to alter their settings to
    allow this.
    Think about it. I could send a user to a link with a virus.exe on it and
    install it automatically... NOT a good thing.

    --
    Curt Christianson
    Owner/Lead Developer, DF-Software
    www.Darkfalz.com


    "SK" <> wrote in message
    news:023301c3dac8$13173bf0$...
    > I am calling an exe thru' href, but when it executes,
    > I get the message if I want to open the file(exe file).
    > Is there any way I can suppress this from appearing
    > and open the program?
    >
    > Thank you,
    > SK
     
    Curt_C [MVP], Jan 14, 2004
    #3
  4. SK

    SK Guest

    ljb,

    Thanks for the reply!

    I am able to run my program, however when its launched,
    I get window "Some files can harm your computer....

    YOu want to Open/Save/Cancel ...

    How to avoid this message from appearing so that it
    runs the program.
    Next thing is it should open the file using the name
    that I pass on. For eg. you want to open an excel
    file using excel.

    Thanks again for your help!
    -SK


    >-----Original Message-----
    >Probably not an ASP question...
    >
    ><script language="vbscript">
    > function RunFile(TheFile)
    > CreateObject("WScript.Shell").Run """" & TheFile

    & """, 0, False"
    > end function
    ></script>
    ><body>
    ><A href='vbscript:RunFile

    ("\\server\path\program.exe")'>Run this program</A>
    ></body>
    >
    >"SK" <> wrote in

    message
    >news:023301c3dac8$13173bf0$...
    >> I am calling an exe thru' href, but when it executes,
    >> I get the message if I want to open the file(exe file).
    >> Is there any way I can suppress this from appearing
    >> and open the program?
    >>
    >> Thank you,
    >> SK

    >
    >
    >.
    >
     
    SK, Jan 14, 2004
    #4
  5. SK

    sk Guest

    Curt,

    Can set it programmatically, then reset it back?

    Thanks much!
    -SK

    >-----Original Message-----
    >No, thank heavens....
    >It's a HUGE security risk. The user will have to alter

    their settings to
    >allow this.
    >Think about it. I could send a user to a link with a

    virus.exe on it and
    >install it automatically... NOT a good thing.
    >
    >--
    >Curt Christianson
    >Owner/Lead Developer, DF-Software
    >www.Darkfalz.com
    >
    >
    >"SK" <> wrote in

    message
    >news:023301c3dac8$13173bf0$...
    >> I am calling an exe thru' href, but when it executes,
    >> I get the message if I want to open the file(exe file).
    >> Is there any way I can suppress this from appearing
    >> and open the program?
    >>
    >> Thank you,
    >> SK

    >
    >
    >.
    >
     
    sk, Jan 14, 2004
    #5
  6. SK

    Dan Boylett Guest

    "SK" <> wrote in message
    news:032001c3dad1$2d08d740$...
    >
    > How to avoid this message from appearing so that it
    > runs the program.


    This requires a very low security model - 'non-existant'.
    As Curt mentions, allowing this to occur is a potentially huge security
    risk, even in a trusted environment.
    You may just have to live with the Open/Save/Cancel box.

    > Next thing is it should open the file using the name
    > that I pass on. For eg. you want to open an excel
    > file using excel.


    If Excel is installed, and the file associations haven't been altered, Excel
    will automatically open .xls files - you don't need to specify this.
     
    Dan Boylett, Jan 14, 2004
    #6
  7. SK

    Ray at Guest

    Link to the .xls file, and the file will open (depending on the user's
    settings). Are you trying to link to excel.exe on your server or something?
    That wouldn't work. Excel can be executed without being installed but it
    needs 7 or 8 dependent files in the startup directory or %path% even for
    that to work. If the person has Excel on his machine, the xls file will
    open in it (or in the browser with an execl.exe process or the user will be
    prompted to download the file). This is all determined by the user's
    settings for the .xls filetype.

    Ray at work

    "SK" <> wrote in message
    news:032001c3dad1$2d08d740$...
    > ljb,
    >
    > Thanks for the reply!
    >
    > I am able to run my program, however when its launched,
    > I get window "Some files can harm your computer....
    >
    > YOu want to Open/Save/Cancel ...
    >
    > How to avoid this message from appearing so that it
    > runs the program.
    > Next thing is it should open the file using the name
    > that I pass on. For eg. you want to open an excel
    > file using excel.
    >
    > Thanks again for your help!
    > -SK
    >
    >
    > >-----Original Message-----
    > >Probably not an ASP question...
    > >
    > ><script language="vbscript">
    > > function RunFile(TheFile)
    > > CreateObject("WScript.Shell").Run """" & TheFile

    > & """, 0, False"
    > > end function
    > ></script>
    > ><body>
    > ><A href='vbscript:RunFile

    > ("\\server\path\program.exe")'>Run this program</A>
    > ></body>
    > >
    > >"SK" <> wrote in

    > message
    > >news:023301c3dac8$13173bf0$...
    > >> I am calling an exe thru' href, but when it executes,
    > >> I get the message if I want to open the file(exe file).
    > >> Is there any way I can suppress this from appearing
    > >> and open the program?
    > >>
    > >> Thank you,
    > >> SK

    > >
    > >
    > >.
    > >
     
    Ray at, Jan 14, 2004
    #7
  8. SK

    SK Guest

    Curt,

    Or if there is flag I can specify like NOCHECK, NOPROMPT,
    SECURITY=OFF.

    Thank you,
    -SK
    >-----Original Message-----
    >No, thank heavens....
    >It's a HUGE security risk. The user will have to alter

    their settings to
    >allow this.
    >Think about it. I could send a user to a link with a

    virus.exe on it and
    >install it automatically... NOT a good thing.
    >
    >--
    >Curt Christianson
    >Owner/Lead Developer, DF-Software
    >www.Darkfalz.com
    >
    >
    >"SK" <> wrote in

    message
    >news:023301c3dac8$13173bf0$...
    >> I am calling an exe thru' href, but when it executes,
    >> I get the message if I want to open the file(exe file).
    >> Is there any way I can suppress this from appearing
    >> and open the program?
    >>
    >> Thank you,
    >> SK

    >
    >
    >.
    >
     
    SK, Jan 14, 2004
    #8
  9. SK

    Ray at Guest

    The same risk would still exist then, would it not?

    ''code to change user's settings
    ''code to execute virus

    ?

    Ray at work

    "sk" <> wrote in message
    news:033b01c3dad2$272a3250$...
    > Curt,
    >
    > Can set it programmatically, then reset it back?
    >
    > Thanks much!
    > -SK
    >
    > >-----Original Message-----
    > >No, thank heavens....
    > >It's a HUGE security risk. The user will have to alter

    > their settings to
    > >allow this.
    > >Think about it. I could send a user to a link with a

    > virus.exe on it and
    > >install it automatically... NOT a good thing.
    > >
    > >--
    > >Curt Christianson
    > >Owner/Lead Developer, DF-Software
    > >www.Darkfalz.com
    > >
    > >
    > >"SK" <> wrote in

    > message
    > >news:023301c3dac8$13173bf0$...
    > >> I am calling an exe thru' href, but when it executes,
    > >> I get the message if I want to open the file(exe file).
    > >> Is there any way I can suppress this from appearing
    > >> and open the program?
    > >>
    > >> Thank you,
    > >> SK

    > >
    > >
    > >.
    > >
     
    Ray at, Jan 14, 2004
    #9
  10. SK

    Curt_C [MVP] Guest

    no... again this would be a huge security risk and by default it not
    allowed.
    If it's programmatically alterable I could easily infect any person who
    visit a site.

    --
    Curt Christianson
    Owner/Lead Developer, DF-Software
    www.Darkfalz.com


    "sk" <> wrote in message
    news:033b01c3dad2$272a3250$...
    > Curt,
    >
    > Can set it programmatically, then reset it back?
    >
    > Thanks much!
    > -SK
    >
    > >-----Original Message-----
    > >No, thank heavens....
    > >It's a HUGE security risk. The user will have to alter

    > their settings to
    > >allow this.
    > >Think about it. I could send a user to a link with a

    > virus.exe on it and
    > >install it automatically... NOT a good thing.
    > >
    > >--
    > >Curt Christianson
    > >Owner/Lead Developer, DF-Software
    > >www.Darkfalz.com
    > >
    > >
    > >"SK" <> wrote in

    > message
    > >news:023301c3dac8$13173bf0$...
    > >> I am calling an exe thru' href, but when it executes,
    > >> I get the message if I want to open the file(exe file).
    > >> Is there any way I can suppress this from appearing
    > >> and open the program?
    > >>
    > >> Thank you,
    > >> SK

    > >
    > >
    > >.
    > >
     
    Curt_C [MVP], Jan 14, 2004
    #10
  11. SK

    SK Guest

    Ray,

    Sorry if I mislead you. The program I am executing is
    an .exe file by another vendor. I want to open
    a file using this program. I am able to launch it
    but I get the dialog box as I mentioned as a result
    it doesn't even store the file name.

    Users click on the file name to open so it is will
    be inconvenient to remember the path and filename.

    Thank you,
    -SK

    >-----Original Message-----
    >Link to the .xls file, and the file will open (depending

    on the user's
    >settings). Are you trying to link to excel.exe on your

    server or something?
    >That wouldn't work. Excel can be executed without being

    installed but it
    >needs 7 or 8 dependent files in the startup directory or

    %path% even for
    >that to work. If the person has Excel on his machine,

    the xls file will
    >open in it (or in the browser with an execl.exe process

    or the user will be
    >prompted to download the file). This is all determined

    by the user's
    >settings for the .xls filetype.
    >
    >Ray at work
    >
    >"SK" <> wrote in

    message
    >news:032001c3dad1$2d08d740$...
    >> ljb,
    >>
    >> Thanks for the reply!
    >>
    >> I am able to run my program, however when its launched,
    >> I get window "Some files can harm your computer....
    >>
    >> YOu want to Open/Save/Cancel ...
    >>
    >> How to avoid this message from appearing so that it
    >> runs the program.
    >> Next thing is it should open the file using the name
    >> that I pass on. For eg. you want to open an excel
    >> file using excel.
    >>
    >> Thanks again for your help!
    >> -SK
    >>
    >>
    >> >-----Original Message-----
    >> >Probably not an ASP question...
    >> >
    >> ><script language="vbscript">
    >> > function RunFile(TheFile)
    >> > CreateObject("WScript.Shell").Run """" & TheFile

    >> & """, 0, False"
    >> > end function
    >> ></script>
    >> ><body>
    >> ><A href='vbscript:RunFile

    >> ("\\server\path\program.exe")'>Run this program</A>
    >> ></body>
    >> >
    >> >"SK" <> wrote in

    >> message
    >> >news:023301c3dac8$13173bf0$...
    >> >> I am calling an exe thru' href, but when it

    executes,
    >> >> I get the message if I want to open the file(exe

    file).
    >> >> Is there any way I can suppress this from appearing
    >> >> and open the program?
    >> >>
    >> >> Thank you,
    >> >> SK
    >> >
    >> >
    >> >.
    >> >

    >
    >
    >.
    >
     
    SK, Jan 14, 2004
    #11
  12. SK

    SK Guest

    Dan,

    Just for testing purpose, can you let me know where
    should I specify. I want to ensure that it works as
    I want. 'cause I want to make sure that the file
    name is being passed over to this app.

    Note, I am not using excel, it was just and example
    I am using an .exe to open up file.

    Thanks for your help!

    -SK

    >-----Original Message-----
    >
    >"SK" <> wrote in

    message
    >news:032001c3dad1$2d08d740$...
    >>
    >> How to avoid this message from appearing so that it
    >> runs the program.

    >
    >This requires a very low security model - 'non-existant'.
    >As Curt mentions, allowing this to occur is a

    potentially huge security
    >risk, even in a trusted environment.
    >You may just have to live with the Open/Save/Cancel box.
    >
    >> Next thing is it should open the file using the name
    >> that I pass on. For eg. you want to open an excel
    >> file using excel.

    >
    >If Excel is installed, and the file associations haven't

    been altered, Excel
    >will automatically open .xls files - you don't need to

    specify this.
    >
    >
    >
    >.
    >
     
    SK, Jan 14, 2004
    #12
  13. SK

    Curt_C [MVP] Guest

    see my other replies, basically NO.

    --
    Curt Christianson
    Owner/Lead Developer, DF-Software
    www.Darkfalz.com


    "SK" <> wrote in message
    news:00f701c3dad2$8fdd05c0$...
    > Curt,
    >
    > Or if there is flag I can specify like NOCHECK, NOPROMPT,
    > SECURITY=OFF.
    >
    > Thank you,
    > -SK
    > >-----Original Message-----
    > >No, thank heavens....
    > >It's a HUGE security risk. The user will have to alter

    > their settings to
    > >allow this.
    > >Think about it. I could send a user to a link with a

    > virus.exe on it and
    > >install it automatically... NOT a good thing.
    > >
    > >--
    > >Curt Christianson
    > >Owner/Lead Developer, DF-Software
    > >www.Darkfalz.com
    > >
    > >
    > >"SK" <> wrote in

    > message
    > >news:023301c3dac8$13173bf0$...
    > >> I am calling an exe thru' href, but when it executes,
    > >> I get the message if I want to open the file(exe file).
    > >> Is there any way I can suppress this from appearing
    > >> and open the program?
    > >>
    > >> Thank you,
    > >> SK

    > >
    > >
    > >.
    > >
     
    Curt_C [MVP], Jan 14, 2004
    #13
  14. SK

    Dan Boylett Guest

    "SK" <> wrote in message
    news:037801c3dad4$5769a890$...
    > Dan,
    >
    > Just for testing purpose, can you let me know where
    > should I specify. I want to ensure that it works as
    > I want. 'cause I want to make sure that the file
    > name is being passed over to this app.
    >
    > Note, I am not using excel, it was just and example
    > I am using an .exe to open up file.
    >
    > Thanks for your help!


    Hi SK,

    In Internet Explorer, browse to your site, then click on Tools -> Internet
    Options -> Security.

    Move the security slider to the lowest option - note the warnings it will
    give you.

    Click on Apply (Yes if promoted) and then ok - try clicking on your link
    again.

    If it still doens't work there might be a option under the custom level you
    can specify, but TBH I've never actually
    done what you're trying.

    My instinct would be that if it still doesnt' work with security set to
    'Low' then it will never work.

    The other possible solution is for you to write your own Browser that your
    users use - not sure if that's possible or feasible for you to do,
    but then you would have full control over what the application does.
     
    Dan Boylett, Jan 14, 2004
    #14
  15. SK

    Ray at Guest

    You cannot avoid this dialog.

    Ray at work

    "SK" <> wrote in message
    news:036e01c3dad4$0774e890$...
    > Ray,
    >
    > Sorry if I mislead you. The program I am executing is
    > an .exe file by another vendor. I want to open
    > a file using this program. I am able to launch it
    > but I get the dialog box as I mentioned as a result
    > it doesn't even store the file name.
    >
    > Users click on the file name to open so it is will
    > be inconvenient to remember the path and filename.
    >
    > Thank you,
    > -SK
    >
    > >-----Original Message-----
    > >Link to the .xls file, and the file will open (depending

    > on the user's
    > >settings). Are you trying to link to excel.exe on your

    > server or something?
    > >That wouldn't work. Excel can be executed without being

    > installed but it
    > >needs 7 or 8 dependent files in the startup directory or

    > %path% even for
    > >that to work. If the person has Excel on his machine,

    > the xls file will
    > >open in it (or in the browser with an execl.exe process

    > or the user will be
    > >prompted to download the file). This is all determined

    > by the user's
    > >settings for the .xls filetype.
    > >
    > >Ray at work
    > >
    > >"SK" <> wrote in

    > message
    > >news:032001c3dad1$2d08d740$...
    > >> ljb,
    > >>
    > >> Thanks for the reply!
    > >>
    > >> I am able to run my program, however when its launched,
    > >> I get window "Some files can harm your computer....
    > >>
    > >> YOu want to Open/Save/Cancel ...
    > >>
    > >> How to avoid this message from appearing so that it
    > >> runs the program.
    > >> Next thing is it should open the file using the name
    > >> that I pass on. For eg. you want to open an excel
    > >> file using excel.
    > >>
    > >> Thanks again for your help!
    > >> -SK
    > >>
    > >>
    > >> >-----Original Message-----
    > >> >Probably not an ASP question...
    > >> >
    > >> ><script language="vbscript">
    > >> > function RunFile(TheFile)
    > >> > CreateObject("WScript.Shell").Run """" & TheFile
    > >> & """, 0, False"
    > >> > end function
    > >> ></script>
    > >> ><body>
    > >> ><A href='vbscript:RunFile
    > >> ("\\server\path\program.exe")'>Run this program</A>
    > >> ></body>
    > >> >
    > >> >"SK" <> wrote in
    > >> message
    > >> >news:023301c3dac8$13173bf0$...
    > >> >> I am calling an exe thru' href, but when it

    > executes,
    > >> >> I get the message if I want to open the file(exe

    > file).
    > >> >> Is there any way I can suppress this from appearing
    > >> >> and open the program?
    > >> >>
    > >> >> Thank you,
    > >> >> SK
    > >> >
    > >> >
    > >> >.
    > >> >

    > >
    > >
    > >.
    > >
     
    Ray at, Jan 14, 2004
    #15
  16. SK

    SK Guest

    Curt,

    Thanks for your time,
    -SK
    >-----Original Message-----
    >see my other replies, basically NO.
    >
    >--
    >Curt Christianson
    >Owner/Lead Developer, DF-Software
    >www.Darkfalz.com
    >
    >
    >"SK" <> wrote in

    message
    >news:00f701c3dad2$8fdd05c0$...
    >> Curt,
    >>
    >> Or if there is flag I can specify like NOCHECK,

    NOPROMPT,
    >> SECURITY=OFF.
    >>
    >> Thank you,
    >> -SK
    >> >-----Original Message-----
    >> >No, thank heavens....
    >> >It's a HUGE security risk. The user will have to alter

    >> their settings to
    >> >allow this.
    >> >Think about it. I could send a user to a link with a

    >> virus.exe on it and
    >> >install it automatically... NOT a good thing.
    >> >
    >> >--
    >> >Curt Christianson
    >> >Owner/Lead Developer, DF-Software
    >> >www.Darkfalz.com
    >> >
    >> >
    >> >"SK" <> wrote in

    >> message
    >> >news:023301c3dac8$13173bf0$...
    >> >> I am calling an exe thru' href, but when it

    executes,
    >> >> I get the message if I want to open the file(exe

    file).
    >> >> Is there any way I can suppress this from appearing
    >> >> and open the program?
    >> >>
    >> >> Thank you,
    >> >> SK
    >> >
    >> >
    >> >.
    >> >

    >
    >
    >.
    >
     
    SK, Jan 14, 2004
    #16
  17. SK

    SK Guest

    Dan,

    Thank you for the reply!

    Can you send me your email id so that if I find a
    workaround I can convey it to you.

    Appreciate your help!

    Thanks again,
    SK

    >-----Original Message-----
    >
    >"SK" <> wrote in

    message
    >news:037801c3dad4$5769a890$...
    >> Dan,
    >>
    >> Just for testing purpose, can you let me know where
    >> should I specify. I want to ensure that it works as
    >> I want. 'cause I want to make sure that the file
    >> name is being passed over to this app.
    >>
    >> Note, I am not using excel, it was just and example
    >> I am using an .exe to open up file.
    >>
    >> Thanks for your help!

    >
    >Hi SK,
    >
    >In Internet Explorer, browse to your site, then click on

    Tools -> Internet
    >Options -> Security.
    >
    >Move the security slider to the lowest option - note the

    warnings it will
    >give you.
    >
    >Click on Apply (Yes if promoted) and then ok - try

    clicking on your link
    >again.
    >
    >If it still doens't work there might be a option under

    the custom level you
    >can specify, but TBH I've never actually
    >done what you're trying.
    >
    >My instinct would be that if it still doesnt' work with

    security set to
    >'Low' then it will never work.
    >
    >The other possible solution is for you to write your own

    Browser that your
    >users use - not sure if that's possible or feasible for

    you to do,
    >but then you would have full control over what the

    application does.
    >
    >
    >
    >.
    >
     
    SK, Jan 14, 2004
    #17
  18. SK

    sk Guest

    Curt,

    I forgot to add this - why is it not storing the
    names of files to open? After I click on open in dialog
    box, it should open the file, but it doesn't. Can you
    help me on that?

    Thank you,
    -SK

    >-----Original Message-----
    >no... again this would be a huge security risk and by

    default it not
    >allowed.
    >If it's programmatically alterable I could easily infect

    any person who
    >visit a site.
    >
    >--
    >Curt Christianson
    >Owner/Lead Developer, DF-Software
    >www.Darkfalz.com
    >
    >
    >"sk" <> wrote in

    message
    >news:033b01c3dad2$272a3250$...
    >> Curt,
    >>
    >> Can set it programmatically, then reset it back?
    >>
    >> Thanks much!
    >> -SK
    >>
    >> >-----Original Message-----
    >> >No, thank heavens....
    >> >It's a HUGE security risk. The user will have to alter

    >> their settings to
    >> >allow this.
    >> >Think about it. I could send a user to a link with a

    >> virus.exe on it and
    >> >install it automatically... NOT a good thing.
    >> >
    >> >--
    >> >Curt Christianson
    >> >Owner/Lead Developer, DF-Software
    >> >www.Darkfalz.com
    >> >
    >> >
    >> >"SK" <> wrote in

    >> message
    >> >news:023301c3dac8$13173bf0$...
    >> >> I am calling an exe thru' href, but when it

    executes,
    >> >> I get the message if I want to open the file(exe

    file).
    >> >> Is there any way I can suppress this from appearing
    >> >> and open the program?
    >> >>
    >> >> Thank you,
    >> >> SK
    >> >
    >> >
    >> >.
    >> >

    >
    >
    >.
    >
     
    sk, Jan 14, 2004
    #18
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Chris Bedford
    Replies:
    6
    Views:
    2,285
  2. joshivaibhav
    Replies:
    3
    Views:
    686
    joshivaibhav
    Nov 21, 2006
  3. yw
    Replies:
    3
    Views:
    843
    Phlip
    Jul 2, 2005
  4. Mr Gordonz

    Button to launch the "File Open" dialog

    Mr Gordonz, Aug 15, 2003, in forum: ASP .Net Web Controls
    Replies:
    0
    Views:
    113
    Mr Gordonz
    Aug 15, 2003
  5. Matt
    Replies:
    1
    Views:
    304
    Randy Webb
    Nov 20, 2004
Loading...

Share This Page