IMAGE Control

HMG Tutor 14

Displaying Images (The IMAGE Control)

The IMAGE control allows to show image files in your program.

@ 10,10 IMAGE Image_1 ;
        PICTURE 'Demo.Bmp' ;
        WIDTH 90 ;
        HEIGHT 90

#include "hmg.ch"
Function Main
DEFINE WINDOW Win_1 ;
   AT 0,0 ;
   WIDTH 400 ;
   HEIGHT 200 ;
   TITLE 'Tutor 14 Image Test' ;
   MAIN
   DEFINE MAIN MENU
      POPUP "First Popup"
         ITEM 'Change Image Content' ACTION ;
               Win_1.Image_1.Picture := 'Open.Bmp'
         ITEM 'Retrieve Image Content' ACTION ;
               MsgInfo ( Win_1.Image_1.Picture)
      END POPUP
  END MENU
  @ 10,10 IMAGE Image_1 ;
          PICTURE 'Demo.Bmp' ;
          WIDTH 90 ;
          HEIGHT 90
END WINDOW
ACTIVATE WINDOW Win_1
Return

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.