Skip to main content

JPG GIF Images with Dialog System

  • June 28, 2018
  • 3 replies
  • 0 views

The demo program delivered together with Netexpress 5.1 “Micro Focus\\Net Express 5.1\\Examples\\Dialog System\\CLASSLIBRARY\\Pictures\\Images.App”  works pretty well and shows immediately after  SCREENSET-INITIALIZED the previously defined .JPG .GIF or .BMP image.

 

After adding to the program

            MOVE “next-image.jpg” TO IO-Text-Buffer

            MOVE "SET-PICTURE" TO Call-Function

            SET OBJECT-REFERENCE-x TO IMAGE-REF

            CALL "IMAGECTL" USING  DS-Control-Block.   Data-Block

           PERFORM Call-Dialog-System

I can show one image after another.

But due to the fact that at the beginning of the program I don’t know which image, how can I avoid showing the first image and show it after selecting it? That is after running several procedures.

A lot of changes just give me different error messages, but not the expected Change still the first Image appears or I have an other error.

Leaving the IO-Text-Buffer empty = Does not understand: draw Exception 24”

omitting the     CALLOUT in the SCREENSET-INITIALIZED still shows the first Image. and afterwards returns Error No. 0017

Thanks for any help.

3 replies

  • 0 replies
  • June 28, 2018

The demo program delivered together with Netexpress 5.1 “Micro Focus\\Net Express 5.1\\Examples\\Dialog System\\CLASSLIBRARY\\Pictures\\Images.App”  works pretty well and shows immediately after  SCREENSET-INITIALIZED the previously defined .JPG .GIF or .BMP image.

 

After adding to the program

            MOVE “next-image.jpg” TO IO-Text-Buffer

            MOVE "SET-PICTURE" TO Call-Function

            SET OBJECT-REFERENCE-x TO IMAGE-REF

            CALL "IMAGECTL" USING  DS-Control-Block.   Data-Block

           PERFORM Call-Dialog-System

I can show one image after another.

But due to the fact that at the beginning of the program I don’t know which image, how can I avoid showing the first image and show it after selecting it? That is after running several procedures.

A lot of changes just give me different error messages, but not the expected Change still the first Image appears or I have an other error.

Leaving the IO-Text-Buffer empty = Does not understand: draw Exception 24”

omitting the     CALLOUT in the SCREENSET-INITIALIZED still shows the first Image. and afterwards returns Error No. 0017

Thanks for any help.

High Rolf,
I do the same with

call WINAPI ShellExecute using
by value 0 size 4,
by reference z"open",
by reference z"image.exe",
by reference bildnummer,
by value 0 size 4,
by value SW-normal
end-call

and in the Image.exe before "call dialog-System"
accept io-text-buffer from command-line

I have no Problems.

regards Georg

  • Author
  • Rocketeer
  • 19312 replies
  • June 29, 2018

The demo program delivered together with Netexpress 5.1 “Micro Focus\\Net Express 5.1\\Examples\\Dialog System\\CLASSLIBRARY\\Pictures\\Images.App”  works pretty well and shows immediately after  SCREENSET-INITIALIZED the previously defined .JPG .GIF or .BMP image.

 

After adding to the program

            MOVE “next-image.jpg” TO IO-Text-Buffer

            MOVE "SET-PICTURE" TO Call-Function

            SET OBJECT-REFERENCE-x TO IMAGE-REF

            CALL "IMAGECTL" USING  DS-Control-Block.   Data-Block

           PERFORM Call-Dialog-System

I can show one image after another.

But due to the fact that at the beginning of the program I don’t know which image, how can I avoid showing the first image and show it after selecting it? That is after running several procedures.

A lot of changes just give me different error messages, but not the expected Change still the first Image appears or I have an other error.

Leaving the IO-Text-Buffer empty = Does not understand: draw Exception 24”

omitting the     CALLOUT in the SCREENSET-INITIALIZED still shows the first Image. and afterwards returns Error No. 0017

Thanks for any help.

Thanks, it works very good. Instead of "not showing the Initial picture" I call (with Shellexecute) the Image.exe afther knowing what to show.
I just changed ShellExecute by ShellExecuteA and observed a funny thing: if my program has no
Display " " at 0101
the ShellExecute dos not work and Returns a 24 not found message.
Dankeschön.

  • 0 replies
  • June 29, 2018

The demo program delivered together with Netexpress 5.1 “Micro Focus\\Net Express 5.1\\Examples\\Dialog System\\CLASSLIBRARY\\Pictures\\Images.App”  works pretty well and shows immediately after  SCREENSET-INITIALIZED the previously defined .JPG .GIF or .BMP image.

 

After adding to the program

            MOVE “next-image.jpg” TO IO-Text-Buffer

            MOVE "SET-PICTURE" TO Call-Function

            SET OBJECT-REFERENCE-x TO IMAGE-REF

            CALL "IMAGECTL" USING  DS-Control-Block.   Data-Block

           PERFORM Call-Dialog-System

I can show one image after another.

But due to the fact that at the beginning of the program I don’t know which image, how can I avoid showing the first image and show it after selecting it? That is after running several procedures.

A lot of changes just give me different error messages, but not the expected Change still the first Image appears or I have an other error.

Leaving the IO-Text-Buffer empty = Does not understand: draw Exception 24”

omitting the     CALLOUT in the SCREENSET-INITIALIZED still shows the first Image. and afterwards returns Error No. 0017

Thanks for any help.

Hi Rolf,
fine that I could help. My Shellexecute is a shellexecuteA
78 ShellExecute value "ShellExecute" & Suffix.
78 Suffix value "A".
In all my programs with Dialog System I have a Display space at 0101.
Regards Georg