LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Why does the function GetBitmapFromFile("trv01.bmp",&BitMapID) return an error code of null (OK), and an invalid control ID (BitMapID = -366280330) ?

I know this is an invalid control ID because the function SetCtrlBitmap(..) returns with an error code of -13
0 Kudos
Message 1 of 2
(3,166 Views)
That bitmap id is valid. If you're getting a -13 error from SetCtrlBitmap, that is because of what you're passing as the control parameter of SetCtrlBitmap. It must be a control valid for that panel.

Remember, a bitmap is not a control. It is something that you can pass to a control, but it is not a control in and of itself.

When you no longer need the bitmap, you shouls discard it, using DiscardBitmap.

- luis
0 Kudos
Message 2 of 2
(3,166 Views)