April 28, 2024, 09:10:38 PM

News:

IonicWind Snippit Manager 2.xx Released!  Install it on a memory stick and take it with you!  With or without IWBasic!


Getting a handle

Started by Brian, January 30, 2021, 05:19:52 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Brian

Hello,

This is not working code. It is just an example of something I am trying. Question is: How do I get the correct handle of the PBOX I am creating with CreateWindowEx so I can see the picture with SHOWIMAGE?


Const PBOX=100

WINDOW win
UINT hInst,image
INT pb
hInst=GetModuleHandleA(win.hWnd)
OPENWindow win,0,0,1024,768,@SIZE|@MINBOX|@MAXBOX|@SYSMENU|@BORDER,0,"PicBox",&main
   pb=CreateWindowEx(0x200,"PicBox","",0x56800000,104,144,465,433,win.hWnd,PBOX,hInst,0)
   SETWINDOWCOLOR(win,RGB(240,240,240))
image=LOADIMAGE(GETSTARTPATH+"rose2.jpg",@IMGSCALABLE)
SHOWIMAGE(pb,image,@IMGSCALABLE,0,0)

Many thanks,

Brian