We help IT Professionals succeed at work.
Get Started

How Do I change a URL file location on my webspace for the same file on my Desktop - for a road trip.

James Hancock
on
186 Views
Last Modified: 2015-09-09
Hi

On my road trip, in the car, I want to work on my invulnerable chess engine, (I'll move it from my PC to my Macbook)
but my chess piece .png files are on my web-space.

How can I change a URL object to be a local file, instead?

Passing the file's location into the URL constructor doesn't work, like some pages suggested.
What actually works, without deprecated solutions?

I have working..
URL url = new URL(" http://mydomain/graphicsFile.png");
pieceImages[0] = tk.createImage(url);

Open in new window


How do I do the same with a local file on a MacBook?

Thanks
Comment
Watch Question
CERTIFIED EXPERT
Distinguished Expert 2020
Commented:
This problem has been solved!
Unlock 1 Answer and 3 Comments.
See Answer
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE