Space at the end of a word

Hello,
Is there a way to recognize space sign at the end of a sentence?
The meaning of that is that there is a word that somebody typed at the end of the sentence
and after that pushed the space bar . When looking at the text inside the sap system the text looks fine,
but when transferring to excel the text doesnt equal because the space at the end of the sentence.
Please advise
Yifat

Do you want to handle that space or just use the text value?
If you just want to use the text value (i.e 1word - space)...u simply say CONDENSE <UR TEXT VARIABLE>.
Else the other option is: Find the string length and then handle it the way u want.
Or if u r sure that every word has that extra space, and u dont want that u can even use SHIFT RIGHT BY 1 PLACE in thet text variable.
Hope this helps.
Thanks
Kiran

Similar Messages

  • Adding space at the end of a ritchEditableText  line

    Hi!
    I found an interesting behaviour in my application.  I have a RichEditableText component with a fixed width . If I add text till almost the end of the line and then  insert spaces, the cursor get's stuck at the end of the line. My surprise was on retreiving the text from that line in the code, where all that spaces existed even if they were not visible in the app. So on screen you see let's say 3 spaces, but then you save the text you can get 10. If you keep inserting any letter the cursor will move itself to the next line, but this does not seem to be the case of " "(space).
    I tested it useing the following code. I'm useing 4.1 sdk.
    <s:RichEditableText id="richTxt"  width="100" height="500" change="richTxt_changeHandler(event)" />
    protected function richTxt_changeHandler(event:TextOperationEvent):void
                    var noOfLines:int = richTxt.textFlow.flowComposer.numLines;             
                    for (var i:int = 0; i < noOfLines; i++)
                        var startIndex:int = richTxt.textFlow.flowComposer.getLineAt(i).absoluteStart;
                        var seqLength:int = richTxt.textFlow.flowComposer.getLineAt(i).textLength-1;
                        var textLine:String = richTxt.text.substr(startIndex, seqLength);
    I try to set clipAndEnableScrolling=true; for richTxt but this thid not change anything.
    How can I retrieve only the visible text( with the corect number of spaces at the end of the line) from the RET in order to save it ?
    Thanks !

    Do you want to handle that space or just use the text value?
    If you just want to use the text value (i.e 1word - space)...u simply say CONDENSE <UR TEXT VARIABLE>.
    Else the other option is: Find the string length and then handle it the way u want.
    Or if u r sure that every word has that extra space, and u dont want that u can even use SHIFT RIGHT BY 1 PLACE in thet text variable.
    Hope this helps.
    Thanks
    Kiran

  • Preserve a single space at the end of line using spool command

    Hi,
    Can you please help me to write the result of an sql query into a file with the last column of the row ending with a single space?
    For example:
    COL1DATA|COL2DATA|COL3DATA<space1>
    As mentioned in the example the col3 value in the file should end with a single space. And there should not be any delimiters at the end of the row.
    I tried with set trimspool on/off. But, it didn't work. When I say trimspool on - it is trimming all the trailing spaces.
    When I say trimspool off - it is retaining all the trailing spaces to the size of the line.
    But, I do not wish to modify the file through shell commands once it is written thru spool. I mean I do not wish to append spaces to the end of a line using shell script or any other method.
    I do not wish to use other methods like UTL_FILE also.
    Please help me how to do it using spool command?
    Thank you.
    Ramana

    My requirement is that all the trailing spaces should be truncated except the last one in the row.Why?
    As you have discovered a single column in sqlplus, is always a fixed length regardless of the size of the data, if the length of the data varies the output is padded to the maximum or line size with spaces. The trim and trimpsool commands are there to remove all the spaces from the end of a line if there are any. There are no commands to trim all the spaces except one, or even to trim all the spaces except two, or three even.
    If you want such custom processing you should post process the file in the OS using sed, awk or perl or something designed for such things.

  • How to add spaces at the end of record

    Hi Friends,
    i am creating a file which contains more than 100 records.
    In ABAP i have internal table with on field(135) type c.
    some time record have length 120, somtime 130 its vary on each record.
    but i would like to add space at the end of each record till 135 length.
    Can you please help me how to add speace at the end of record.
    regards
    Malik

    So why did you said that in your first posting? My glass sphere is out for cleaning...
    Instead of type c use strings and add spaces until they have the appropriate length.
    loop at outtab assigning <pout>.
      while strlen( <pout>-val ) < 135.
        concatenate <pout>-val `` into <pout>-val.
      endwhile.
    endloop.

  • Blank spaces at the end of an IDoc text field get lost when posted to R/3

    Hi Guys,
    I am facing the following issue:
    In an XML file-to-Idoc scenario, there are spaces at the end of a text field in the inbound XML file, which I can see when I open the inbound file with a text editor like notepad, and they are kept after XI mapping is executed (I can see them in message mapping simulator). However, it seems that these spaces get lost once the IDoc is posted to SAP R/3 and they are not visible on SAP R/3 side.
    Do you have any idea ? Thanks.
    Best Regards,
    Evaggelos Gkatzios

    That means SAP is removing the spaces from IDoc fields, where you spaces are not allowed. Does it create any problem?
    Thanks,
    Nabendu.

  • How to pad spaces at the end of a string

    Hi All,
    I am new to ABAP and need help to achieve this functionality
       I have to build a string with fixed lenth . my input string
      is always lesser than equal to X . I need to calculate and
       add that many spaces at the end of the input string .
      I tried to do this and getting the following error
        please help on this :
      if strlen( t_resultc ) < 525.
      RFILL(t_resultc,' ',525)
      endif.
      Error : Comma without preceding colon(after RFILL(T_RESULTC ?)
    Q: Can I use RFILL with out Select statement in a ABAP program
    Thanks & Regards
      KLK

    Hi,
    Try the following code but kindly make a note..
    Note:-USE quote like this  ` `, Instead of normal single quotes ‘ ’
    WHILE strlen( T_RESULTC ) < 525.            “Check the length   
       CONCATENATE  T_RESULTC ` ` INTO T_RESULTC. ”Add spaces at the end   
    ENDWHILE.
    Hope this helps,
    Andrew

  • Check space in the end to display warning message.

    I am currently working on validations on functional locations in the EDIT MASK. the code is already written for validations on to check for space in the beginning of the each level in the edit mask. however user requirement is that the program should produce warning messages for spaces regardless of where they appear in the Edit Mask. we have not validated to check for space at the end of each level.
    I have checked with condense ,shift string right deleting trailing spaces however I am not able to check for space at the end of levels.
    when i debugged the program the level8 length shows as 2 even though there is only one char in the level8. i
    could you please suggest any possible solution or any keywords that would help. you can go through the below code which is already written for checking space in the begining.
    here l_level1
    Level 8 errors
        l_length = STRLEN( l_level8 ).
    IF ( l_level8 = space AND l_dash_count > 6 ) OR
             l_dash_count > 7 OR
             l_length > 4.
          lt_mask_err-error = '8E'.
          APPEND lt_mask_err.
          l_errlvl8 = c_y.
        ENDIF.
    Level 8 Warning
        IF rb_bdc <> c_on AND p_warn = c_on AND
        ( l_level8 <> space AND l_level8+0(1) = space ).
          lt_mask_err-error = '8W'.
          APPEND lt_mask_err.
        ENDIF.
    i have added this code to display warning message using shift.
        l_lev8 = l_level8.                                                
        shift l_lev8 right.                                             
        l_length = STRLEN( l_lev8 ).                                    
        IF rb_bdc <> c_on AND p_warn = c_on AND                       
        ( l_lev8 <> space AND l_lev8+0(1) = space ).                    
          lt_mask_err-error = '1W'.                                     
          APPEND lt_mask_err.                                          
        ENDIF.

    You can use REGEX for string parsing, it is really handy. If you would like to test it out check out program "demo_regex_toy".
    Trailing space:
    FIND REGEX '[ ]+$' IN lv_text.
    leading space
    FIND REGEX '^[ ]+' IN lv_text.
    Any space
    FIND ALL OCCURRENCES OF REGEX '[ ]+' IN lv_text.

  • May I run "shrink DB/truncate free space from the end of file" at PROD?

    We have a SAP/MSS production system.
    The disk is full.
    We want to truncate the log file by:
    "shrink DB/truncate free space from the end of file"
    on the log file.
    How risk is it? Can we do it during production is running?
    Thanks! Points!

    Backup the log file (to save the data and keep a consistent backup) Then shrink the file. Its normal for the log not to shrink down to the size you want. Do not shrink past 1GB.
    DO NOT TRUNCATE - you are losing/dropping data and recovery will only be possible to the last on-line, or on-line plus last log/s.
    You can avoid a full log file by setting a 9002 trap - this will trigger a backup (like oraarch when you back up based on % full). Else you need to change the frequency of the backups for the logs to ensure the system never fills ups.
    You can Also add a second log file on a separate F/S if this occurs regular - which it shouldn't if you have a correct backup strategy.

  • My letter t is corrupt when it appears at the end of certain words--really!

    This is such a weird problem that none of the AppleCare people I've spoken to have ever heard of it before. As of a few days ago, when I type words that have the letter to at the end--simple words like that, next, what, at or best--the last t in the word turns into a symbol that looks like a cross. Here is an example:
    tha† isn’t right
    Look at the t at the end of the first word. As you can see it doesn't happen every time because isn't and right are fine. It's totally random. It also never happens at the beginning of a word, just the end. It happens in all apps, including Gmail, Word, Text Edit, Facebook, Mail, etc. I† happens in any font I use. As you can see, it just happened at the beginning of this sentence in the word It!
    So far Apple has had me reinstall Snow Leopard and that did nothing. They had me switch to a different keyboard and that did nothing. On my own I went into System Preferences and set it up so that the cross symbol would be substituted by t and that doesn't work either.
    The only thing that offers me a clue is that when we set up a new user account it didn't seem to happen in there, although I really haven't played with that enough yet to know if it's definitely not a problem in there. So it's very likely user-specific but I can't say for sure. Since I already  reinstalled the OS and it didn't go away I doubt that doing a clean erase and install would help either because this corruption seems to be in some file somewhere. I assume that if I start from scratch and do a backup from Time Machine the problem will follow me there too.
    Does anyone have the slightest clue wha† is going on here and how I can fix this? Any suggestions are GREATLY appreciated. It's totally annoying and bewildering!

    any suggestions

  • SPACE at the end of number of gl account  (ALPHA Conversion)

    Hi,
    While updating data from ODS to cube, it is giving error as <b>"Characteristic value '010000 ' of characteristic 0GL_ACCOUNT is not ALPHA-converted " </b>. If you can see there is added <b>SPACE</b> at the end of '010000'. This number is not generating any problem while activation of ODS but it generates it while updating ODS to cube . In ODS data there is no added space in it.
    Please help me to solve it. It is urgent. I will give full points for correct answer.
    Thanks.

    Hi,
    Assune your ODS name is ODS1 then you can see a transfer rules 8ODS1 under 0DM node. In that tranasfer rules you can see it ,at the dead end of <i>Communication str./Transfer rules</i> part of the screen.
    If you are not using Datamart concept, thats means if you have only update rules between ODS and Cube, then you need to make this setting in the Transfer rules used to upload the data to ODS . And then reupload the data to ODs and activation and further upload has to be done once this setting is over.
    With rgds,
    Anil Kumar Sharma .P

  • PI removing blank spaces at the end of the lines in a plain text file

    Hi -
    I have an interface that transfers a file via FTP. I defined both the sender and receiver to transfer either Text or Binary but the interface removes every blank space I have after the last character. The file is a fixed lenght file.
    Example:
    Original file:
    Hello world(space)(space)(space)(space)(space)(space)(space)(space)(eol)
    where (space) is the space character and (eol) is the end of line char.
    File after it is received.
    Hello world(eol)
    I already defined the parameter Row.fieldFixedLenghts with 10164 which is the lenght of the lines of the file.
    Any ideas why it may be happening?
    Thanks,
    Carlos.

    Hi -
    I tried both the parameters:
    xml.fieldContentFormatting
    structure.fieldContentFormatting
    The received file still has the problem. All the blank spaces are cleared out.
    The file is a plain text file not an XML file. May this be the issue?
    Thanks,
    Carlos.

  • Add space to the end of textfield value

    Hi,
      I have a requirement where I need to append 2 spaces to ta textfield at the end of field for certain conditions.
    I used Concat() function and if I checked the length, it added the space successfully in the scripting. But in the output display, it is not considering the space to the text. I need this particularly because all my text fields are right alligned and if I have a space appended to the text at the end, I should able to see it in the form
    for ex:
           I need     Martin     ( for the first text field)
                       Martin       ( with two spaces appended)
    I need the output in the above way.
    Can you please help me out.
    Sample code I wrote on scripting:
    var raw = $.rawValue
    $.rawValue = Concat(raw, Space(2))
    If I check the length of field, I could see that length got increased by 2. But I cannot display in the output.
    Thanks in advance,
    k.c

    Hi,
    Instead of inserting white spaces script to change the right indent:
    if (this.rawValue == "Martin")
        this.para.marginRight = "1.5mm";
    else
        this.para.marginRight = "0mm";
    This is Javascript, but I am sure it will run in FormCalc.
    N.

  • Blank space at the end of the TXT file using FDTA (T.code)

    We have created payment runs in Quality Client as follows:
    1. Payment Run ID MSA01 Run Date: 24.02.2011
    2. Payment Run ID MSA11 Run Date: 24.02.2011
    The resulting DME Files are as per our attachment.
    The file got rejected by the bank due to an extra white space on the last
    line of the DME File. The file should end immediately after the last
    character in the fle. We have not done any thing to the DME File structure.
    The connection to SAP CQ1 is now open and your user id and password are
    in the secure area.
    Thanks.
    Regards,

    Hi Kiran,
    Maybe check the following note to see if this addresses your problem:
    [1514624 - Extra CR (carriage return) in DME file created by RFFOGB_T program when run on AIX (unix system) |https://websmp230.sap-ag.de/sap(bD1lbiZjPTAwMQ==)/bc/bsp/sno/ui_entry/entry.htm?param=69765F6D6F64653D3030312669765F7361706E6F7465735F6E756D6265723D3135313436323426]
    Kind regards,
    Robert
    PS. unable to see in this note to which support package and release the note pertains.

  • Regarding blank space at the end of the record

    Hi All,
    We have a requirement where in which we have to pass either X or space to that field and this field is at the end of the record.
    I can download it to local pc or to an application server.
    If i pass normal space, i'm unable to view it when i download that to the local pc.
    I tried with cl_abap_char_utilities, i was able to get the tab, can you please tell me how can i acheive space both in the presentation and at application server.
    Thanks,
    Bharathi.

    Sowmya answer should work.
    Are you looking for something like this?
    CONSTANTS: BEGIN OF end_of_file,
      x(2) TYPE x VALUE '0D0A',
    END OF end_of_file.
    DATA: BEGIN OF itab OCCURS 0,
      line(20),
    END OF itab.
    itab-line = 'Hello World '.
    CONCATENATE itab-line end_of_file INTO itab-line SEPARATED BY space.
    APPEND itab.
    CALL FUNCTION 'GUI_DOWNLOAD'
         EXPORTING
              filename              = 'C:\helloworldtest.txt'
              write_lf              = ''
              trunc_trailing_blanks = 'X'
         TABLES
              data_tab              = itab.

  • Trailing Space at the end of Record

    Hi,
    I need a blank space at end of header record when transferring data to a file on application server.
    Appreciate help.
    Code:
      wa_header-empty         = space.           " Length 4 type char
      wa_header-rec_type     = 'ZREF'.           " Length 4 , constant
      wa_header-partner_id   = '1234'             " Length 35 type char
      wa_header-i_usr_id      = 'COMPANY'.   " Length 35 type char
      wa_header-p_id_qualf   = space.            " Length 4 type char
      TRANSFER  wa_header  TO  g_out_file.
    Desired output: enclosed in brackets.
    [    ZREF1234                               COMPANY                                ]
    The desired output has 28 trailing space after the text 'COMPANY'.

    Hi,
    Have you Tried the SHIFT hope it will solve out your problem,
    or use Concatenate To insert Spaces to Right Side inside a loop.
    Hi, Please Go Through the following Thread too hope will help you out.
    [How to retain spaces in a string|Re: How to retain spaces in a string...really urgent]
    Kind Regards,
    Faisal
    Edited by: Faisal Altaf on Feb 18, 2009 1:33 AM

Maybe you are looking for

  • Problem about execute import button

    This is mdm 5.5 sp4. First, i did field mapping and value mapping in mdm import manager. Then i clicked 'execute import' button. The importing was successful. After that, I added new fields in ‘destination fields’ of ‘field mapping’ panel via ‘add’ b

  • No installation disk with lion

    Hi Folks After runnuning a Verify Disk in Disk Utility, the program tells me I need to start the computer from my installation disk go to Disk Utility and then run Repair Disk.  I download my Lion upgrade from the App Store and have no installation d

  • Getting error to load wsdl from parner link

    i was try call google search web service from Jdeveloper using partner lik. it is giving me an error . Faied to read wsdl from http://api.google.com/GoogleSearch.wsdl. HTTP connection error code is 407. the wsdl can be opened from browser. Please hel

  • J2SE to J2EE - general question

    Hi, I have an application, made up of several classes, written in J2SE. What does it entail to make these classes J2EE-compliant? changing import statements to include J2EE-specific classes? is it a major overhaul?

  • Unable to create iView from template

    Hi, I'm unable to create new iView from a template If I try to create a new iView I get no selection of iView templates. The step 1 of Template selection shows the message: "No templates to display. You are not assigned to any existing templates." I