Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Copy File Across Network

Status
Not open for further replies.

simplyJ

MIS
Jul 12, 2001
59
US
I have never created an ActiveX control before, so type slow.

Project:
I need a browser interface that will allow a user to select a file and then copy the file across a network to another lcoation when a form is submitted.

Problem:
Is it possible to initiate the copy of the file/folder on the client's machine with an ActiveX control?

What is a good resource to teach me how to make an ActiveX? I am experienced at coding, but I have never even looked at this before.
 
Copying the file is possible from within an ActiveX control(just do it as you would normally do).

And as for researching ActiveX...
There are som tutorials on the MSDN, yous hould check these out (it is how I got started too).
 
Maybe I am trying to make this too hard...

How do I start copying the file?

I guess I do not even understand what language I am programming in. Honestly, I don't even know what application I use to do this. Do I need VB 6.0?

For instance, in ASP I would do something like this:
dim fs, f
set fs=Server.CreateObject("Scripting.FileSystemObject")
set f=fs.GetFile("\\data\users\text.txt")
Call f.Copy("\\data\users\test\test.txt",TRUE)
set f=nothing
set fs = nothing

Is this what I need to be doing?

I have read some of the MSDN notes, but they are greek. Long winded with no point. [I feel like a hypocrite :)]
 
You could build your control in VB yes, or in VC++ or whatever language you wish (as long as it is COM capable of course), but since your experience lies in ASP VB might seem like the best choice (use FileCopy to copy the file...).

Your code might work fine in ASP, but since you're now building your own ActiveX control, it is not necessary anymore to create other objects just to copy a file.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top