png errors
Posted
#1
(In Topic #1441)
Regular

I have an unusual error and wondering if anyone can help. In the simple test code below I am downloading a specific .png file from my web server. The file downloads but will not open. Error says it's not a png file. There is nothing wrong with the png on the server, I can download through webmin and open it just fine. I use this code a lot downloading jpgs and never had a problem. The download path on the server is correct, I have been staring at it for hours so it is right. Is there something about downloading and saving a png that I am missing? Should I do something different for png files?
Code (gambas)
- Try File.save("/home/rjr/test/1/channimg.png", HttpClient.Download("http://192.168.1.72/imgs/1/channimg.png"))
- 'image not on server
- 'show img
- PictureBox1.Picture = pc
Posted
Regular

Posted
Guru

This works, you can test it as the file exists online.
Posted
Guru

cogier said
it's because he used [angle brackets] not (parenthesis) by mistake.
Picture.Load() is of course a method
Posted
Regular

Posted
Regular

Posted
Regular

Posted
Regular

thatbruce said
Thanks Bruce!
1 guest and 0 members have just viewed this.


