Our Products:   CompleteFTP  edtFTPnet/Free  edtFTPnet/PRO  edtFTPj/Free  edtFTPj/PRO
0 votes
7.1k views
in Java FTP by
Hi,

how can I use the progressbar?
Do you have an example? In the test-files I found something like:

ftp.setProgressMonitor(new TestProgressMonitor(), 2048);

This does not work. Did I forget to import something or where is the problem?

Thanx for an answer!

S

2 Answers

0 votes
by
You need to write a class that implements the FTPProgressMonitor interface, e.g. MyProgressMonitor implements FTPProgressMonitor ....

Then

FTPProgressMonitor monitor = new MyProgressMonitor();
ftp.setProgressMonitor(monitor, 2048);

monitor.bytesTransferred() will be called every 2048 bytes transferred.


Hi,

how can I use the progressbar?
Do you have an example? In the test-files I found something like:

ftp.setProgressMonitor(new TestProgressMonitor(), 2048);

This does not work. Did I forget to import something or where is the problem?

Thanx for an answer!

S
0 votes
by
Thanx very much.

Categories

...