Skip to main content

[Migrated content. Thread originally posted on 28 January 2012]

Hi.

Sorry for my poor English.

I am trying to do this:

////Code flagment //////////////////////////////////////////////////
           Invoke   BitmapData "fromFileZ" Using
                    z"D:\\piSistemas\\Imagem\\Foto01.bmp"
                                       Returning BitmapOR

           Move     0                   To hPalette
           Move     1                   To fPictureOwnsHandle
           Invoke   OlePicture "fromBitmap" Using BitmapOR
                                                  hPalette
                                                  fPictureOwnsHandle
                                        Returning anObject

           Invoke   anObject "getDomainObject" Returning aPicture

           invoke   SCGrid "SetPicture" Using aPicture

////End of Code flagment ///////////////////////////////////////////


But, i get the "Member no found" message.

Obs: "Picture" is a property.

Compiler: NetExpress 3.1 (Trial)

Thanks in advance.

Antonio João
Brasil

[Migrated content. Thread originally posted on 28 January 2012]

Hi.

Sorry for my poor English.

I am trying to do this:

////Code flagment //////////////////////////////////////////////////
           Invoke   BitmapData "fromFileZ" Using
                    z"D:\\piSistemas\\Imagem\\Foto01.bmp"
                                       Returning BitmapOR

           Move     0                   To hPalette
           Move     1                   To fPictureOwnsHandle
           Invoke   OlePicture "fromBitmap" Using BitmapOR
                                                  hPalette
                                                  fPictureOwnsHandle
                                        Returning anObject

           Invoke   anObject "getDomainObject" Returning aPicture

           invoke   SCGrid "SetPicture" Using aPicture

////End of Code flagment ///////////////////////////////////////////


But, i get the "Member no found" message.

Obs: "Picture" is a property.

Compiler: NetExpress 3.1 (Trial)

Thanks in advance.

Antonio João
Brasil
I just created a simple test program that uses SCGrid control version 6.08 and Net Express 5.1 and upodated the control program with the following code which does exactly what you are trying and it worked fine and the bitmap displayed in the control.


          invoke anOLEControlSite "GetDomainObject"
                             returning SCGrid
          invoke SCGrid "GetDataSource" returning DataSource

          Invoke   BitmapData "fromFileZ"
            Using z"C:\\testgrid2\\testbmp.bmp"
            Returning BitmapOR
          Move 0 To hPalette
          Move 1 To fPictureOwnsHandle
          Invoke OlePicture "fromBitmap" Using BitmapOR
               hPalette
               fPictureOwnsHandle
               Returning anObject
          Invoke anObject "getDomainObject" Returning aPicture
          invoke   SCGrid "SetPicture" Using aPicture




Perhaps it is the older version of Net Express that you are using or that you have an older version of the SCGrid control?

If you right click on the control in Dialog System to display the properties page, can you set the Picture property?

[Migrated content. Thread originally posted on 28 January 2012]

Hi.

Sorry for my poor English.

I am trying to do this:

////Code flagment //////////////////////////////////////////////////
           Invoke   BitmapData "fromFileZ" Using
                    z"D:\\piSistemas\\Imagem\\Foto01.bmp"
                                       Returning BitmapOR

           Move     0                   To hPalette
           Move     1                   To fPictureOwnsHandle
           Invoke   OlePicture "fromBitmap" Using BitmapOR
                                                  hPalette
                                                  fPictureOwnsHandle
                                        Returning anObject

           Invoke   anObject "getDomainObject" Returning aPicture

           invoke   SCGrid "SetPicture" Using aPicture

////End of Code flagment ///////////////////////////////////////////


But, i get the "Member no found" message.

Obs: "Picture" is a property.

Compiler: NetExpress 3.1 (Trial)

Thanks in advance.

Antonio João
Brasil
Hi Chris.

I am using the Netexpress 3.1, trial version.

The version of ocx is 4.5.5 (SCGrid Freeware), but, i try with the 6.08 Version.

And yes, I can set the picture property. It is ok.

I am trying to develop an control to this OCX, to make it available to my friends.

StringGrid is a control very, very useful.
NetExpress is great, but it not have an StringGrid control.

Maybe the netx 3.1 do not can do it, but...

Can you help us?

Hugs.

P.S. aPicture is an OBJECT REFERENCE !?

[Migrated content. Thread originally posted on 28 January 2012]

Hi.

Sorry for my poor English.

I am trying to do this:

////Code flagment //////////////////////////////////////////////////
           Invoke   BitmapData "fromFileZ" Using
                    z"D:\\piSistemas\\Imagem\\Foto01.bmp"
                                       Returning BitmapOR

           Move     0                   To hPalette
           Move     1                   To fPictureOwnsHandle
           Invoke   OlePicture "fromBitmap" Using BitmapOR
                                                  hPalette
                                                  fPictureOwnsHandle
                                        Returning anObject

           Invoke   anObject "getDomainObject" Returning aPicture

           invoke   SCGrid "SetPicture" Using aPicture

////End of Code flagment ///////////////////////////////////////////


But, i get the "Member no found" message.

Obs: "Picture" is a property.

Compiler: NetExpress 3.1 (Trial)

Thanks in advance.

Antonio João
Brasil
Yes, aPicture is defined as an Object Reference.

Net Express 3.1 is a very old product and the only trial versions that were available would have been in the form of a 30 day evaluation copy which would have expired a long time ago.

I would suggest if you would like to do some new development with Net Express that you upgrade to a professional copy of Net Express 5.1 or look at the new Visual COBOL product.

Contact Micro Focus Sales and they can help you do either one.

Thanks.