Special characters into datagrid through the use of buttons

Hi!
I have a datagrid for word input, I'm trying to create a "special characters" panel, kind of like google's new "virtual keyboard" thing on google.com, so that the user can enter data into the datagrid cells using characters that aren't on their keyboards.
I manage to do this just fine, using the solution below. I know this is probably not the best/most effective way to do this, so any suggestions for making the code better will be appreciated. I only started using Flex a month ago.
grid.addEventListener(DataGridEvent.ITEM_EDIT_BEGIN, selectColumn)
function selectColumn(event:DataGridEvent):void
var selectedColumn:DataGridColumn = grid.columns[event.columnIndex];
selCol = selectedColumn.dataField;
//The function for adding a special character to the selected datagrid column by clicking a button:
//(inputWordArray is the dataprovider for the grid called "grid" )
protected function clickSomeButton(event:MouseEvent):void
var colIndex:int = new int;
if (selCol == "from"){
inputWordArray[grid.selectedIndex].from = inputWordArray[grid.selectedIndex].from + "æ";
colIndex = 0;
else if (selCol == "to"){
colIndex = 1;
inputWordArray[grid.selectedIndex].to = inputWordArray[grid.selectedIndex].to + "æ";
inputWordArray.refresh();
grid.dispatchEvent(new DataGridEvent(DataGridEvent.ITEM_EDIT_BEGINNING, false, false, colIndex, null, grid.selectedIndex));
The problem is that this only adds a letter at the end of the selected item's value, not at a specific position within the word specified by the position of the cursor. This is what I need to achieve. I have no idea even what to search for, if anyone could please give me a hint that'd be great.

You will probably need to capture the editor's selectionBeginIndex and
selectionEndIndex

Similar Messages

  • How i can transmitt audio in LAN through the use of Java JMF

    can anynone help me to give the code for audio transmission in LAN through the use of JMF classes

    If you need help with JMF, there's a forum specificlly for JMF. Go ask your JMF question there...

  • How do you put safari web pages into icloud with the safari iCloud button?

    how do you put safari web pages into icloud with the safari iCloud button?

    What that button does is sync your tabs between your devices. So if you have multiple macs with Mountain Lion and/or devices with iOS 6 (once it comes out this fall) you can pick up where you left off. For example, let's say I have apple.com, nytimes.com, and facebook.com open on my mac, but I need to run. Later, if I need to use another computer in my household, I can just restore the tabs that I was using before on this other mac.

  • CAN I SAFELY download the free audacity library mp3 file to my Macbook Air MAC OS X 10.6.8 through the audacity option button??

    CAN I SAFELY download the free audacity library mp3 file (libmpslame.dylib) to my Macbook Air MAC OS X 10.6.8 through the audacity option button without crushing my computer?? Also (since my friend installed audacity I can only get out of it by force quitting. Am I doing something wrong?

    I just had the same problem, I've updated to 10.6.8 yesterday, and since then the browsing are very slow, no matter what broswer I am using, the upload download speed are still the same. But browsing just take forever, It takes for example google.com 30 seconds to load. I have Extream high speed internet connection, 3 other computers, and the only one is having this problem is the Mac after the update.
    Something in this update screwed my browsing capabitilties, I tried downloading Crome browser, same issue.
    I hope there is a way beside TimeMachine to revert the latest update. I don't want to reformat as I am sure as soon as I am going to do the update it will cause the same problem.
    Model Name:    iMac
      Model Identifier:    iMac11,3
      Processor Name:    Intel Core i7
      Processor Speed:    2.93 GHz
      Number Of Processors:    1
      Total Number Of Cores:    4
      L2 Cache (per core):    256 KB
      L3 Cache:    8 MB
      Memory:    12 GB
      Processor Interconnect Speed:    4.8 GT/s
      Boot ROM Version:    IM112.0057.B00

  • How to insert & # special characters into oracle table?

    I have a text value which contains special characters such as & and #.
    After I pass from one page to another,
    TEST& becomes "TEST&"
    I put " " on the above test, otherwise amp; will be truncated by OTN).
    TEST# becomes TEST (# is truncated).
    Actually the value is saved in table like this: "TEST&"
    How to solve this problem?
    How to insert & into table without &
    Thank you.
    Edited by: user628655 on Jul 27, 2009 9:47 AM
    Edited by: user628655 on Jul 27, 2009 9:49 AM
    Edited by: user628655 on Jul 27, 2009 10:39 AM

    Avoid doing that through a link. If this is a page item then submit the page and redirect to the target page using a branching. On the target page, create a computation to compute the target item using the original page item as the source. If you are talking about a report, use the id to pass through the link and fetch the text column in an on load computation.
    Denes Kubicek
    http://deneskubicek.blogspot.com/
    http://www.opal-consulting.de/training
    http://apex.oracle.com/pls/otn/f?p=31517:1
    ------------------------------------------------------------------------------

  • HTML Editor - converting "special characters" into entities

    Hi everyone,
    I'm currently in the middle of formatting my wife's novel into 'clean' html so I can use Calibre to create a well formatted epub/mobi/etc.
    I've read that TextMate on Mac includes a function to "Convert Selection to Entities excluding Tags".  In other words it will replace all special characters (ellipses, copyright sign, etc) with the html entities.
    I'm currently using Kate and I can't seem to find anything similar.  Is anyone aware of any linux editors with the same function?
    Thanks for the help!

    ctarwater wrote:Encoding is already UTF-8 but I'm trying to make these docs as "universal" as possible and I've read that little things like replacing quotation marks and other symbols with their html entities is a good step in that direction.
    In situations with multiple encodings this might be the case, but the XML spec requires UTF‐8 support at minimum and defaults to it when the encoding is not declared. All XML parsers can deal with UTF‐8.
    In fact, replacing UTF‐8 characters with entities is less portable in XML. This is because the available entities are defined by the doctype, and XML only supports five by default (<, >, ", &, and '). Things like … are defined in the HTML and XHTML doctypes, but not in other dialects of XML. This used to bite RSS pretty hard (probably still does), because people assumed the entities were available everywhere when they’re really not. EPUB and Mobi are based on XHTML, but other formats might use other XML dialects.

  • How to export special characters into an XML file?

    Dear experts,
    We read files from our customers and save data into our customized table without any character changed, including some address fields. In those address fields, some special characters (not in our code page) are also kept. When we want to write these address fields into an XML file or flat file, the special charcters become "##" or not readable, can anyone help us to solve this issue?
    Question1: How to write special code to an external file?
    Question2: how to use 'CALL TRANSFORMATION' from an internal table to an XML file?
    Your answer is highly appreciated!
    Joanne

    Hi Joanne.
    Please check the below link.
    CALL TRANSFORMATION
    Before that u have to create one transformation program in STRANS tcode for using it in call transformation statement.
    Hope it will be useful.
    Regards,
    Lakshman

  • Can't read special characters in an excel file using JDBC

    Hi! I 've a code to read an excel file using JDBC-ODBC bridge. I can read the values, but any special characters is readed wrong, just symbols. The special characters are of spanish language. This is my code:
                    Locale currentLocale;
              currentLocale = new Locale("es", "MX");
              Locale.setDefault(currentLocale);
                   Class.forName( "sun.jdbc.odbc.JdbcOdbcDriver" );
                   c = DriverManager.getConnection("jdbc:odbc:Driver={Microsoft Excel Driver (*.xls)};DBQ=comisionesperfiles.xls");
                   stmnt = c.createStatement();
                   String query = "Select * from [Hoja1$]" ;
                   ResultSet rs = stmnt.executeQuery( query );
                   while( rs.next() ){
                        String valor = rs.getString(2) ;
                        if(valor != null && !"null".equalsIgnoreCase(valor)){
                             if(!comisiones.contains(valor)){
                                  System.out.println(valor);
                                  comisiones.add( valor );
                   rs.close();
                   stmnt.close();As you can see, I've tried to set the locale, but it didn't work.
    I'm using Excel 2003, Java Version 1.4.2_07 and Windows XP Professional (in latin american spanish).
    Hope someone can help me!

    FYI: Apache's POI can read/write Excel files in Java:
    http://jakarta.apache.org/poi/index.html

  • Special characters being read from the unicode file for greek language

    Hi All,
    I have a report which would upload a unicode file and then update the vendor master data accordingly.
    The file contains greek characters too.
    when the file is being read in the code, some special characters are being added up to the vendor number which is the first entry. The special characters are not included in the file , but are added up only to the first vendor number and not any other vendor numbers.
    The logic that is being used is as follows :
    TRY.
          IF unicode IS INITIAL.
            IF codepage IS INITIAL.
    *-->      For backward compatibility where this FM might be called from
    *         other dependent objects (FMs/dynamic subroutines)
    *         which donot have access to  user's input w.r.t Unicode parameters
              OPEN DATASET filename FOR INPUT
                   IN LEGACY TEXT MODE
                   MESSAGE msg
                   REPLACEMENT CHARACTER repl_char
                   IGNORING CONVERSION ERRORS
                   FILTER filter.                         
            ELSE.
    *--> System in non-unicode and Unicode Environment (Phases I and II)
              OPEN DATASET filename FOR INPUT
                   IN LEGACY TEXT MODE CODE PAGE codepage MESSAGE msg
                   REPLACEMENT CHARACTER repl_char
                   IGNORING CONVERSION ERRORS
                   FILTER filter.                          
            ENDIF.
          ELSE.
    *-->  Extract File in Unicode format - Phase III
            OPEN DATASET filename FOR INPUT IN TEXT MODE ENCODING UTF-8
            MESSAGE msg
            FILTER filter.                                 
          ENDIF.
          IF sy-subrc NE 0.
            MESSAGE e001(zuni) WITH filename sy-subrc
             RAISING file_open_error.
          ENDIF.
    the unicode parameters used are : codepage = 8000.
    An early reply is most appreciated.
    Regards,
    Manu.

    Please check SAP notes for Eastern European Characters in Unicode system. and may be below code helps you
    DATA:
        ltp_bom                  TYPE sychar01,
        ltp_encoding             TYPE sychar01,
        ltp_codepage             TYPE cpcodepage.
    Processing --------------------------------------------------------- *
      TRY.
          CALL METHOD cl_abap_file_utilities=>check_utf8
            EXPORTING
              file_name         = itp_filename
              max_kb            = -1
              all_if_7bit_ascii = abap_true
            IMPORTING
              bom               = ltp_bom
              encoding          = ltp_encoding.
        CATCH cx_sy_file_open .
          MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                  WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4
                  RAISING file_open_error.
        CATCH cx_sy_file_authority .
          MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                  WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4
                  RAISING file_authority_error.
        CATCH cx_sy_file_io .
          MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                  WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4
                  RAISING file_io_error.
      ENDTRY.
      CASE ltp_encoding.
        WHEN cl_abap_file_utilities=>encoding_utf8
          OR cl_abap_file_utilities=>encoding_7bit_ascii.
          CASE ltp_bom.
            WHEN cl_abap_file_utilities=>no_bom.
              OPEN DATASET itp_filename FOR INPUT IN TEXT MODE
                ENCODING UTF-8.
            WHEN cl_abap_file_utilities=>bom_utf8.
              OPEN DATASET itp_filename FOR INPUT IN TEXT MODE
                ENCODING UTF-8
                  SKIPPING BYTE-ORDER MARK.
            WHEN cl_abap_file_utilities=>bom_utf16_be.
              ltp_codepage = '4102'.
              OPEN DATASET itp_filename FOR INPUT IN LEGACY BINARY MODE
                BIG ENDIAN CODE PAGE ltp_codepage.
            WHEN cl_abap_file_utilities=>bom_utf16_le.
              ltp_codepage = '4103'.
              OPEN DATASET itp_filename FOR INPUT IN LEGACY BINARY MODE
                LITTLE ENDIAN CODE PAGE ltp_codepage.
            WHEN OTHERS.
              OPEN DATASET itp_filename FOR INPUT IN TEXT MODE
                ENCODING UTF-8.
          ENDCASE.
        WHEN OTHERS.
          OPEN DATASET itp_filename FOR INPUT IN LEGACY TEXT MODE.
      ENDCASE.
    Edited by: Nilesh Shete on May 7, 2010 5:29 PM

  • How to you enforce special characters under Authentication in the CMC?

    Is there a way to to enfoce special characters in the password for user authentication?  I do know BO XI R2 SP3 does allow special characters, but I would like to notify users when they get prompt to change their password.

    Margaret,
    Using the CMC, navigate to the entry entitled "Authentication", next choose the tab "Enterprise".
    There are two key options (they appear towards the top), and here is a brief explanation of these:
    When you enable the enforce mixed-case passwords option, then it ensures that passwords contain at least two of the following character classes: upper case letters, lower case letters, numbers, or punctuation.
    The second option, must contain at least (N) characters stipulates the minimum length that a user can choose for his or her password.
    From a practical point of view, I would say that if you have the first option taken (enforce mixed-case), then your next option should be set at no lower than 8.
    As far as educating the user, this is done externally from the web page when it presents to the user (the user gets three prompts:  old password, new password, and re-type new password).  As far as a clue to using at least two of the upper/lower/number/punctuation in their password, I don't know how you communicate that other than an internally circulated "Introduction to Our System" handout and you include this tidbit amongst other details you'd like your users to know, etc, etc.
    Thanks,
    John

  • Parsing BLOB (CSV file with special characters) into table

    Hello everyone,
    In my application, user uploads a CSV file (it is stored as BLOB), which is later read and parsed into table. The parsing engine is shown bellow...
    The problem is, that it won't read national characters as Ö, Ü etc., they simply dissapear.
    Is there any CSV parser that supports national characters? Or, said in other words - is it possible to read BLOB by characters (where characters can be Ö, Ü etc.)?
    Regards,
    Adam
      |
      | helper function for csv parsing
      |
      +-----------------------------------------------*/
      FUNCTION hex_to_decimal(p_hex_str in varchar2) return number
      --this function is based on one by Connor McDonald
        --http://www.jlcomp.demon.co.uk/faq/base_convert.html
       is
        v_dec number;
        v_hex varchar2(16) := '0123456789ABCDEF';
      begin
        v_dec := 0;
        for indx in 1 .. length(p_hex_str) loop
          v_dec := v_dec * 16 + instr(v_hex, upper(substr(p_hex_str, indx, 1))) - 1;
        end loop;
        return v_dec;
      end hex_to_decimal;
      |
      | csv parsing
      |
      +-----------------------------------------------*/
      FUNCTION parse_csv_to_imp_table(in_import_id in number) RETURN boolean IS
        PRAGMA autonomous_transaction;
        v_blob_data   BLOB;
        n_blob_len    NUMBER;
        v_entity_name VARCHAR2(100);
        n_skip_rows   INTEGER;
        n_columns     INTEGER;
        n_col         INTEGER := 0;
        n_position    NUMBER;
        v_raw_chunk   RAW(10000);
        v_char        CHAR(1);
        c_chunk_len   number := 1;
        v_line        VARCHAR2(32767) := NULL;
        n_rows        number := 0;
        n_temp        number;
      BEGIN
        -- shortened
        n_blob_len := dbms_lob.getlength(v_blob_data);
        n_position := 1;
        -- Read and convert binary to char
        WHILE (n_position <= n_blob_len) LOOP
          v_raw_chunk := dbms_lob.substr(v_blob_data, c_chunk_len, n_position);
          v_char      := chr(hex_to_decimal(rawtohex(v_raw_chunk)));
          n_temp      := ascii(v_char);
          n_position  := n_position + c_chunk_len;
          -- When a whole line is retrieved
          IF v_char = CHR(10) THEN
            n_rows := n_rows + 1;
            if n_rows > n_skip_rows then
              -- Shortened
              -- Perform some action with the line (store into table etc.)
            end if;
            -- Clear out
            v_line := NULL;
            n_col := 0;
          ELSIF v_char != chr(10) and v_char != chr(13) THEN
            v_line := v_line || v_char;
            if v_char = ';' then
              n_col := n_col+1;
            end if;
          END IF;
        END LOOP;
        COMMIT;
        return true;
      EXCEPTION
         -- some exception handling
      END;

    Uploading CSV files into LOB columns and then reading them in PL/SQL: [It&#146;s|http://forums.oracle.com/forums/thread.jspa?messageID=3454184&#3454184] Re: Reading a Blob (CSV file) and displaying the contents Re: Associative Array and Blob Number of rows in a clob doncha know.
    Anyway, it woudl help if you gave us some basic information: database version and NLS settings would seem particularly relevant here.
    Cheers, APC
    blog: http://radiofreetooting.blogspot.com

  • How to add special characters into numbers?

    Hi, I wonder how can I add special characters like the one in the "Edit" menu for the Mac versions? Thanks.

    It all depends what exactly you are talking about, so if you tell us, someone can help you. Some can be made from the keyboard, others you would need to copy/paste from an app like Unicode Map.

  • Turning off audio while shuttling through clips using keyboard buttons

    Is there a way to turn off the audio while shuttling through clips when using either the J, K, and L buttons or the left and right arrow keys?  I have audio skimming turned off but this only turns off the audio while skimming with the mouse, and not using the keyboard buttons above when you want to make a more precise edit.
    Many thanks for your help!!

    Hi Russ,
    Thank you for replying.  You're correct that keyboard shorcut toggles the audio skimming on & off, but if it's off I'm still hearing audio while I shuttle through clips using the keyboard buttons J & L or using the Left & Right arrow keys.  I would think that would turn off the audio for those functions too and not just skimming with the mouse.
    Do you know of a solution?
    Thanks,
    Reid

  • I have upgraded to Mavericks and I now cannot import DV into FCP through the capture presets.

    Since upgrading to Mavericks, I cannot import DV vision through my Sony FX-1E. I have tried various connections - DV to Firewire 400 + 800 with no success. I now have to get the vision ingested at another facility and exported to a hard drive in order to edit.
    Is there a way I can get vision into FCP?

    FCP (not FCPX) is legacy software, now EOL and not designed or guaranteed to work with Mavericks, some people report no problems others do, it depends on your setup. I'd suggest using iMovie to capture your footage then transfer to FCP to save using (or paying) another facility. An alternative (and my own solution) is a second boot drive with 10.8.5 and FCP 7 which still works OK.  

  • How can I read a file with ASCII Special Character into a SQL table using SSIS 2008?

    I've tried everything to read this file and am getting no where.   Help how can I read this file and load a SQL table?
    RS - AscII - 30  (Record Separator)
    GS - AscII - 29 (Group Separator)
    Thank you for your assistance - Covi
    Mark Covian

    We can use script component as source/transformation to read the text file and assign the contains to a string. Split the string by chr(30)  i.e RS and finally stored into an array or write to the output buffer of the script component.
    For example on how to use script component refer this link
    http://social.technet.microsoft.com/Forums/en-US/6ff2007d-d246-4107-b77c-624781baab38/how-to-use-substring-in-derived-column-in-ssis?forum=sqlintegrationservices
    Regards, RSingh

Maybe you are looking for

  • Need help installing boot camp onto macbook pro

    I'm attempting to get Boot Camp to run on my MacBook Pro as I need to run several programs on windows for school. I purchased a Windows 8.1 download from Microsoft's website. The download from their website is not an ISO image and is not recognized b

  • Skype number still not working

    I am have been subscribing to a Skype number, but when I call it an automated female voice answers the number despite that I have been trying to reset it by switching Skype privacy settings. When I call from Skype to my phone a caller id number that

  • HT201412 I dropped my phone and the camera shutter will not open- any suggestions? Thank you!!

    I dropped my iPhone and the camera app no longer works.  The shutter will not open, however I am able to take front facing punctures when using the Camera360 app. Any suggestions would really be appreciated!

  • Foxfire is preventing a page from reloading even after I allow it. How do I stop that?

    I'm enrolled in an online business training program called Power Sellers College. In that site, there is a private messaging system that I may use to correspond with my instructor, other instructors, other students etc. This Private Messaging System

  • BI aplication server problem

    Hello all, I've successfully installed both DB 10.2 at linux OpenSuse and BI aplication at a Windows 2000 machine. All is running smoothly since I already start up the DB and access it from 3 different clients, create a user, tables, an EUL, import t