Welcome Serena Central users! CLICK HERE
The migration of the Serena Central community is currently underway. Be sure to read THIS MESSAGE to get your new login set up to access your account.
Ektoras Giorgos
New Member.
3697 views

Printing an MSCHART (mschrt20.ocx)

Jump to solution

Hello Developers, 

Does anyone know hot to print an mschart?

0 Likes
1 Solution

Accepted Solutions
Ektoras Giorgos
New Member.

RE: Printing an MSCHART (mschrt20.ocx)

Jump to solution

Sr10-MSC-1 is a MSChart control. I did it from the code you send me.

View solution in original post

0 Likes
10 Replies
Micro Focus Expert
Micro Focus Expert

RE: Printing an MSCHART (mschrt20.ocx)

Jump to solution

Is there a Print property in the def file?

0 Likes
Micro Focus Expert
Micro Focus Expert

RE: Printing an MSCHART (mschrt20.ocx)

Jump to solution

If there isn't a print property .. with 9.0 and above you can use XML extensions to take the values in your chart and create a HTML (XML) chart.

0 Likes
Micro Focus Expert
Micro Focus Expert

RE: Printing an MSCHART (mschrt20.ocx)

Jump to solution

I tried to find examples of how to do this ... what I found is that you need to copy the chart to the Windows clipboard and then print from there. There is an example of using the clipboard within COBOL here: community.microfocus.com/.../6143.aspx

0 Likes
Ektoras Giorgos
New Member.

RE: Printing an MSCHART (mschrt20.ocx)

Jump to solution

and then?

0 Likes
Ektoras Giorgos
New Member.

RE: Printing an MSCHART (mschrt20.ocx)

Jump to solution

how? have any code exaple?

0 Likes
Ektoras Giorgos
New Member.

RE: Printing an MSCHART (mschrt20.ocx)

Jump to solution

the code youre giving paste text to the clipboard, but i need some more complex. I must take all the control of active x (mschrt20.ocx) to paste it into clipboard.

0 Likes
Micro Focus Expert
Micro Focus Expert

RE: Printing an MSCHART (mschrt20.ocx)

Jump to solution

You can do an entire screen capture within COBOL .. community.microfocus.com/.../6805.aspx

0 Likes
Ektoras Giorgos
New Member.

RE: Printing an MSCHART (mschrt20.ocx)

Jump to solution

Can i just capture the MSChart control?

0 Likes
Ektoras Giorgos
New Member.

RE: Printing an MSCHART (mschrt20.ocx)

Jump to solution

ok i found it

          INQUIRE Sr10-MSC-1 SYSTEM HANDLE IN CHART-BMP.

          CALL    "W$BITMAP"       USING

                  WBITMAP-CAPTURE-IMAGE

                  "C:\A.BMP"

                  CHART-BMP.

     *             0

     *             1

     *             24.

     *Load bitmap

          CALL    "W$BITMAP"       USING

                  WBITMAP-LOAD

                  "PRINTFORM.BMP"

                  GIVING           PRTSCR-BMP.

0 Likes
Ektoras Giorgos
New Member.

RE: Printing an MSCHART (mschrt20.ocx)

Jump to solution

Sr10-MSC-1 is a MSChart control. I did it from the code you send me.

View solution in original post

0 Likes
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.