In string spaces beween in text

hi experts ,
a(2)  type  c  VALUE KA,
b(4) type c  VALUE APPM,
c(10) type c VALUE ABCDE,
d(10) type c  123456.
VAL(22)  TYPE C .
now i am concatinating above fields in to  VAL .
WRITE : VAL .
OUTPUT IS KAAPPMABCDE123456
BUT I WANT OUTPUT : KAAPPMABCDE       123456
HOW TO SET SPACE BEWEEN IN TEXT
Moderator message: please consult ABAP documentation before asking.
locked by: Thomas Zloch on Sep 14, 2010 3:11 PM

First concatenate a,b,c to another variable - let's say x.
And then concatenate x and d with addition separated by ' '.
dagmar

Similar Messages

  • Importing space delimited iPad text files into number

    Lots of iPad app collect data as space delimited text files ( where is tab key on iPad) how can I import these files into numbers for analysis and plotting?

    Hi Wayne
    In the posted datas, some dates end with a period but some don't.
    Between values there are :
    period (not always. None after the 1st date and after the one just above "no scale travel to Tucson")
    space
    Given the source which I used, I got different spaces.
    In one case they were NO BREAK spaces
    In the example which you posted, the first missing period is revealed
    The second one isn't revealed because you didn't treated the entire set of datas.
    I assume that when there are datas after the decimal values, they are supposed to be in a 3rd column.
    Given these features, I wrote a script deciphering automatically the set of datas.
    Adjust the property « fromClipboard » to match what you use as source.
    --{code}
    --[SCRIPT split-table-from-ipad]
    Treat the set of datas imported from iPad by VerusEx
    see Apple Discussions forum :
    https://discussions.apple.com/thread/3879328?tstart=0
    Yvan KOENIG (VALLAURIS, France)
    2012/04/17
    property fromClipboard : true
    true = get datas from the clipboard
    false : get the datas from a text file
    on run
              if fromClipboard then
                        set lesValeurs to the clipboard as text
              else
                        set lesValeurs to read (choose file of type {"public.plain-text"})
              end if
    Instruction removing NO BREAK spaces which I got when I copied from the mail which I received from the forum.
              set lesValeurs to my supprime(lesValeurs, character id 160)
    Replace every groups of space characters by a single one
              repeat
                        if lesValeurs does not contain "  " then exit repeat
                        set lesValeurs to my remplace(lesValeurs, "  ", space)
              end repeat
    Replace single digit + space by single digit + tab.
    Useful to take care of cases when period is missing,
    or to split strings stored after a digit + a space
              repeat with i from 0 to 9
                        set lesValeurs to my remplace(lesValeurs, (i as text) & space, (i as text) & tab)
              end repeat
    Replace period + space by a tab
              set lesValeurs to my remplace(lesValeurs, ". ", tab)
    Save the deciphered datas in a temporary text file
              set leFichier to (path to temporary items as text) & "azertyuiop.txt"
              my writeTo(leFichier, lesValeurs, text, false)
    Open the temporary file in Numbers
              tell application "Numbers" to open leFichier
    end run
    --=====
    replaces every occurences of d1 by d2 in the text t
    on remplace(t, d1, d2)
              local oTIDs, l
              set oTIDs to AppleScript's text item delimiters
              set AppleScript's text item delimiters to d1
              set l to text items of t
              set AppleScript's text item delimiters to d2
              set t to "" & l
              set AppleScript's text item delimiters to oTIDs
              return t
    end remplace
    --=====
    removes every occurences of d in text t
    on supprime(t, d)
              local oTIDs, l
              set oTIDs to AppleScript's text item delimiters
              set AppleScript's text item delimiters to d
              set l to text items of t
              set AppleScript's text item delimiters to ""
              set t to l as text
              set AppleScript's text item delimiters to oTIDs
              return t
    end supprime
    --=====
    Handler borrowed to Regulus6633 - http://macscripter.net/viewtopic.php?id=36861
    on writeTo(targetFile, theData, dataType, apendData)
      -- targetFile is the path to the file you want to write
      -- theData is the data you want in the file.
      -- dataType is the data type of theData and it can be text, list, record etc.
      -- apendData is true to append theData to the end of the current contents of the file or false to overwrite it
              try
                        set targetFile to targetFile as text
                        set openFile to open for access file targetFile with write permission
                        if not apendData then set eof of openFile to 0
      write theData to openFile starting at eof as dataType
      close access openFile
                        return true
              on error
                        try
      close access file targetFile
                        end try
                        return false
              end try
    end writeTo
    --=====
    --[/SCRIPT]
    --{code}
    Yvan KOENIG (VALLAURIS, France) mardi 17 avril 2012
    iMac 21”5, i7, 2.8 GHz, 12 Gbytes, 1 Tbytes, mac OS X 10.6.8 and 10.7.3
    My Box account  is : http://www.box.com/s/00qnssoyeq2xvc22ra4k

  • How to Remove Blank spaces in the text elements for a smartform

    Hi All,
    Can any one please help me out to remove the blank spaces in the text elements.
    We are printing Labels using the Zebra Printer and we have rotated the windows to 90 degrees.
    We are able to see out text and barcodes. But the issues is when we are printing the label. We are getting spaces in the Text and in the Text elements fields. I have tried to give &g_name(C)&. But it is not working even i worked with style sheet spaces no luck.
    Currently out text and fields are printing like this
    s h r i y a n
    material number
    1111  -001  -000
    They should print like
    shriyan
    1111-001-000
    According to the ZEBRA suggestions we are using the font helve.
    Plase help us it is very urgent.
    Reward point will be given.
    Thanks

    Hi,
    Just use Condense g_name inside the program lines.
    Just to see how it behaves put a hard breakpoint.
    Break Username. and check the condense statement.
    condense <your field> no-gaps.
    Create program lines ahead of printing. give the field you want to condense in the input and output parameters of the program lines.
    Use condense inside the program lines.
    Thanks,
    Vamshi.

  • Space appears after text when you scroll to the bottom

    i am a newbie flash designer. a client has asked me to make modifications in a flash file used on his website. it is flash 8 actionscript. i am currently working on the same and would appreciate your help. the client has given me 'divisions.swf' file which i decompiled using sothink decompiler 4.5 build 90120 to '~divisions original.fla'. the xml folder resides in the same folder as ~divisions original.fla. it contains divisions.xml. you can download these files at http://rapidshare.com/files/257100523/space_after_text_when_scroll_to_bottom.zip
    i discovered a problem - if you view 'divisions.swf' - when you click on 'retail visual solutions'and scroll to the bottom, you can see that there is no space after the text. the end of the text aligns with the end of the scrollbar. but when you click on eyesite, and scroll to the bottom, you can see that there is space after the text. the end of the text does not align with the end of the scrollbar.
    please help me to resolve this problem.
    my additional questions are:
    has the creator of the swf file used some unique scrollbar code or is this scrollbar provided in flash itself. in this case, i can read a tutorial to understand it better.
    i have given 'is correct - no space at bottom of text.jpg' and 'is incorrect - space at bottom of text.jpg' to further explain my query.
    please tell me if i have explained my problem properly or further clarifications are needed.

    Try changing the code in frame 16 to be:
    stop ();
    var tString = xmlObj.Options.Option[2]._value;
    tString = tString.split("\r\n").join("\r").split("\n\r").join("\r");
    txt3.htmlText = tString;
    The scrollbar is a component that may or may not have been concocted by the original designer.  In any case it does utilize the FScrollbar feature of Flash.  You can read about it via the link below:
    http://www.adobe.com/support/flash/action_scripts/actionscript_dictionary/actionscript_dic tionary303.html.

  • Remove blank spaces in a text field?

    How can I remove blank spaces in a text field? Some text fields have a lot of blank fields that need to be removed so that I can report only on the text.
    CRXI
    Edited by: Burton Roger on Feb 10, 2009 5:48 PM

    Ex:
    "Hi,
    I have a need for monthly service desk reporting.
    Please provide data on single sheet.
    Thank you"
    I would like to shrink it down to -
    Hi, I have a need for monthly service desk reporting. Please provide data on single sheet. Thank you"

  • First time I press the space-bar the text entry hangs for several seconds

    Hi,
    When entering text, the first time I press the space-bar the text entry hangs for several seconds.
    From then on, there are no problems when entering text.
    iPhone 3G, iOS 4.2.1, no automatic correction and no spell checking.
    Thanks,
    Ofir

    Didn't resolve the problem
    There was some duplicated fonts fixed, but there wasn't the problem.
    Right now i'm writin this in Firefox and here is fine. Couldn't do this in Safari.
    I did make a video showing the problem.
    Also strange is the fact that in some tabs there isn't (aparently) the problem in Safari.
    Any other ideas?
    Tks
    http://gallery.me.com/kincas#100067/Spin%20beach%20ball

  • Remove single space in a text file

    In a text file data having single space , how to remove the single space using java program?
    Kindly reply ASAP.
    Thanks in advance
    Regards,
    Lakshmi

    It is seem that read a text file, then remove space from the string, Then output to other file.
    import java.io.*;
    public class eric_io {
    public static void main(String[] args) throws IOException {
         File inputFile = new File("input.txt");
         File outputFile = new File("output.txt");
    FileReader in = new FileReader(inputFile);
    FileWriter out = new FileWriter(outputFile);
    int c;
         System.out.println("Input from " + inputFile);
    while ((c = in.read()) != -1)
    out.write(c);
    in.close();
    out.close();
         System.out.println("Output to " + outputFile);
    }

  • Eliminate Tab spaces in Customer Text

    Hi SAP Gurus,
    I have a requirement.
    In Smartforms/Script I pull Text from SD Invoice at header level. This text is getting copied from Customer master into Invoice. In Customer master if user enter text along with the spaces or Tabs, It disturbs the Billing output layout. Text doesn't print properly on output. Is there any code available to avoid spaces or tabs in Text so that Text can print accurately.
    Thanks in advance.

    Hi naveen,
    CONDENSE
    Basic form
    CONDENSE c.
    Addition
    ... NO-GAPS
    Effect
    Shifts the contents of the field c to the left, so that each word is separated by exactly one blank.
    Example
    DATA: BEGIN OF NAME,
    TITLE(8), VALUE 'Dr.',
    FIRST_NAME(10), VALUE 'Michael',
    SURNAME(10), VALUE 'Hofmann',
    END OF NAME.
    CONDENSE NAME.
    WRITE NAME.
    produces the output:
    Dr. Michael Hofmann
    Addition
    ... NO-GAPS
    Effect
    Suppresses all blanks from the field c
    Example
    DATA: BEGIN OF NAME,
    TITLE(8), VALUE 'Dr.',
    FIRST_NAME(10), VALUE 'Michael',
    SURNAME(10), VALUE 'Hofmann',
    END OF NAME.
    CONDENSE NAME NO-GAPS.
    The contents of NAME is now " Dr.MichaelHofmann ".
    Since the field string NAME is interpreted and handled like a type C field, the CONDENSE statement treats it as a whole and ignores any sub-fields. The contents of the component field would therefore now be as follows:
    NAME-TITLE = 'Dr.Micha'
    NAME-FIRST_NAME = 'elHofmann '
    NAME-SURNAME = ' '
    Note
    Performance
    The runtime required to condense three fields is about 20 msn (standardized micooseconds). The variant ... NO-GAPS needs about 12 msn.
    Regards,
    Anand

  • Determining word boundaries when no space exists in text

    I am developing a text search feature for a viewer application and I run into PDFs quite often that do not use the space character to delineate word boundaries.  For example, a text showing operator with individual glyph positioning will contain strings and positioning information like this:
    [(de)15(grees)-262(and)-262(who)-262(w)10(ould)-262(contrib)20(ute)-262(an)]TJ
    When the strings are concatenated the result is:
    "degreesandwhowouldcontributean"
    Without spaces it's not possile to split the string into words based on character information.  It would appear the only information that could be used to guess word boundaries is the glyph positioning.  I have tested the documents in Adobe Reader and the application is able to correctly determine where word boundaries are, and it must be doing so by examing the glyph positioning and metrics.
    My first appreach was to get the glyph width for the space character, and assume a space is any position advance greater than the glyph width of a space.  The problem with that is the case where the font has been subsetted and the 'space' glyph is missing from the font.
    My second approach was to calculate the average glyph width for the font, then assume any text advance greater than 33% of the average glyph width is a space.  Works better but still not a reliable general solution.
    My question: does Adobe have a standard method for determining word boundaries when space characters are missing?

    Sounds like it's time for me to play some more "guesswherethewhitespaceis".  I've gleaned a bit by experimenting with Acrobat... feeding it text strings and increasing/decreasing glyph spacing to get an idea of how whitespace threshholds are being derived.  I discovered Acrobat gets word boundaries wrong on occassion so it seems to be an inexact process at best.
    Oh joy... in any case thanks for the reply.

  • [AS] Find a string of words in text

    Hello - hopefully someone can help as I'm now stuck on this. I want to be able to find a specific string of words within a text frame, though I want to be able to do this without using the Find Text Preferences approach.
    I can get it to work if i am just finding one word, but if there is more than one word it doesn't work.
    For example this works (given a text frame with text in that contains the word Example):
    tell application "Adobe Indesign CS5"
    tell active document
    set mybox to selected
      tell mybox
       set myfind to object reference of every word whose contents = "Example"
      end tell
    end tell
    end tell
    However the same does not work (searching for "The Example", which is two words)
    tell application "Adobe Indesign CS5"
    tell active document
    set mybox to selected
      tell mybox
       set myfind to object reference of every word whose contents = "The Example"
      end tell
    end tell
    end tell
    What i can't figure out is the correct phrasing for finding a string of words, i guess i should not be looking for the object reference of WORD, but nothing else i've tried seems to work. Many thanks for any help

    I think what John has said is correct… I only had a quick look in the dictionary terms. Without find/change the closest you may get is line or paragraph after that you would need to manipulate the line/para contents further… Word by definition I would think can't contain space but is encapsulated in space bar first/last…
    tell application "Adobe InDesign CS5"
    tell active document
    tell story 1
    set myfind to object reference of every word whose contents = "Example"
    end tell
    show text first item of myfind
    end tell
    end tell
    This would show the line you can then break down further…
    tell application "Adobe InDesign CS5"
    tell active document
    tell story 1
    set myfind to object reference of every line whose contents contains "For Example"
    end tell
    show text first item of myfind
    end tell
    end tell

  • Problems with string encoding - need the text content in char* format.

    The problem is non ASCII-characters, which comes out as some sort of unicode I need to desipher.
    Here's what I got:
    A text frame object with the TextString "Agnartjørna"
    I get the text content of this object into an ai::UnicodeString the following way:
    AIErr
    VMGetTextOfTextArt( AIArtHandle textArt, ai::UnicodeString &ucStr)
        ASUnicode *textBuffer = NULL;
        AITRY {
            TextFrameRef ateTextRef;
            AIX( sAITextFrame->GetATETextFrame( textArt, &ateTextRef));
            ATE::ITextFrame ateText( ateTextRef);
            ATE::ITextRange ateRange = ateText.GetTextRange( true);
            ASInt32 textLen = ateRange.GetSize();
            AIX( sSPBlocks->AllocateBlock( (textLen+2) * sizeof( ASUnicode), nil, (void**) &textBuffer));
            ateRange.GetContents( textBuffer, (ASInt32) textLen+1);
            /* trim off trailing newlines */
            if ((textBuffer[textLen] == '\n') || (textBuffer[textLen] == '\r'))
                 textBuffer[textLen] = 0;
            ucStr.clear();
            ucStr.append( ai::UnicodeString( textBuffer, textLen));
            sSPBlocks->FreeBlock( textBuffer);
            textBuffer = NULL;
           AIRETURN;
        AICATCH {
            if (textBuffer) sSPBlocks->FreeBlock( textBuffer);
           AIPROPAGATE;
    Now, the next step is to convert it into a form that I can use to call regexp.
    Baiscally, I want to detect the ending "tjørna" (meaning small lake) on a map label, and apply a standard abbevriation "tj^a" (with "a" superscripted).
    So the problem is to obtain the regexp pattern and the text content in same encoding.  And since the regexp library is old *char based, I would like to convert the text content in to plain old *char.
    Hence the following code:
    static AIErr
    VMAbbreviateTextArt( AIArtHandle textArt,
                             vmTextAbbrevEffectParams *params)
        AITRY {
        /* first obtain the text contents of the textArt */
           ai::UnicodeString ucText;
          const int kTextLen = 256;
          char textContent[kTextLen];
          AIX( VMGetTextOfTextArt( textArt, ucText));
          ucText.as_Roman( textContent, kTextLen);
    But textContent now has the value "Agnartj\xbfnna"  (According to XCode),
    which will not get a match on the pattern "tj([øe][rn])na\\" (with  backslash matching the end of the string)
    Any other ways to convert the textContent to a plain *char string?

    Thank you very much, your method will work fine. with
    the "UTF-8" parameter the byte[].length is double,
    cause every valid byte is preceeded by an -62, but I
    will just filter the valid bytes into a new array.
    Thanks again,
    StefanActually what you need to do is to find the character encoding that your device expects, and then you can code your strings in Arabic.
    That's the way Java does things; Strings and char values are always in UNICODE (see www.unicode.org) (which means \u600 to \u6ff for arabic) and uses a specified character encoding when translating these to and from a byte stream.
    Each national character encoding has a name. Most of them are identical to ASCII for 0-127 and code their national characters in 128-255.
    Find the encoding name for your display and, odds are, the JRE has it in the library.
    BTW the character encoding ISO-8859-1 simply maps UNICODE characters 0-255 on to bytes.

  • Empty space check for text box

    i need to verify null check for textbox fields and it sould not allow spaces as well.... is there any way like trim functions.. please help me..
    Already tried with JavaScript's trim() and not working... I'm using es3

    Hello and welcome to the forum,
    You do not tell which version you are using? And I suppose you are talking about a Text Entry Box?
    If you want to check if the right text is entered, you'll have to tick 'Validate User Input' in the General accordion of the TEB Properties panel.
    A HUD will appear under the TEB, labeled Correct Entries. With the + button you can add correct values (text that is correct when the TEB is validated), eventually check the 'Case Sensitive' option.
    In the Options accordion you can check the captions to appear (like for a button or a click box).
    When the user clicks the Submit button or uses the shortcut key for the TEB, one of two actions (Action accordion) will be performed:
    Success: if the text was correct, you can choose there for 'Go to Next Slide'
    Last Attempt after the attempts are exhausted
    Lilybiri

  • How to create spaces in a text file

    Hi forum
               i am creating a text file with the GUI_DOWNLOAD function, my problem is that i need to create some lines with spaces at the end of the line. But i can´t, i had concatenate spaces and i have created structures but in the file doesn´t appear that spaces to the end of the line. example
    -  line
      abcdefghij
    - i need
      abcdefghij******************
    = space
    tghnks
    Josue

    Thnks Pawan, the correct code to append spaces to the end of line for save in a file is, this is an example:
       <b>DATA: space_character type c.</b>
       DATA: s_var1 type c(10).
    *  Init the space character
       <b>space_character  = cl_abap_char_utilities=>minchar .</b>
       s_var1 = '123'.
    *   we need seven spaces more to complete the length of s_var1, then :
    * We need to concatenate into field
    DO 7 TIMES.
        <b>CONCATENATE s_var1 space_character INTO s_var1.</b>
    ENDDO.
    * Move to the internal table for save the text in a file
    MOVE s_var1 TO t_out-line.
    APPEND t_out.
    * Finally we call the GUI_DOWNLOAD function
      CALL FUNCTION 'GUI_DOWNLOAD'
        EXPORTING
          filename                        = fullpath
          filetype                        = 'ASC'
        TABLES
          data_tab                        = t_out
        EXCEPTIONS
          file_write_error                = 1
          no_batch                        = 2
          gui_refuse_filetransfer         = 3
          invalid_type                    = 4
          no_authority                    = 5
          unknown_error                   = 6
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
    And it´s all... looks easy but many partner doesn`t know
    Josué
    Code Formatted by: Alvaro Tejada Galindo on Jan 18, 2010 3:34 PM

  • How to format the spaces in a text file using bat file scripting

    Currently the records in my text file are like this:
    100239 0000015.00 
    QRP
    I want them to be like this:
    100266 0000015.00 QRP
    There should be 6 spaces before the first column and 8 spaces after that. There should be 1 space between the second and third columns.
    Generally this file contains approx 1000 records.
    Any help is highly appreciated.
    Thank you.

    So far it's like this:
    for /f "skip=2 delims=*" %%a in (C:\Bonus_File_Export.txt) do (
    echo %%a >>C:\newfile.txt    
    xcopy C:\newfile.txt C:\Bonus_File_Export.txt /y
    del C:\newfile.txt /f /q
    I've to format a text file generated by the tool Microstrategy and it feed it to another system in a specific format. Ihave removed the headers with the above script but was unable to remove the spaces between those columns.
    You can use this code as a basis for your script:
    @echo off
    set Line=
    if exist d:\temp\newfile.txt del d:\temp\newfile.txt
    for /F "skip=2 tokens=1-2" %%a in (d:\temp\test.txt) do call :Sub %%a %%b
    goto :eof
    :Sub
    if not "%2"=="" (
      set Line=      %1        %2
    ) else (
      echo %Line% %1>>d:\temp\newfile.txt
    It works provided that your input file uses this format:
    Header line
    Header line
    100239 0000015.00  
    QRP
    100240 0000016.00  
    QRR
    100241 0000017.00  
    QRS
    100242 0000018.00  
    QRT
    100243 0000019.00  
    QRU
    100244 0000020.00  
    QRV

  • Immutable String in a swing.text.Document

    Hello,
    I want to add to a text component an 'immutable' bit of text. That is a string that is one 'item', it can not be broken or split. If for example if you wanted to delete you would have to delete the whole thing, not part of it.
    Does anyone know how to do this?
    I'm currently using a JTextPane and struggling with the Document interface.
    Some context to this. I'm building a widget like the Outlook 'to field'. You type text in and it looks up that text in a list of contacts. You can select from the list. When you do this the contact is added to the text box and is underlined and made bold and becomes 'immutable' in the way that I have explained above.
    In an ideal World I would want to do this :
    be able to add a ContactElement to the text pane. Be able to specifiy that ContactElements are to be rendered in bold and underlined and would display the name attribute of the Contact object. These ContactElements would be 'immutable' as described above. Get a list of the ContactElements in the text pane and thus the contacts displayed.
    hope that makes sense, all help gratefully received,
    thanks, Tom

    When you insert a ContactElement, create two Position objects representing the start and end points of the element, and save them. Whenever the user moves the caret, refer to your list of ContactElement end points to see whether the new location is inside one. If it is, either whisk the caret to the other end or select the whole thing, whatever seems appropriate. I've never used it, but I believe NavigationFilter is the tool for that job.
    Any time text is deleted, you'll need to check the list to see if the deleted section contained any ContactElements, and to remove them from the list if so. I was going to recommend using a DocumentListener for that, but I don't think it would work; all the Positions would already have been updated. I suggest using a DocumentFilter to update the list before deleting the text.
    One complication that occurs to me is searching, or other operations that involve programmatic selection or highlighting. The NavigationFilter is too low-level; you'll have to make sure the search feature doesn't look inside ContactElements. You'll probably find other higher-level tasks that need to be aware of ContactElements so they can treat them specially.

Maybe you are looking for

  • .png file not showing up on windows VM

    Hello, I have users who are having issues seeing .png files when using a windows VM.  This is a windows environment.  The business partner is using a Mac pro and creates the .png file in creative suite and saves the file to a windows 2008 server.  Wh

  • Problem with browsing

    Initially I was able to browse normally using the data package from my mobile provider, recently I have not been able to, in the browser options the default browser configuration is set to Wi-fi Browser as an only option, which previously would have

  • Subcontracting PO - GR/IR difference

    Hi Masters, When users do a GR to a subcontracting PO for the price maintained, an additional FI document with small price is created which is actually equal to the price of the posting resulted through movement '543' (price of subcontracting materia

  • Computer will not turn on, is there a way to reset it?

    I need help, Pro Mac will not open. Any suggestion.Just got it for X-mas

  • Problem with Ipod Classic

    Hello I have an ipod Classic 160 GB. Recently I had to re-contruct my itunes library. I have synced the library and the ipod 3-4 times. Each time itunes seems to transfer the recordings and podcasts without any difficulties. However, nothing is comin