Skip to Content
author's profile photo Former Member
Former Member

Unable to interpret " 1,100.0 " as a number

Hi all

Im getting this error when I try to print a customized sapscript form. This sapscript call a form from include file.

Here's the code:

FORM Cal_weight tables in_tab structure itcsy              
                       out_tab structure itcsy.            
                                                           
  DATA: mate TYPE STRING, "Material no                     
        mqty TYPE RESBD-BDMNG,"IOOPCOMP-MENGE, "QtySTRING  
        umret TYPE MARM-LAENG, "Temp qty                   
        umrez LIKE MARM-UMREZ, "B.UOM qty                  
        umren LIKE MARM-UMREN. "A.UOM qty                                                                                
READ table in_tab index 1.                               
  MOVE in_tab-value to mate.                                                                                
READ table in_tab index 2.                               
  MOVE in_tab-value to mqty.        <--- the error is pointing to here.                         
  umret = mqty.                                                                                
SELECT SINGLE UMREZ UMREN                                
  INTO (umrez, umren)                                      
  FROM MARM                                                
  WHERE MATNR = mate                                       
  AND MEINH = 'KG'.                                                                                
umret = ( umret / umrez ) * umren.                       
  mqty = umret.                                                                                
read table out_tab index 1.                              
  move mqty to out_tab-value.                              
  modify out_tab index sy-tabix.                           

ENDFORM.

And this is the call code in sapscript:

DEFINE &V_WEIGHT& = ''.
PERFORM CAL_WEIGHT IN PROGRAM ZFIR002
USING &RESBD-MATNR&
USING &RESBD-BDMNG&
CHANGING &V_WEIGHT&
ENDPERFORM.

Please advise

Thanks

az

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

2 Answers

  • Best Answer
    author's profile photo Former Member
    Former Member
    Posted on Apr 28, 2008 at 06:11 AM

    Make sure that 'mqty' is a character fied.

    otherwise write like this,

    replace ALL OCCURRENCES OF ',' in in_tab-value with ' '.

    MOVE in_tab-value to mqty.

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Apr 28, 2008 at 04:08 AM

    hi,

    Check out this way ...

    write in_tab-value to mqty.

    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.