How to display or write quantity with decimals?

Exists some mask or function that make next?:
1.- If a quantity is 1500.000 should display 1,500
2.- If a quantity is 1500.010 should display 1,500.01
3.- If a quantity is 1500.555 should display 1,500.555
In others words, only display decimals if apply.

i think below code will helpful to u :
data: var(10) type c,
      var2 type string,
      var3 type string,
      var1 type string.
var = '15000.000'.
var1 = var.
split var1 at '.' into var2 var3.
if var3  ge '000'.
   condense var3.
   SHIFT var3 RIGHT DELETING TRAILING '0'.
   condense var3.
endif.
if not var3 is initial.
concatenate var2 '.' var3 into var.
write: / var.
else.
write: / var2.
endif.

Similar Messages

  • How to display the selection screen with icons as well as with text element

    How to display the selection screen with icons as well as with texts (written in text elements) for PlantDate, OrderType,WareHouse..

    Report zex33.
    type-pools: icon.
    selection-screen begin of line.
    selection-screen comment 1(20) text_001.
    parameters: p_werks type marc-werks.
    selection-screen end of line.
    selection-screen begin of line.
    selection-screen comment 1(20) text_002.
    parameters: p_whouse(10).
    selection-screen end of line.
    selection-screen begin of line.
    selection-screen comment 1(20) text_003.
    parameters: p_auart like vbak-auart.
    selection-screen end of line.
    initialization.
      write ICON_PLANT  as icon to text_001.
    concatenate text_001 text-001 into text_001 separated by space.
      write ICON_WAREHOUSE  as icon to text_002.
    concatenate text_002 text-002 into text_002 separated by space.
      write ICON_ORDER  as icon to text_003.
    concatenate text_003 text-003 into text_003 separated by space.

  • How to display the message along with a value using BBP_CHECK_BADI

    Hi Gurus,
    I need to display a message dynamically when the user create's a shopping cart. I am using Check_badi for this. i.e., I need to display the buyer number and amount left for him dynamically. I am storing both of them in variables and don't know how to display the messages laong with some message " the amount left for <XXXXXX> is <$$$$$$$$>". Can you help me out.
    Thanks,
    Neelima

    Hi,
    you can use the function module 'BBP_PD_MSG_ADD'. This is the function module normally used for the displaying the error messages in SRM.
    See wether you can use already available error messages , use the transaction SE91 , and the message class being BBP_PD

  • How in Illustrator I write text with transparent background ?

    How in Illustrator I write text with transparent background ?

    that is correct. You open it in AI and you have an option to use area text, you first take the text tool and drag to make a text frame, which wors like it does in a layout program. Or you click the text tool any where on the canvas and just start typing if you want to make another line you either hit the return (enter) key or for  soft return use shift/return (enter).
    The default is a transparent background.
    All art i Illustrator is on a transparent background unless you add an object behind other objects that has a fill color.

  • How to display a Math symbol with Subscript(like  "Xad", make the "ad" be Subscript )

    How to display a Math symbol with Subscript(like  "Xad", make the "ad" be Subscript )
    I need to show "Xad"(ad is Subscript )
    I try to find the letter subscript......but ,Unicode set is not have.....
    I try to use  X<sub>ad</sub>   show it  whit Text.htmlText,   but is not used,   I think Flex's HTML is  not support the <sub> mark.
    can you tell me , how to display a Math symbol with Subscript(like  "Xad", make the "ad" be Subscript )
    thank you very much.....

    http://blog.ggshow.com/index.php/how_to_use_subscript_aamp_superscript_in?blog=11
    http://jasonbejot.com/superscript-and-subscript-in-actionscript
    and thank you very very muck

  • How to display double byte characters with system.out.print?

    Hi, I'm a newbie java programmer having trouble to utilize java locale with system io on dos console mode.
    Platform is winxp, jvm1.5,
    File structure is:
    C:\myProg <-root
    C:\myProg\test <-package
    C:\myProg\test\Run.java
    C:\myProg\test\MessageBundle.properties <- default properties
    C:\myProg\test\MessageBundle_zh_HK.properties <- localed properties (written in notepad and save as Unicode, window notepad contains BOM)
    inside MessageBundle.properties:
    test = Hello
    inside Message_zh_HK.properties:
    test = &#21890; //hello in big5 encoding
    run.java:
    package test;
    import java.util.*;
    public class Run{
      public static void main(String[] args){
        Locale locale = new Locale("zh","HK");
        ResourceBundle resource =
            ResourceBundle.getbundle("test.MessageBundle", locale);
        System.out.println(resource.getString("test"));
      }//main
    }//classwhen run this program, it'll kept diplay "hello" instead of the encoded character...
    then when i try run the native2ascii tool against MessageBundle_zh_HK.properties, it starts to display monster characters instead.
    Trying to figure out what I did wrong and how to display double byte characters on console.
    Thank you.
    p.s: while googling, some said dos can only can display ASCII. To demonstrate the dos console is capable of displaying double byte characters, i wrote another helloWorld in chinese using notepad with C# and compile using "csc hello.cs", sure enough, console.write in c# allowed me to display the character I was expecting. Since dos console can print double byte characters, I must be missing something important in this java program.

    after google a brunch, I learned that javac (hence java.exe) does not support BOM (byte order mark).
    I had to use a diff editor to save my text file as unicode without BOM in order for native2ascii to convert into a ascii file.
    Even the property file is in ascii format, I'm still having trouble to display those character in dos console. In fact, I just noticed I can use system.out.println to display double byte character if I embedded the character itself in java source file:
    public class Run {
         public static void main(String[] args) throws UnsupportedEncodingException{
              String msg = "&#20013;&#25991;";    //double byte character
                    try{
                    System.out.println(new String(msg.getBytes("UTF-8")) + " new string");  //this displays fine
                    catch(Exception e){}
                    Locale locale = new Locale("zh", "HK");
              ResourceBundle resource = ResourceBundle.getBundle("test.MessagesBundle", locale);
                    System.out.println(resource.getString("Hey"));      //this will display weird characterso it seems like to me that I must did something wrong in the process of creating properties file from unicode text file...

  • Stock Quantity With Decimals

    Hi All,
    I have noted that we've got some stock items whose Quantity include Decimals yet they are suppossed to be whole numbers.
    For instance: for Bread: OITM.OnHand=10.5
    I want to come up with a query to display all these kind of items. Whats the right Condition in an SQL query to achieve this? Thanks
    Regards,
    Henry

    Try this query:
    Select itemcode, itemname from OITM where Onhand > Round(Onhand,0)
    Thanks,
    Gordon

  • How to create Report Writer Form with page longer than 255

    As i need to create report writer form with many columns which exceed than 1 acceptable page, how can I create since in writer there is no Horizontal Page as in report painter.
    Thank you very much.
    Sirirak

    check it out.
    pretty simple example
    http://www.baigzeeshan.com/2010/04/creating-simple-search-form-in-oracle.html
    here is the example what you 're looking instead of af:table have your form.

  • How to display BLOB image column with WEB application, JSF, ADF BC

    I looking for a way to display the content from a blob column on a WEB application, JSF, ADF BC
    The blob column contains a JPEG image.
    About the application
    The model contains a viewobject where the blob column attribute (photoimg) type is of type : BlobDomain
    Now I have to create the view to display the content of photoimg inside a JSF-JSP page.
    Any advice ?

    Search is your friend
    How to display the content of a BLOB column in a ADF/BC pages ?
    John

  • How to display the detailed navigation with the Search Results

    Hello Gurus,
    I was able to display the search results in the same frame rather than opening the new window and getting it displayed. Now when the search results are displayed, my detailed navigation and portal favorites etc.. all the iviews are automatically suppressed.
    Please help me displaying the search results with Navigation Panel.
    Regards
    V.

    Hi Vaibhav,
    What do you mean by suppressed?
    Is it gone, or just closed?
    If it is just closed, you can try 2 things:
    1. Check if the property "Initial State of Navigation Panel" of the page has any influence.
    2. There is a javascript method that opens it.
    You can see it by importing the file '<b>com.sap.portal.layouts.framework.par.bak</b>'.
    Navigate to
    System Administration -> Support -> Support Desk -> Portal Runtime -> Browse deployment
    then the folder
    ROOT/WEB-INF/deployment/pcd
    and press download.
    Import from par to Developer Studio, and check the javascript files under dist/PORTAL-INF for a function called something like 'expandTray'.
    Hope that helps,
    Yoav.

  • OLE: export quantity with decimals according to UoM

    Dear Guru,
    I encounter a problem when exporting data from Itab to Excel using OLE.
    In the itab, there are many Quantity fields (with UoM). When I export to Excel, I want the number of decimals of each quantity field must comply with UoM (for ex: PC with 0 decimal, Kgs with 3 decimals).
    I try to write the qty to text, it's ok but I also need the exporting qty is formatted as a number in Excel so user can do a sum.
    The solution for this problem seems complicated. I have to write qty to text, convert text to number...But for a large number of data, it is really slow.
    Is there anybody encounter the same problem? Please advice the solution.
    Thanks.

    > The solution for this problem seems complicated. I have to write qty to text, convert text to number...But for a large number of data, it is really slow.
    You make confusion about the real problem. Converting the quantity is not time consuming (or your program is really badly programmed ).
    What is time consuming is making many calls to OLE.
    To avoid that issue, SAP uses the Data Provider and the Desktop Office Integration (DOI). The whole data is sent to the frontend once (more or less), and sends only a few instructions to the frontend to process this data. I don't really know the exact process, but it's really, really  much faster.
    DOI can be programmed directly (there are SAP demo programs which show how it works, search forum), and there is an upper abstraction if you only need to paste data, set colors, that is indicated by Pedro.

  • In BEx, how to display hierarchy Upper Node with selected Lower Nodes only

    Currently I am displaying the Cost Centre (GFL Responsibility Cost Centre) hierarchy in a workbook. I want to be able to filter on this hierarchy dynamically. E.g. the upper node must be displayed including the rolled up results for this node, together  with a selection of the lower nodes e.g 2 nodes ( not all the lower nodes related to the upper node must be displayed in the query).
    What's possible when filtering :
    To filter on the 2 lower nodes only ( results are displayed as required)
    Not possible:
    When I include the higher node of the 2 lower nodes in the query, All the lower nodes of the higher node are displayed, and the filter selection of the lower nodes are over written.
    This is logically what's expected when the higher node is included in the filter.
    Creating a hierarchy variable gives the same problem, I am not able to filter on the hierarchy nodes as required.
                      <b>Upper Node</b>
              <b>Lower Node1 LowerNode2 LowerNode3</b>
    Filter the report for UpperNode and LowerNode 2 & 3 only
    <b><i>Thanking YOU in advance. Will reward points for the correct help</i></b>

    Hi
    Do you want to show particular node or particular level ?
    If you want particular node , then create hierarchy node variable and restrict to that node ( 3rd node)
    If you want particular level, what does that mean  say i am taking employee hierarchy and the hierarchy is as below.
    Ihe setting that we have is to expand upto n levels but  if yiou say i need level 2 what does that mean and how do you want to show in report ?
           A -
    (level 1)
           B,C,D( --child of A ) --- level 2
              E(Child of B), F(Child of C)   -
    level 3.
    Regards
    vamsi

  • How to display a long text with several in multiple lines in template cell

    Hi,
       here i have one string such as 'Power MOS_TestTestTest'. But it will display in the template cell as
       'Power
       MOS_TestTestTest'.
       And what i want is 'Power MOS_TestTes
                                   tTest'.
      How to achieve this ? ths

    Hi,
    If the Width of the Templete in not sufficient to display whole text then from the next word it is dislpayed in the next line. As in your case ..
    'Power
    MOS_TestTestTest'.
    If you want to have this like
    'Power MOS_TestTes
    tTest'.
    You need to write the logic to split the string as per your rquirement and print them.

  • How to display my alarm summary with using listbox?

    i am using fieldpoint and labview to log and monitor the temperatures of my system.
    and i want to save and display the time, date and value of the alarm signal, can anyone give me advice?
    in fact i don't know how to show more than one data in sting.

    Are you using the Datalogging and Supervsory Control (DSC) module with LabVIEW? This module makes it really trivial to configure and display Alarms.
    For more info' on DSC, please take a look at this:
    http://sine.ni.com/apps/we/nioc.vp?cid=1010〈=US
    Rgds,
    Khalid

  • How to display/input/write Chinese Text in java

    Dear All,
    I am trying to make a very simple java program, where I am trying to display Chinese characters. I am trying to save them into a file (for now, later into db2). However, I seem to make no progress at all.
    I am completely lost with this one. I have googled and gone through a lot of sites like :
    http://www.mandarintools.com/javaconverter.html
    http://www.chinesecomputing.com/programming/java.html
    http://forum.java.sun.com/thread.jspa?threadID=442220&messageID=1995079
    http://www.linuxforum.net/chinese/develop/java.html
    I have downloaded the cyberbit.ttf into /jre/lib/fonts and updated the fonts.properties also.
    I have tried to compile with two different encoding options big5 and gb2132 as well.
    I have also tried to pick up a few unicodes from a site and tried .. for ex.
    String s = "\U+0061";but this results in Illegale Escape Char. exception.
    All I am trying to do is use a String reference, feed it with Chinese text, which again I copied from a site, and then display it on the console. Or even write it to a file.
    I am lost in the maze of Unicode, UTF -8 etc.
    I would be really glad if someone could lead me out of this.
    Thanks in advance.
    Rgds,

    Hi,
    So I tried to actually start working on the web app where this change is intended.
    I copied a chinese String from a website (pasted it in Word, and it pasted fine).
    Pasted it in the text box and saved this field. The value appears gibberish in db2 ( I am sure the tables arent specified for UTF-8).
    My app doesnt use any contentType or characterEncoding either.
    Then when I retrieve this value, it comes as exact same gibberish as in DB.
    But, behold, when I change the encoding (view -> encoding -> chinese (GB2312)) It displays the exact String that was inserted :-)
    Then I add these lines in my Jsp.
    <%@ page contentType="text/html; charset=GB2312" %>
    request.setCharacterEncoding("GB2312"); .
    so that I can make that chinese GB2312 as the default option. It does that. (The default was Western European (ISO).
    However now, it displays question marks (????) in that field.
    What options can I have ?
    TIA

Maybe you are looking for

  • My iphone won't allow me to download new apps

    I have never had this issue before. It tells me I can retry. I am downloading apps directly on my phone. I was able to last night. It is not saying I need to reconnect to the internet but I am wondering if this is because of a bad internet connection

  • Creation of Stock transfer order using BAPI

    Dear Gurus,         I was trying to create Stock transfer order using BAPI function         BAPI_PO_CREATE         though i have defined Bsart as 'UB'         still it gives message :         " No master record exists for vendor MOH1 "         Please

  • Elements Organizer does not save contacts entered in Contact Book

    When I try to save contacts in either Elements Organizer 10 or 11 in the Contact Book, it saves nothing.  After I click the save button and reopen the contact book, anything I entered is gone. I've tried entering names as I'm preparing to send e-mail

  • Firefox is not supported on the architecture (mac g5, os 10.5.8

    I downloaded and installed Firefox 4 this afternoon. When I tried to open it I got an error message, "You can't open the application "Firefox" because it is not supported on this architecture. I have a Mac PowerPC G5 running OS 10.5.8 I should add th

  • A MDM Scenario Regarding accessing and displaying data

    Hi All, If there is a scenario such that there is a Manufacturer field from Main table[ Products ], has some vaues say A, B, C, etc. A suppose belongs to India, B to USA, C to UK, etc respectively. Then how can we do this that if a user is assigned t