web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Retail receipt font size in OPOS

(0) ShareShare
ReportReport
Posted on by

We have an EPSON TM-T82 printer, setup to print from AX with OPOS driver.

This was the result.

DSC_5F00_0009.JPG

As you can see, the font is so small it's painful to read. I have tried changing the font in Printer.cs from size 7 to 12, Courier New to Consolas but nothing changed. If I were to print using Windows driver for the same printer, with the same edited Printer.cs, the changes get reflected alright.

There was also a problem with alignment. Any bold text would randomly jump out of line no matter how I try to offset the difference.

DSC_5F00_0010-_2D00_-Copy.JPG

Note the first line (Bill) and Total line near the end.

Since we can't print the logo with Windows driver, we would prefer to use OPOS.

I wonder, if there is any other lines code that set the font for OPOS printer, or if there is any workaround for our problems. Any suggestion would be greatly appreciated.

Thank you

*This post is locked for comments

I have the same question (0)
  • Community Member Profile Picture
    on at
    RE: Retail receipt font size in OPOS

    Dear Phuong Nguyen,

    I printed "logo" by using Windows Driver...and by using Windows driver, we can bold  text and change the font size through code easily.

  • Community Member Profile Picture
    on at
    RE: Retail receipt font size in OPOS

    Can you please elaborate on how you got the logo printed with windows driver?

  • Suggested answer
    Community Member Profile Picture
    on at
    RE: Retail receipt font size in OPOS

    Follow these steps:-

    1) Create a logo image of dimension "121x132 pixels" and name the image file as "RetailPOSLogo" with ".bmp" extension.

    2) Place the image file at following path:-

          C:\Program Files (x86)\Microsoft Dynamics AX\60\Retail POS

    3) Now place the following code at the start of "printDoc_PrintPage" method in "Printer.cs" class

    private void printDoc_PrintPage(object sender, PrintPageEventArgs e)

           {

               try

               {

                   try

                   {

                       if (Array.Exists(printText, element => element.Contains("Terminal")))

                       {

                           Bitmap bitmap = new Bitmap(@"C:\Program Files (x86)\Microsoft  Dynamics AX\60\Retail POS\RetailPOSLogo.bmp");

                           Point point = new Point();

                           point.X = 80;

                           point.Y = 5;

                           e.Graphics.DrawImage(bitmap, point);

                       }

                   }

                   catch(Exception ex)

                   {

                   }

    4) Put some empty spaces at the start of Receipt design for logo to print.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Abhilash Warrier – Community Spotlight

We are honored to recognize Abhilash Warrier as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Martin Tocauer Profile Picture

Martin Tocauer 4

#2
Community Member Profile Picture

Community Member 2

#2
Nayyar Siddiqi Profile Picture

Nayyar Siddiqi 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans