Solved

File Transfer

Posted on 2000-04-14
28
212 Views
Last Modified: 2010-04-04
I want to make a program that does the equivalent to ICQ File Transfer.

ie. a client selects a file to send and the receiver has the option to choose the folder to receive to.

I need this program to run on a land using TCP.

I only have Delphi 4 Standard, so I am currently using the freeware FPIette ICS components although i am prepared to use winshoes although i would prefer not to.

0
Comment
Question by:frangers99
  • 10
  • 9
  • 7
  • +2
28 Comments
 

Expert Comment

by:haehnen
ID: 2718849
HI,
you can use the Ftp-Components from ICS.
Look at the ICS-Homepage for more Information.
bye
0
 
LVL 3

Expert Comment

by:bryan7
ID: 2719075
0
 

Expert Comment

by:airboy
ID: 2719781
I am pretty sure you will find all you need for your file transfers at this site
http://www.experts-exchange.com/jsp/qShow.jsp?ta=delphi&qid=10104621 
Bye!!
0
 
LVL 3

Expert Comment

by:bryan7
ID: 2719941
I'm just wondering airboy.. no offense.. are you blind ?
0
 

Author Comment

by:frangers99
ID: 2721134
can either of you explain that code, i've seen it before but is there a comopnent that does most of the work or is that the easiest way?
0
 
LVL 3

Expert Comment

by:bryan7
ID: 2721188
it uses fpiette's component to do so.. it's very easy in a few steps:

1. side1 connects to side2
2. side2 asks the file transmision to start
3. side1 gets a piece of the file and sends it (let's say 8kb)
4. when side2 has received the 8kb it asks side1 for the next piece
5. side1 sends next 8kb piece....
6.. back to step 4 until file is complete..

I have made this once.. but a bit more complex...
you can have 2 connections.. 1 for file transmision only
and 2 for passing file name and size, make pause/resume.
etc..

0
 

Author Comment

by:frangers99
ID: 2721608
but there aren't any components, it would make life easier
0
 
LVL 3

Expert Comment

by:bryan7
ID: 2721622
in fact there are.. FTP server and FTP client in fpiette's package
0
 

Author Comment

by:frangers99
ID: 2721682
i have had a look at those components but it works the opposite way, I want my client to send the files and the server to receive them, i spose FTP does that, what's the most effective way to go about this problem
0
 
LVL 3

Expert Comment

by:bryan7
ID: 2725242
? the opposite way ? ftp can server can RECEIVE and SEND files...
so it's ok for your needs..
0
 
LVL 3

Expert Comment

by:bryan7
ID: 2725248
? the opposite way ? ftp server can RECEIVE and SEND files...
so it's ok for your needs..
0
 

Author Comment

by:frangers99
ID: 2725319
yeah sorry, i wrote the wrong thing, do you have any sample code, then you get the points.
0
 
LVL 3

Expert Comment

by:bryan7
ID: 2725441
well, I'm doing an FTP client with it.. but the code is long..
I can do it.. but ics already has 2 samples.. on is an ftp CLIENT sample.. and the other is an ftp SERVER sample.. you can compile and run them at the same time and try it .. server as localhost.. then look at the sources.. they are quite clear and easy and with some explanations..

but if you want I can do the samples to show you..
0
 

Author Comment

by:frangers99
ID: 2729954
just what code do you use to send a file to the client if you are the server?
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 7

Expert Comment

by:God_Ares
ID: 2744211
your awnser is at

http://www.angelfire.com/ok/GODARES/downl.html

it is pretty easy to modify it exactly to your needs... but if you want me to do it 4 u don't reject my awnser but give an extra comment, and raise the points a bit.

greetz

Ares

comments or questions to

god_ares@yahoo.com
0
 
LVL 7

Expert Comment

by:God_Ares
ID: 2744244
btw

i'm using d4 pro  no extra components
0
 
LVL 3

Expert Comment

by:bryan7
ID: 2746120
frangers.. look at the FTP server DEMO from fpiette... it's all there..
0
 
LVL 7

Expert Comment

by:God_Ares
ID: 2746322
Well ftp is not quite icq... now is it? i'm not using fpiette's stuff...
0
 
LVL 7

Expert Comment

by:God_Ares
ID: 2762719
so how about it???
0
 

Author Comment

by:frangers99
ID: 2763107
just got back from a holiday, i'll check it out
0
 

Author Comment

by:frangers99
ID: 2778879
I don't have the majority of the components required
0
 
LVL 3

Expert Comment

by:bryan7
ID: 2778898
? what do you mean ? install the full ics package..
0
 

Author Comment

by:frangers99
ID: 2779793
no, I ment in rejection to God Ares answer of the program file_trans that you can modify.
0
 
LVL 7

Expert Comment

by:God_Ares
ID: 2785480
so what is the problem? You don't have the components i have used? Install d4 pro... i haven't used anything fancy.
0
 

Author Comment

by:frangers99
ID: 2787410
i have d4 standard
0
 
LVL 7

Expert Comment

by:God_Ares
ID: 2787457
well if you don't have the components i have used.. too bad..

i'm shure FPIette has a tcp/ip component just send over the filename filesize and blocks of 1024bytes let

so you can write a program that does the icq transver

person1                  person2
filename >
                       < okfilename
filesize >             < okfilesize

 
(okfilesize should be make by a button click   that is for accepting the transver)

repeat                   repeat
 if filesizeleft
  >=1024
  send 1024k >     
                    < ok1024            
 else
  send remaining  
                   <okremaining

done:=done or timeout
until done               until done



why 1024 bytes ?   it's easy to make a calculation like  4 kb/s
0
 
LVL 3

Accepted Solution

by:
bryan7 earned 50 total points
ID: 2788384
0
 
LVL 7

Expert Comment

by:God_Ares
ID: 2790158
yep that should be it... didn't test it do...


frangers99 i wish you the best, you should give bryan7 the points, but don't forget to compress!!!! sending a screen can be HUGE
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

The uses clause is one of those things that just tends to grow and grow. Most of the time this is in the main form, as it's from this form that all others are called. If you have a big application (including many forms), the uses clause in the in…
Introduction I have seen many questions in this Delphi topic area where queries in threads are needed or suggested. I know bumped into a similar need. This article will address some of the concepts when dealing with a multithreaded delphi database…
This Micro Tutorial demonstrates using Microsoft Excel pivot tables, how to reverse engineer competitors' marketing strategies through backlinks.
Migrating to Microsoft Office 365 is becoming increasingly popular for organizations both large and small. If you have made the leap to Microsoft’s cloud platform, you know that you will need to create a corporate email signature for your Office 365…

896 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

15 Experts available now in Live!

Get 1:1 Help Now