URL+/path_here_/path_there

BlitzMax Forums/BlitzMax Programming/URL+/path_here_/path_there

Blitzplotter(Posted 2006) [#1]
Anyone else experienced the problem whereby a path specified as:

TBall.Create(LoadImage(URL+"ball.png"),Width/2,600)

works great when built and executed by the compiler,

but then when you try to run the .exe (which is in the same directory as the uncompiled file) it crashes, I suspect due to not being able to source the URL path for some reason ?


Regards,


Dreamora(Posted 2006) [#2]
If you build it in debug mode you can find out why it actually crashes.


xlsior(Posted 2006) [#3]
When you say "URL", do you mean an actual HTTP URL, or just a local file?

If you're talking about website data:

The loadimage routines will not work on a linear data stream, but need to jump around inside the data to parse the appropriate header information and such... so you'll need to cache it in a bank first, and can load from there.

The following should work OK:

img:TImage = LoadImage(LoadBank ("http::www.google.com/intl/en/images/logo.gif"))


Blitzplotter(Posted 2006) [#4]
thanks xlsior