Text printing in smartforms

Hi All,
My smartform has 3 pages namely FIRST, NEXT and TERMS.
I have 2 texts ( T1 and T2) to be printed on the smartforms. These texts are defined only in the first and the next pages.
The condition is that these 2 texts(T1 and T2) should be printed only till the 3rd last page and in the second last page only one text( T2) needs to be printed.
For example if there are 5 pages in a smartform then T1 and T2 both should be printed till page 3 and then T2 only should be printed on page 4.
I am trying to use the logic by comparing the values of sfsy-jobpages and sfsy-page but at runtime they are having the same values depending on the page the cursor is there.
Plz help me out to achieve this.

hi
    program lines is a node that we can insert in a loop within a window...you can code any logic just like in a normal abap program..so, you could do something like this
DATA: page1 type i, page2 type i, totalpage type i.
--->in your first page
totalpage = &sfsy-formpages&
page1 = &sfsy-page&
if page1 < ( totalpage - 2 )
write: T1, T2.
endif.
-->in your second page
totalpage = &sfsy-formpages&
page1 = &sfsy-page&
if page1 < ( totalpage - 2 )
write: T1, T2.
endif.
if page1 = totalpage - 1.
write T2.
endif.
if helpful, reward
Sathish. R

Similar Messages

  • Vertical text print in smartforms

    Hi Experts,
    I want to print text vertically in smartforms.
    Can any one tell me how to do that.
    Thanks in advance
    Dhananjay

    hi
    good
    i dont think there is any option to print the data vertically in smartform.
    thanks
    mrutyun^

  • Re : Problem in arabic text printing in smartforms

    Hi,
       In smartforms I am printing arabic text. Its coming correct up to the variable. But while printing Each and every word having space. How to avoid this space between thw arabic words while printing.
    Regards
    Anto

    When I export a SWF containing Arabic Text from Flash, I get
    no errors and everything is ok. The problem occur when I compile a
    SWF from Flex Builder, I'm using FP 9 for both files

  • Printing chinese text in a smartform.

    Whenever, I try to write chinese text in the smrtform, some weird characters appear. How can I paste chinese text in the smartform. Please provide me a solution.
    Moderator message: please do some research before asking.
    [Rules of engagement|http://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement]
    Edited by: Thomas Zloch on Feb 28, 2011 9:21 AM

    Please check with your basis that your output device support print Chinese character. Or, you can search more in forum, there are a lot of threads about print Chinese and other Unicode characters in form.
    Thanks,

  • Ukrainian text on preview is fine but gives junk char on print in smartform

    HI All,
    I am trying to print hardcoded ukrainian text in smartform. In preview it is coming correctly but while printing it gives some junk charecters.
    During my analysis i found out that previously existing hardcoded text is coming fine on printing but it is showing different charecters(than the one on the printing) in smartform node and in print preview.
    Regards,

    Hi,
    Do you use a device type that supports Cyrillic characters to create the spool and print? e.g. Device type SAPWIN, SAPWIN5 or Unicode device type SWINCF?
    If you use a non-Unicode device type like SAPWIN or SAPWIN5, then the font used for these characters in the smartform should be a Cyrillioc font like COURCYR, HELVCYR or TIMECYR.
    Regards,
    Aidan

  • Using read text fm in smartforms

    hi experts,
                  I have captured a text using Read_text Fm .now i need to use it inside a smartforms .how to do .
    i have used that code inside a program line .
    and in text i have called the field.
    declaration in form interface
    text type char20
    itab type tline
    in program lines
    data itab like TLINE occurs 0 with header line.
    CALL FUNCTION 'READ_TEXT'
      EXPORTING
    * CLIENT                        = SY-MANDT
        id                            = '0001'
        language                      = 'E'
        name                          = '0080000055'
        object                        = 'VBBK'
      ARCHIVE_HANDLE                = 0
      LOCAL_CAT                     = ' '
    IMPORTING
      HEADER                        =
      tables
        lines                         = itab.
    LOOP AT ITAB.
    text = ITAB-TDLINE.
    ENDLOOP.
    in text
    &text&
    but the text value is not printing .but i am getting the value when i do it in SE38.
    what shall i do?
    regards,
    mani

    Hi ,
        Instead of using the FM, Use the standard functionality to print the required text provided by Smartforms.
      Create a text element, in the left top...in the drop down there is an option of include text...
    id = '0001'
    language = 'E'
    name = '0080000055'
    object = 'VBBK'
    u will get the dessired output
    Regards,
    Himanshu

  • Issue with character formats using duplex printing in smartform

    Hi all,
    I am getting a problem with character formats using duplex printing in smartform. I am using a text module with a bold character to display text in a window. The problem is that on the first back page,the text is being printed normally (without bold), but on the next pages, the back pages are being printed with the bold character format.
    Can anyone know where is the problem..please.
    Points to be rewarded..
    Thanks.
    Regards,
    Zaheed.

    Hi Zaheed,
    Normally this should not happen.. and also there is no internal formatting done by SAP.. it will show based on what fomatting option we have specified..
    If you are saying it is happening in ur case then
         1. Recheck whether whether you have same text module getting printed on the
             two page. If they are different then then individual check formatting option for
             each..
          2. If above point does'nt work for you ..then instead of bold char use normal
              format for text element and see if it is printing same on both page..
    Try this out and let us know your findings...
    Enjoy SAP.
    Pankaj Singh

  • Zebra printing for smartforms

    Hi
    SAP version ecc6.0
    I want to roate a single text on the lable by 270 degrees. I have searched this forum and came to know about including a print control. therfore for the device type lzeb2( 200 dpi print head) created a print control z270 with the following A0BFD.
    description of the command
    Description The ^A command specifies the font to use in a text field. ^A designates the
    font for the current ^FD statement or field. The font specified by ^A is used only once for that
    ^FD entry. If a value for ^A is not specified again, the default ^CF font is used for the next
    ^FD entry.
    Format ^Afo,h,w
    This table identifies the parameters for this format:
    Important u2022 Parameter f is required. If f is omitted it defaults to the last value of the ^CF
    command.
    Command Details
    f = font name Accepted Values: A through Z, and 0 to 9
    Any font in the printer (downloaded, EPROM, stored fonts, fonts A
    through Z and 0 to 9).
    o = field orientation Accepted Values:
    N = normal
    R = rotated 90 degrees (clockwise)
    I = inverted 180 degrees
    B = read from bottom up, 270 degrees
    Default Value: the last accepted ^FW value or the ^FW default
    ^FD means field data
    my questions
    Do i have have to create a print control for 300 dpi printer  or is there a differenet universal  solution?
    secondly with ^A i specify the type of font i use....i simply don't wont to be concerned with the type of font? I want to use what is used in the smartform?
    thirdly the text to be printed it as the right hand side of the label so in order to see that the text gets printed i have to create
    which simply exceeds the length of the label length, but it achieves the rotation and the printing is within the label itself...strange
    do you guys have any alternative solution / recommendations
    thanks
    Sachin

    correction  for the below text in the thread
    "thirdly the text to be printed it as the right hand side of the label so in order to see that the text gets printed i have to create
    which simply exceeds the length of the label length, but it achieves the rotation and the printing is within the label itself...strange"
    thirdly  the text to be printed it as the right hand side of the label so in order to see that the text gets printed , i create a window
    that is horizontal but exceeds the length of the lable, but usiing the aforementioned command prints the text roated by 270 degress and within the label, so the text printed is within the label.
    I find it strange

  • Standard text from SO10 - smartform

    Hi Folks,
    I need to print a document with some standard text and the vendor address.
    1.For this I had created the standard text in S010,how to call this standard text in the text editor of the main window?
    This standard text will be the same for all the vendors.
    2.I need to fetch the address of the vendor.So I had created a select option.I have to print this document with the standard text for each vendor.Text will remain the same but the vendor address differs.I had created a structure having all the fields for the address and declared in the form interface.Internal table is getting populated but it is not printing in the smartform.
    How to get the document in one shot for all the vendors given in the range.
    Thanks,
    K.Kiran.

    u can call the standrd text from the smartform directly :
    got the smarform u created/ developed.
    create text.
    in the general attributes tab give the type <Include Text>
    assign the standard text that u want ot inclue.
    smartform will call that directly
    address cn be created direclty from the smartform
    in creation u will the get the option to create the address.
    just give th varible and populate the varible from the program.
    Thanks

  • Japanese Kanji is not printing in SMARTFORM eventhough it is showing in PP

    Hi All,
    I have a very peculier problem with smart form. When we are trying to print Quotation and Sales Order seperately in the SAME printer Kanji data(Material description VBAP-ARKTX)  is not getting printed for Sales Order but it is printing for Quotation. This Sales Order is created with respect the same Quotation. So SO hase same materials and same descriptions. When we check print preview in both the Forms we could able to see kanji data. But when we are trying to print or even trying to download using program RSTXPDFT4 kanji description is not coming in SO but it is coming in Quotation.
    only the difference we found between these smart forms is SMARTSTYLES.
    For Quotation used a style with TIMES type and
    For SO used a style with HELVE.
    I tried to change SO style to TIMES still it didnt work..
    I read in SDN reply that for style with HELVE we need to maintain font "JPMINCHO" in form.
    Can anybody explain where and how to maintain this font in the form.
    Thanks in advance.
    Purushotham

    Hi,
    If you use a non unicode device type like JPSAPWIN, you need to maintain font like JPMINCHO in the smartstyle for the paragraph and character formats that are used for the Japanese texts in the smartform. You should also use a smartform with language key JA.
    If you have a Unicode system and you create the spool via unicode device type SWINCF, then the font or the form language is not important. So can you try again creating the spool via device type SWINCF and check the result?
    Regards,
    Aidan

  • Arabic Printing using Smartforms

    Hi Gurus,
    I am trying to print arabic text using smartforms. I have set MS Word as the text editor. Arabic text is coming up correctly in the editor (Arabic font, Right-to-Left). I  created a Arabic smartstyle using A_TRAD font (I also tried other arabic fonts available). Now when I try to print it on HP LasetJet printer, the arabic text is coming up as single characters rather than words and lines. Different Arabic characters are not joined together to form words, they are all single characters separate from each other. Whereas arabic text is coming up correctly in the MS Word editor. Any help would be highly appreciated!!
    [email protected]

    Hi There.. Greetings...
    I am having the same problem of printing Arabic text in the smartform. The arabic Text is printing in opposite direction as well.
    what is the solution for this?
    Please help me.
    Looking forward to hearing from u.
    Kind regards,
    shekher

  • How to change TEXT EDITOR in SMARTFORMS

    Dear All,
    How to change TEXT EDITOR in SMARTFORMS i am getting editor like Microsoft Word but i want the regular editor.
    I am using ECC 6.0 GUI 710
    thanks,
    RP

    Solution By Mr. Eitan Rosenberg is correct.
    Program Name: RSCPSETEDITOR
    Thanks a lot.
    Regards..........

  • Printing a smartform to a different printer than my default

    I have a function module that gets passes a delivery number and the short-name of a printer.  The function module is supposed to print a smartform (pick list) for that delivery to the specified printer.  The problem is that no matter what I put in for the printer, it prints to my default printer.  If I change it, it will go there.  I'm sure I'm just missing some kind of setting.  Here is what I got:
    printer is the shortname for the printer i want, type RSPOPTYPE
    *Print Smartfomr picklist for  delivery
      data: ls_ctrl_prnt type ssfctrlop,
            ls_outp_opts type ssfcompop.
      ls_ctrl_prnt-no_dialog = 'X'.        " Suppres dialog
      ls_ctrl_prnt-device    = 'PRINTER'.
      ls_outp_opts-tddest    = printer.
      ls_outp_opts-tdprinter = printer.    " Specify required printer
      call function gv_func
        exporting
          control_parameters = ls_ctrl_prnt
          output_options = ls_outp_opts
          pk_hdr               = sf_info
          pk_orders            = sf_odrs
          pk_items             = sf_item
          pk_pgbk              = sf_pgbk
        exceptions
          formatting_error   = 1
          internal_error     = 2
          send_error         = 3
          user_canceled      = 4.
    Am I missing something here?  Any help would be greatly appreciated.
    Thanks,
    Curtis

    I was able to solve my issue. The field TDIMMED (print immediate) in the parameter OUTPUT_OPTION need to be passed with the value 'X'.
    The code is pasted below.
    DATA: l_ssfctrlop TYPE ssfctrlop,
            l_ssfcompop TYPE ssfcompop,
            l_formname  TYPE tdsfname,
            l_fm_name   TYPE rs38l_fnam.
      CLEAR l_formname.
    Get the smartform name based on the output type
      SELECT SINGLE sform FROM tnapr INTO l_formname
        WHERE kschl = ysdt_dynlayout-auart
          AND nacha = '1'
          AND kappl = 'V2'.
      Get the smartform function module name
        CLEAR l_fm_name.
        CALL FUNCTION 'SSF_FUNCTION_MODULE_NAME'
          EXPORTING
            formname           = l_formname
          IMPORTING
            fm_name            = l_fm_name
          EXCEPTIONS
            no_form            = 1
            no_function_module = 2
            OTHERS             = 3.
        IF sy-subrc EQ 0.
          l_ssfctrlop-no_dialog = 'X'.                        " print popup dialog box is suppressed
          l_ssfcompop-tddest    = usr01-spld.         " the printer name is passed from screen to this field
          l_ssfcompop-tdimmed   = 'X'.                    " print immediate option is set
          l_ssfcompop-tdcopies  = copies_in.         " number of copies of output required
        Call the smartform
          CALL FUNCTION l_fm_name
            EXPORTING
              control_parameters = l_ssfctrlop
              output_options     = l_ssfcompop
              user_settings      = ' '                            "manual override of user settings            
              i_del_head         = likp
              i_dyn_layout       = ysdt_dynlayout
            TABLES
              t_del_item         = ig_lips
              t_home_address     = ig_home_address
              t_header_text1     = ig_header_text1
              t_footer_text1     = ig_footer_text1
              t_footer_text2     = ig_footer_text2
              t_footer_text3     = ig_footer_text3
              t_text4            = ig_text4
              t_text5            = ig_text5
            EXCEPTIONS
              formatting_error   = 1
              internal_error     = 2
              send_error         = 3
              user_canceled      = 4
              OTHERS             = 5.
        ENDIF.

  • Text Prints as Black Instead of Assigned Swatch

    Hi, I have been having problems with text printing to a HP laser 5500dn printing as black in
    stead of the assigned swatch color.
    I am using CS3 on a Mac.
    It will print fine exported to PDF or printed on an inkjet.
    I have reset preferences.
    In the print dialogue box I have the following settings.
    I DO NOT have "Text as Black" selected.
    Color Management is: US Web Coated SWOP v2
    Color Handling is Let InDesign determine Colors
    Printer Profile is Document CMYK US Web Coated SWOP v2
    Output color is Composite CMYK (Unable to change in this configuration)
    Lastly, after printing and then closing the document,ID asks to save changes, When I cancel and review what edits were done, the last edit comes up as
    "Undo Change Ink"
    I don't know what that means.
    Suggestions?
    Thanks

    Thanks for your help.
    I haven't deleted the swatch or converted to another color.
    Not sure what you mean by aliasing the swatch.
    I did as suggested and looked in the printer setup in the print dialog and did not see anything to print text as black.
    So I ended up changing the text to several different colors and now it prints those colors fine.
    I think the color is so dark as to appear to be black when printing even though it is very apparent on the monitor that it is much different than black.
    I know that monitor colors and printer colors won't match, but this had me very baffled.
    Especially as the PDF printed much differently.
    So I guess I am going to print from the PDF to make sure the colors are as I want them to be.
    I work predominantly on a PC with CS3 that does not have Indesign; the Mac has CS3 with InDesign. The Mac routinely prints all documents much darker than the PC and what is displayed on the screen.
    Thanks, again.

  • How to print multiple form for tag printing in smartforms

    Dear Experts,
    I am working on tag printing in smartforms .in tag printing i am showing
    1.material no.
    2.material descrption.
    3.material doc no.
    4.Quantity
    5.supplier.
    my requirement is that for example , if the mat. document no.  has a material of 10,000.00 quantity , in tag printing it should come 1,000.00 of each tag  and total no of tag should be 10. and it should come one after another .
    and the page format size 8 x 6 cm. is it possible .if possible how ! how the system will know how many tag is to be printed . please reply its urgent.

    Hi Kumar,
    Let me know. is the quantity 1000.00 is fixed? if so thn you can achieve the requirement.
    For example:
    There are  A-material with 20000.00 quantity thn  u can first divide the quantity with 1000.00
                 v_ex = 20000.00/1000.00=20.
    thn  you can repeat the  print of the smartform for 20 times by passing  the parameter to  form fm.
    Please reward if  useful.

Maybe you are looking for