Advertisement

Really simple question

Started by August 13, 2000 01:24 AM
1 comment, last by Fender148 24 years, 5 months ago
Im loading a bitmap with DDLoadBitmap function in the ddutil library. The bitmap file is in the same directory as my .dsw, I want to move it into a folder called "images" so its not in the same folder as my project. here is my function call: if ((a.surface = DDLoadBitmap(lpdd, "animal.bmp",0,0))==NULL) return FALSE; I assume I would change it to this if ((a.surface = DDLoadBitmap(lpdd, "\images\animal.bmp",0,0))==NULL) return FALSE; or something like that, but no luck. If anyone could help me out Id be very appreciative, thanks
it should be
if ((a.surface = DDLoadBitmap(lpdd, "images\\animal.bmp",0,0))==NULL)
return FALSE;

you dont need the first \, and you need 2 because "\" marks the beginning of an escape character sequence, and \\ is the escape character sequence for a backslash

hope this helps

Advertisement
It worked, thanks a lot!!

This topic is closed to new replies.

Advertisement