Ask a Question related to ASP.NET General, Design and Development.
-
cedced #1
files client
Hello,
is it possible to access client files in VB.NET?
What?
I have doing that but it isn't good (VB.NET take file on pc server and not
on pc client):
(thanks)
Dim fichier As StreamReader
Dim name As String
fichier = File.OpenText("C:\liste.txt")
name = fichier.ReadLine()
Response.Write(name)
Do While Not name Is Nothing
name = fichier.ReadLine()
Response.Write(name)
Loop
fichier.Close()
cedced Guest
-
How to send files to client
Hi, Does anyone know how to send a file to the client from Flex. My scenario is this: 1) Pass some parameters to java layer 2) Java layer... -
client can't publish files with 4.0
I'll first start by saying that my client has been happily editing and publishing files since February. Recently, she was on vacation so I made a... -
Flash Webcam client <-> client (not client <-> server<-> client)
Dear Flash Team, supporter and regular mortals (Like myself) I am currently running a IRC chat with mostly webclients connected. We currently offer... -
XP Client can't access Win2K-files
Hi ! We have a problem when trying to access files from an XP client on a Win2000 server (Server2). Server2 is not the Domain controller but is... -
Can't see server files on Client PC
I have a four machine home network. My main ICS PC is a Win2kPro, and all the clients are WinXPHome. On the winxp clients I can see the win2kpro... -
Kevin Spencer #2
Re: files client
It is possible to access the file system on the client from any web page,
regardless of what is running behind it on the server. However, it can't be
done from the server. There is no connection between the server and the
client. The client sends a message to the server requesting a resource
(usually a file, such as an ASPX page). The server receives the message
(Request), processes it, and sends a message (Response) back to the client,
usually in the form of an HTML document. How then, can the server access
ANYTHING on the client?
How it is possible for any web page in the client browser to access the file
system on the client is by means of a Java Applet or ActiveX control in the
browser (embedded in an HTML document).
--
HTH,
Kevin Spencer
Microsoft MVP
..Net Developer
[url]http://www.takempis.com[/url]
Complex things are made up of
lots of simple things.
"cedced" <cedrico_59@yahoo.fr> wrote in message
news:bhakpk$1mq$1@muguet.sncf.fr...> Hello,
> is it possible to access client files in VB.NET?
> What?
> I have doing that but it isn't good (VB.NET take file on pc server and not
> on pc client):
> (thanks)
> Dim fichier As StreamReader
>
> Dim name As String
>
> fichier = File.OpenText("C:\liste.txt")
>
> name = fichier.ReadLine()
>
> Response.Write(name)
>
> Do While Not name Is Nothing
>
> name = fichier.ReadLine()
>
> Response.Write(name)
>
> Loop
>
> fichier.Close()
>
>
Kevin Spencer Guest
-
James J. Foster #3
Re: files client
Found via Google:
From: Microsoft® Scripting Library - FileSystemObject
.....
Because use of the FSO on the client side raises serious security issues
about providing potentially unwelcome access to a client's local file
system, this documentation assumes use of the FSO object model to create
scripts executed by Internet Web pages on the server side. Since the server
side is used, the Internet Explorer default security settings do not allow
client-side use of the FileSystemObject object. Overriding those defaults
could subject a local computer to unwelcome access to the file system, which
could result in total destruction of the file system's integrity, causing
loss of data, or worse
....
Use of the FSO is possible client-side in IE, provided the user has set
"enable objects not marked as safe for scripting" (or words to that
effect) to "allow" or "prompt".
James
"cedced" <cedrico_59@yahoo.fr> wrote in message
news:bham9p$2ou$1@muguet.sncf.fr...news:> In fact, i know the fullpath (c:\liste1.txt) on client pc.
> But in javascript, i can't using a datagrid.
> SO......(I must use datagrid so using vb.net but file is on client pc)
> javascript :
> v_chemin = ParamValeur(maVariable);
> var fs = new ActiveXObject("Scripting.FileSystemObject");
> mon_fichier = fs.GetFile(v_chemin).OpenAsTextStream(1);
> ligne = mon_fichier.ReadLine();
> //REMPLIT DATAGRID
> while (mon_fichier.AtEndOfStream==false){
> ligne = mon_fichier.ReadLine();
> //REMPLIT DATAGRID
> }
> //BINDLIST
> "James J. Foster" <james@dotnetcoders.com> a écrit dans le message desince> [email]uK3rdqMYDHA.2236@TK2MSFTNGP10.phx.gbl[/email]...> > From ASP.NET, no, you cannot access the files on the client machineimplications,> > that code runs on the server. There would be severe securitybrowser> > not to mention technological hurdles, if you could ask the client> to> not> > give you any file from the client's machine.
> >
> > --
> > James J. Foster, DotNetCoders
> > [url]http://www.dotnetcoders.com[/url]
> >
> >
> > "cedced" <cedrico_59@yahoo.fr> wrote in message
> > news:bhakpk$1mq$1@muguet.sncf.fr...> > > Hello,
> > > is it possible to access client files in VB.NET?
> > > What?
> > > I have doing that but it isn't good (VB.NET take file on pc server and>> >> > > on pc client):
> > > (thanks)
> > > Dim fichier As StreamReader
> > >
> > > Dim name As String
> > >
> > > fichier = File.OpenText("C:\liste.txt")
> > >
> > > name = fichier.ReadLine()
> > >
> > > Response.Write(name)
> > >
> > > Do While Not name Is Nothing
> > >
> > > name = fichier.ReadLine()
> > >
> > > Response.Write(name)
> > >
> > > Loop
> > >
> > > fichier.Close()
> > >
> > >
> >
>
James J. Foster Guest



Reply With Quote

