Skip to Content
Author's profile photo Former Member


Requirement: We have a current requirement where we need to print both ENGLISH and ARABIC texts and numerals in the same output form for Purchase Orders, Sales Orders, and Invoices etc.

Issue Faced: The smart forms while getting printed either shows the Arabic texts in jumbled format (when the print parameter passed is ‘EN’) or it shows all the numerals in Arabic (when the print parameter passed is ‘AR’).

Solution: We need to have the following things in place for printing bidirectional language texts (both fixed and dynamic) [in our case the languages being English – Left to Right (LTR) and Arabic – Right to Left (RTL)] in the same form printout:

  1. Create the form in Arabic language.


b. Create all the windows as mirror image of what is the actual output (for example you want a window to appear in the form output to the left topmost      corner – so define it at the right topmost corner and vice versa.)


     Here the page window is defined at the left lowermost part so that the page numberis printed at the rightmost lower corner.


c.     Pass the control print parameter language as ‘A’.


d.     Declare all numerals which you want to get displayed in English as dynamic texts.

       Before the declaration as dynamic text the output is as follows:


     If you have a look at the left hand window, we see that the text is coming in English but the numerals are in Arabic.

    After using dynamic text the numerals are now coming in English:


    So now we need to know, how to go ahead with using dynamic texts in Smart Forms:

    Let us take an example where we print the page number as

    Page <Page number> of <Total Page Count>.

    Step 1: Declare a variable of type TSFTEXT.


    Step 2: Declare a window for the Page number:


There is a text defined and a code piece.

  Step3: Text is defined as follows:


Step4: The code part is used to populate FNAME:


Now the page number is displayed as follows:


Assigned Tags

      You must be Logged on to comment or reply to a post.
      Author's profile photo Abdul Hameed Hussain
      Abdul Hameed Hussain

      Hi Barik,

           I was looking for the solution for this problem,but couldn't find any until this wonderful document.It's really helped me.Thank you .


      Abdul Hameed Hussain

      Author's profile photo Former Member
      Former Member
      Blog Post Author

      Its great that the document helped you.. đŸ™‚

      Author's profile photo Nooruddin Bohra
      Nooruddin Bohra

      Hi Argha,

      Thanks for the post.

      I am having a problem that if I am printing a line that starts with number or special character then it gets printed on right instead of left.  Also the special characters on last are getting printed on first place.

      I have written 1. Text 1 and so on.. But it is printing Text 1 .1

      Similarly page 1 of 1. is printed as .page 1 of 1


      It will be great if you can help me with this.


      Nooruddin Bohra

      Author's profile photo Sri Hari Anand Kumar
      Sri Hari Anand Kumar


      Did you got solution for this above issue ?

      Author's profile photo Richard Harper
      Richard Harper

      Anybody thoght about  Cascading Fonts ?