Hi all, Can someone kindly point me in the correct direction? I need to copy a JPEG from one file folder to another. It seems so basic, but yet, I can't get it going. Thanks in advance!! Brian
First you click on the 'My Computer' icon up in the corner of your screen, open up the folder the JPEG file is stored in, and then drag the file.... Oh, wait... you mean in Java...
HTH, -Nate
-Nate
Write once, run anywhere, because there's nowhere to hide! - /. A.C.
Brian Snyder
Ranch Hand
Joined: Feb 03, 2001
Posts: 142
posted
0
Thanks Nate!!! That did the trick. I like your joke....it was quite amusing. Regards, Brian
Brian Snyder
Ranch Hand
Joined: Feb 03, 2001
Posts: 142
posted
0
Hi Nate or whomever else..... I am now able to successfully copy a JPEG file from one filefolder to another....BUT...... The only problem is that it is SLOW!!! I put the code used to copy the file into a thread figuring it shouldn't take away from CPU time, but I still find that the program must wait until the copying is done before the user can do something else. Any ideas on increasing speed??? Many thanks in adbance.
Thanks Gregg.. That did make a big difference. There's still some delay, but not as much as before. Good tip. I hope to return the favor. Brian
Brian Snyder
Ranch Hand
Joined: Feb 03, 2001
Posts: 142
posted
0
I'm back looking for another answer. I have 225 JPEG's that need to be copied. Using the above code takes about 5 MINUTES or more to do the job. When using My Computer in Windows it takes less than 1 minute. There has to be an easier way. I have used That is quick. The only problem is that the old file obviously gets removed. How do I 'copy' and not just 'cut and paste' my JPEGS? Many thanks in advance!
gautham kasinath
Ranch Hand
Joined: Dec 01, 2000
Posts: 583
posted
0
Hi! Well have you tried to read the file by a kb?? Read instead of one byte each time the loop executes.. try reading a KB.. 1024 bytes.. that helps in speed coz it helped me on my winnt 4.0 ws Regds Gautham Kasinath
Could you show a code sample of that? Sounds like a dandy idea.
------------------ Happy Coding, Gregg Bolinger
Brian Snyder
Ranch Hand
Joined: Feb 03, 2001
Posts: 142
posted
0
Hi Gautham, Thanks for your reply. Does copying more than one byte at a time lose picture quality? Could you send me some code as well with your example so I can try it out? Many thanks in advance. snydb@home.com