Re: Is there how to client open file in your PC using ASP component??

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: Vilmar (xx1122_at_x1212x.com.jc)
Date: 05/25/04


Date: Tue, 25 May 2004 10:50:07 -0300

thank you a lot guy.

-- 
Regards,
Vilmar Brazão de Oliveira
"Chris Barber" <chris@blue-canoe.co.uk.NOSPAM> escreveu na mensagem
news:uP$CS5EPEHA.3012@tk2msftngp13.phx.gbl...
> Use the object model or just script it.
>
> Found this on Google:
>
> Opening documents with default program
>
> To open a document with its default program from inside a Visual Basic
program
> run Start.exe using the Shell statement and pass the file name and path of
> the document as a parameter. This does not work in Microsoft Windows 2000
or XP.
> The API ShellExecuteA function will work under Microsoft Windows
95/98/2000 and XP.
>
> Example 1:
>
> 'Works under Microsoft Windows 95/98:
> Shell "start.exe c:\windows\picture.bmp"
>
> Example 2:
>
> 'Works under Microsoft Windows 95/98/2000/XP:
> Declare Function ShellExecuteA Lib "shell32.dll" (ByVal hWnd As Long, _
> ByVal lpOperation As String, ByVal lpFile As String, ByVal lpParameters As
String, _
> ByVal lpDirectory As String, ByVal nShowCmd As Long) As Long
>
> Sub Main()
> ShellExecuteA(CLng(0), "open", "picture.bmp", "", "c:\windows", CLng(0))
> End Sub
>
> Chris.
>
>
> "Vilmar" <xx1122@x1212x.com.jc> wrote in message
news:%23uZHETDPEHA.308@TK2MSFTNGP11.phx.gbl...
> Hi Chris,
> Nice component, but I could make it open a file without be inside a input
> text control:
> txtContents.value = mobjFSO.Contents;
> So, how can I do open a file with your default program, as:~
> .doc >> automatically opened by winword.exe
> .xls >> automatically opened by excel.exe
> .txt >> automatically opened by notepad.exe
>
> Thank you so much untill now.
> -- 
>
>
> Vilmar Brazão de Oliveira
>
> "Chris Barber" <chris@blue-canoe.co.uk.NOSPAM> escreveu na mensagem
> news:%23AkjsdhOEHA.2920@tk2msftngp13.phx.gbl...
> > Email sent to you with a sample project and web page.
> >
> > If anyone else is interested then please see:
> > http://ftp.belper.blue-canoe.net/private/demo/webfso
> >
> > Security implications (just in case):
> >
> > 1. Please change the ClassIDs of the public classes (eg. rebuild the VB
> project with no binary
> > compatibility) if you use it in your own environment so that it cannot
be
> used by someone looking at
> > the existing sample page and making a new web page with the objects in
it.
> I've done this myself so
> > that someone can't craft a web page with my component in it and gain
> access to my local system.
> > 2. You use this completely at your own risk. I am providing code samples
> ONLY and will not be held
> > responsible in any way for misuse of the code in any way, shape, or
form.
> > 3. As with all software, do *NOT* accept the security applet code sign
> warning and continue with the
> > install of the component unless you completely trust the software
provider
> (in this case, Blue
> > Canoe) especially where the component is intended to provide web page
> access to the local file
> > system (albeit in trusted intranet environments).
> >
> > Cheers,
> >
> > Chris.
> >
> > "Vilmar" <xx1122@x1212x.com.jc> wrote in message
> news:ei0M5nbOEHA.3096@TK2MSFTNGP09.phx.gbl...
> > Hi Chris,
> > Could you pass me this component with the sample?
> > I ask you because my boss is borring me a lot about open this file in
> client
> > side!!!
> > I need to give any solution, it does not matter how it is!
> > Best regards.
> > -- 
> >
> > Vilmar Brazão de Oliveira
> >
> > "Chris Barber" <chris@blue-canoe.co.uk.NOSPAM> escreveu na mensagem
> > news:uwPkiCROEHA.2728@TK2MSFTNGP12.phx.gbl...
> > > Security, security, security.
> > >
> > > A signed ActiveX install can do that, as can a signed Java Applet. You
> can
> > of course ask the user to
> > > open a .htc but you still get the security warning at least once.
> > > You may also be able to reduce the IE security settings but that would
> be
> > a really bad move -
> > > security, security, security.
> > >
> > > Rule of thumb, forget about accessing anything on client machines
> *unless*
> > you are in a secure
> > > intranet where all the users full agree to install the relevant DLL
> > (marked as safe for scripting as
> > > well).
> > >
> > > I *have* done this but only for a locally installed application that
> uses
> > a hosted IE browser on a
> > > form where the web pages have the ActiveX referenced by it's GUID -
the
> > ActiveX is pre-installed
> > > with the application.
> > >
> > > Chris.
> > >
> > > "Vilmar" <xx1122@x1212x.com.jc> wrote in message
> > news:Okrjw7QOEHA.2100@TK2MSFTNGP11.phx.gbl...
> > > Hi,
> > >
> > > Is there how to client open file in your machine using ASP component??
> > > Is there some component that do that?
> > > I would like to use the input type file, so user look for a file and
> open
> > it
> > > clicking in a button which calls an asp page action.
> > > So he could open .doc, .xls, .txt, .exe, etc.... in your local PC.
> > >
> > > thanks,
> > >
> > > Vilmar
> > >
> > >
> > >
> >
> >
> >
>
>
>


Relevant Pages

  • Re: Is there how to client open file in your PC using ASP component??
    ... "Chris Barber" escreveu na mensagem ... do *NOT* accept the security applet code sign ... > Vilmar Brazão de Oliveira ... >> A signed ActiveX install can do that, as can a signed Java Applet. ...
    (microsoft.public.inetserver.asp.components)
  • Re: Is there how to client open file in your PC using ASP component??
    ... "Chris Barber" escreveu na mensagem ... do *NOT* accept the security applet code sign ... > Vilmar Brazão de Oliveira ... >> A signed ActiveX install can do that, as can a signed Java Applet. ...
    (microsoft.public.inetserver.asp.components)
  • Re: limiting table access and RWOP queries
    ... thanks again Chris, ... > Removing Database Window, AllowBypassKeys, Default Menus, are fundamental ... As important as User-Level Security, ... > (One reason for security is solely economic. ...
    (microsoft.public.access.security)
  • Re: Masking/Hiding a password in Perl Source
    ... Chris G. wrote: ... In the interest of security, I want to find a way to mask this. ... obtained root access. ... The purpose was to make it so the password was not readable in the compiled programs. ...
    (comp.lang.perl.misc)
  • Re: Security help????
    ... Chris again re my help above. ... all except one Excel file that will open excel, ... No keyboard short cuts work ie to open explorer. ... I thought all the problems were to do with the security ...
    (microsoft.public.windowsxp.security_admin)