Xstring to string for ms_excel

Hi ALL,
I am using OFFICE CONTROL UI ELEMENT for displaying iternal table data into EXCEL  OFFICE CONTROL UI .
i am displaying data into OFFICE CONTROL UI EXCEL, then i will update excel of office control and then i will save,when i save that updated data need to send one internal table .
DATA :OUT_STRING1 TYPE STRING,
      CONTENTXMLSOURCE TYPE XSTRING.
WD_CONTEXT->GET_ATTRIBUTE( EXPORTING NAME = 'DATAS' IMPORTING VALUE = CONTENTXMLSOURCE ).
CALL FUNCTION 'HR_KR_XSTRING_TO_STRING'
  EXPORTING
  FROM_CODEPAGE       = '8500'
    IN_XSTRING          = CONTENTXMLSOURCE
  OUT_LEN             =
IMPORTING
   OUT_STRING          = OUT_STRING1.
data lr_conv       type ref to cl_abap_conv_in_ce.
lr_conv = cl_abap_conv_in_ce=>create( ).
lr_conv->convert( exporting input = xstring importing data = string ).
NOT FOR LIKE Excel file (like Tab Delimited, CVS, XML, etc). Only for ms_excel.
the above mention two concepts are not working to convert from xstring to string ,is there any concept ms_excel format xstring to string?
THANKS,
RAMA
Edited by: Ramakullay Challa on Sep 25, 2009 2:03 PM
Edited by: Ramakullay Challa on Sep 25, 2009 2:06 PM

Hi Lekha,
When i am activating one  method , insede this method i am calling one c lass.
data: DATASOURCE type ref to CL_WD_OFFICE_CONTROL,
   content type xstring.
TRY.
      DATASOURCE = cl_wd_office_control=>GET_DATA_SOURCE( VALUE = CONTENT ).
CATCH CX_WD_ACF_EXCEPTION.
ENDTRY.
error .any idea lekha.
*you can use only use "class=>method" with static methos.*
data: DATASOURCE type ref to CL_WD_OFFICE_CONTROL,
   content type xstring.
CONTENT  = DATASOURCE->GET_DATA_SOURCE( ).
no error.
thanks.
thanks,
rama
Edited by: Ramakullay Challa on Sep 28, 2009 7:08 AM
Edited by: Ramakullay Challa on Sep 28, 2009 7:09 AM
Edited by: Ramakullay Challa on Sep 28, 2009 11:26 AM

Similar Messages

  • Convert XString to String and String to IWDResource

    Hi everybody,
    we want to open a PDF-Document from Backend in Web Dynpro. For the communication we use a Web Service.
    In Backend we have a PDF-Document with data type XSTRING.
    1. In Backend we convert the PDF-Document from XSTRING to STRING in order to send it via Web Service
    2. Then we call the Web Service and pass by the STRING param
    3. In Web Dynpro we convert the value from STRING to Bytes, like below:
    IWDResource resource = WDResourceFactory.createResource( myPDFStringFromWS.getBytes(), "Doc1", WDWebResourceType.PDF);
    4. We bind the Resource to a FileDownload-UI.
    Unfortunately we get the error message: Document is not a valid PDF
    How can we convert a String to IWDResource? Could the problem be in our first step, where we convert the XSTRING into STRING?
    regards,
    Sid

    Hello Sid,
    IWDResource resource = WDResourceFactory.createCachedResource(new ByteArrayInputStream(wdContext.currentFileElement().getString()),"PDF",WDWebResourceType.PDF,true);
    IWDWindow window = wdComponentAPI.getWindowManager().createNonModalExternalWindow(resource.toString(),"PDF");
    window.show();
    Can you try this and let us know.
    Regards
    Nizamudeen SM

  • Messy code problem while translating XString to String in OfficeControl

    Hi Expert,
        I have messy code problem while translating XString to String in XML-Format Word Doc in OfficeControl.
    I upload an XML-Format template Word Doc to server as a MIME Object.
    When OfficeControl is started in Web Dynpro, OfficeControl automatically open the XML-Format template.
    For the first time, I get the XString-type Context attribute bind to the content of the Word Doc,
    then translate it to string, I got the XML-format content, it's great!
    However, after the first time, when I input any new contents in MS Word in Web Dynpro,
    no matter I execute "Ctrl + S" or click the "savedocument" button,
    when I translate the XString Context attribute to String, I got messy code. (but the first time, it is good plain text)
    I use the function module: ECATT_CONV_XSTRING_TO_STRING (good for first time, dump after first time),
    SCMS_XSTRING_TO_BINARY, SCMS_BINARY_TO_STRING (good for first time, messy code after first time).
    My Demo source code is in: (system) SMV --> (local object) zhaode --> (Dynpro Component) ztest_office_control
    core source code is as:
    clear itab.
    CALL FUNCTION 'SCMS_XSTRING_TO_BINARY'
    EXPORTING
    BUFFER = lv_datas
    IMPORTING
    OUTPUT_LENGTH = lv_length
    TABLES
    binary_tab = itab.
    CALL FUNCTION 'SCMS_BINARY_TO_STRING'
    EXPORTING
    input_length = lv_length
    mimetype = 'text/plain; charset=utf-8'
    IMPORTING
    text_buffer = lv_datas_string
    output_length = lv_data_len
    TABLES
    binary_tab = itab.
    Can you give me some advice?
    Many thanks in advance.
    Best Regards,

    You have already posted this same question several times (and some very similiar questions) within the forum.  Please do NOT multiple post your questions. This is against the forum rules of engagement. SAP employee or not, you will find yourself banned from the forums if you don't follow the rules.

  • [svn:bz-trunk] 11030: Tweak the deserialization of ASObjects to treat an empty string for the type of an object as null .

    Revision: 11030
    Author:   [email protected]
    Date:     2009-10-20 11:35:02 -0700 (Tue, 20 Oct 2009)
    Log Message:
    Tweak the deserialization of ASObjects to treat an empty string for the type of an object as null. It appears that there is some logic in the LC remoting code that relies on a non-null class name to always exist. This change reverts to the old behavior of not allowing empty string as a value for the ASObject.namedType.
    This should fix bug 2448442 and its duplicates caused by the recent serialization changes.
    I don't think this is the perfect fix. Pending further investigation, a better fix would be either:
    a. If it's OK to assume that empty string should always mean null for the type of the ASObject, the code that enforces it should be in the setter/getter inside ASObject and not in the deserializer.
    b. ASObject doesn't guarantee that a named type exists or is valid. In that sense an empty string is as bad as some random characters that cannot be a valid class name in java, so depending on how disruptive it may be, the fix should be in any logic that uses ASObject.getType().
    Modified Paths:
        blazeds/trunk/modules/core/src/flex/messaging/io/amf/AbstractAmfInput.java

    Hi Pavan,
    "In your payload there is no namespace prefix for the elements under PayloadHeader element."
    Yes, you are right - but this message is standard AQ Adapter Header message - it's not defined by me. I just used message which was automatically added to my project when I have defined AQ Adapter.
    "In your process is the default namespace is same as namespace value of tns ??"
    Do you mean targetNamespace? If yes it's different as it points to process "targetNamespace="http://xmlns.oracle.com/PF_SOA_jws/PF_APPS/APPS_PROCESS" (names of application and process have changed as I try different ways to do that)
    ns1 is: xmlns:ns1="http://xmlns.oracle.com/pcbpel/adapter/aq/PF_SOA/PF_APPS/PO_AQ"
    "another thing is tns and ns1 should have same values.."
    When I create a variable of header type, namespace ns1 is automatically created for it. I set it as property of receive activity. When process is instantiated on the serwer I get the error in which you can see that namespace is tns.
    Maybe I'm doing something wrong but I don't see how I could fix this in my process.
    You can see that the message I get on the server has nothing in common with the application/project/process names. Is it possible to define such variable?
    Regards
    Pawel
    PS:
    In Transformation xsl file, both variables (source and target) has tns namespace for Header and PayloadHeader, and no namespace for subfields.
    Edited by: pawel.fidelus on 2010-01-05 02:37

  • How to dynamically set connection string for report in C# code?

    Hi,
    I have installed CRVS2010. I have created new Crystal Report WPF Application and new report. I would like to set connection string for report in code dynamically.
    Is this possible?
    Thanks
    Ivana

    Lots of posts in this forum on how to set database connections. WPF should not be a consideration as it's just a viewer. The report engine is still the same. Search these forums. Use the search box at the top right corner of this page. Look at samples here:
    https://wiki.sdn.sap.com/wiki/display/BOBJ/CrystalReportsfor.NETSDK+Samples
    Note that none of the samples above are using WPF, but like I said, the WPF is just a different viewer and will not impact how the report engine logs on to a database. (I think of it as a gray car vs. a red car. Same engine, just the color is different)
    Ludek
    Follow us on Twitter http://twitter.com/SAPCRNetSup
    Got Enhancement ideas? Try the [SAP Idea Place|https://ideas.sap.com/community/products_and_solutions/crystalreports]

  • How to use multiple VCI strings for lap 1300 and 1200 (option 60) in one pool?

    Hi All,
    Hope to you a very happy new year,
    I have two differnt LAP 1300 and 1200 in my network and I need to add theme to the WLC,
    I successed to add one of theme by the option 60 in the DHCP pool at the Core SW,
    So my quetion is below:
    How to use multiple VCI strings for lap 1300 and 1200 (option 60) in one pool?
    Thanks in Advanced,
    Ahmed,

    To add to Scott's post.  Option 60 would be useful if you needed to put certain types of AP on specific controllers.  Otherwise, no real need to use it for the most part.
    Though, I do recall an issue a few years ago that some windows machines had issues getting DHCP if option 43 is being returned.
    Now, on an IOS switch, you can only configure one option 60 per DHCP scope
    HTH,
    Steve
    Please remember to rate useful posts, and mark questions as answered

  • Convert xstring to string

    Hi All,
    I need to convert the XSTRING to STRING and i need a FM or method which converts all the special characters like Å, ö, ä, å, ü as it is.
    Im getting the xstring value from excel sheet using file upload in WEB UI.
    The class used is CL_HTMLB_FILEUPLOAD and the attribute is FILE_CONTENT which is of type XSTRING.
    I have few special characters in the excel sheet which i need as string.
    I have modified this FM CRM_IC_XML_XSTRING2STRING to convert the Xstrin gto string... but stilll the replacement is not working.
    Can anyone suggest me...Any different solution i can use to get the file upload in string. Or get the characters from Xstring
    Useful answers are much apprieciated.
    Thanx in advance
    Siva.

    Hey,
    Why dont you check this method
    ECATT_CONV_STRING_TO_XSTRING. Not sure whether it supports special characters or not
    Regards,
    Vinay

  • Need a function module to convert xstring to string in web dynpro applicati

    hi,
       need a function module to convert xstring to string in web dynpro application other than HR_KR_XSTRING_TO_STRING.
    Moderator message: please (re)search yourself first.
    Edited by: Thomas Zloch on Nov 17, 2010 5:31 PM

    Hi,
    Check the following link:
    FM to convert XString to String
    Regards,
    Bhaskar

  • Creation of input string for SHA-1 in hash total calculation

    In order to create an input string for the SHA-1 algorithm based on the REGUH table I am searching for the ABAP source code which can be used in the user exit of transaction of transaction F110 (Payment Run).
    Can anybody provide me the source code or is there a BAPI or something ?
    Please help. The problem is urgent and my ABAP engineer did not succeed so far developing the solution.
    Best regards, Edwin

    And this will get a base64 encoded hash
    select utl_raw.cast_to_varchar2( utl_encode.base64_encode( dbms_crypto.hash(utl_raw.cast_to_raw('mypass'),3) ) )
    from dual;

  • Conversion of XSTRING to String is incomplete

    Hi ,
    I am trying to conver a Xstring to String. But the output string after conversion is incomplete.
    Here is the code snippet-
    CALL METHOD CL_ABAP_CONV_IN_CE=>CREATE
          EXPORTING
            INPUT       = l_xstring
            ENCODING    = 'UTF-8'
            REPLACEMENT = '?'
            IGNORE_CERR = ABAP_TRUE
          RECEIVING
            CONV        = loc_CONV.
            length = xstrlen( l_xstring ).
            CALL METHOD loc_CONV->READ
            EXPORTING
            N = length
            IMPORTING
                DATA = loc_string
                LEN = length.
    Can anyone please help?
    Best Regards,
    Lata

    Hi,
    http://www.sapfans.com/forums/viewtopic.php?p=403405&sid=e524cddae19e7ae48a12477e68c6032d
    Regards,
    Sravanthi

  • [svn] 3519: Fix typo in error string for situations where there are advanced messaging configuration settings from LCDS used in the configuration files but no AdvancedMessagingSupport service .

    Revision: 3519
    Author: [email protected]
    Date: 2008-10-08 04:17:40 -0700 (Wed, 08 Oct 2008)
    Log Message:
    Fix typo in error string for situations where there are advanced messaging configuration settings from LCDS used in the configuration files but no AdvancedMessagingSupport service. The error string said that there was no flex.messaging.services.AdvancedMessagingService registered but it is the flex.messaging.services.AdvancedMessagingSupport service that needs to be registered.
    Add configuration test that starts the server with a destination that has the reliable property set which is an advanced messaging feature but there is no AdvancedMessagingSupport service registered.
    Modified Paths:
    blazeds/trunk/modules/common/src/flex/messaging/errors.properties
    Added Paths:
    blazeds/trunk/qa/apps/qa-regress/testsuites/config/tests/messagingService/ReliableDestina tionWithNoAdvancedMessagingSupport/
    blazeds/trunk/qa/apps/qa-regress/testsuites/config/tests/messagingService/ReliableDestina tionWithNoAdvancedMessagingSupport/error.txt
    blazeds/trunk/qa/apps/qa-regress/testsuites/config/tests/messagingService/ReliableDestina tionWithNoAdvancedMessagingSupport/services-config.xml

    Hi,
    Unfortunately I already tried all kinds of re-installs (the full list is in my original message). The only one remaining is the reinstall of Windows 8 itself, which I would really like to avoid.
    What I find really strange is the time it takes for the above error message to appear. It's like one hour or even more (never measured exactly, I left the computer running).
    What kind of a timeout is that? I would expect that, if ports are really used by some other application, I get the message in less than a minute (seconds, actually). To me this looks like the emulator itself for some reason believes there's a problem with
    some port while in reality there isn't.
    I'll eventually contact Microsoft Support, thanks for the suggestion.

  • Define Search String for EBS in SAP 4.6c

    Hi All,
    I have some question for search string for EBS in SAP 4.6c. I have already done this thing in ECC 6 and work well with "target field" as account number. but in 4.6c target field account number doesn't exist. Please suggest me, if there is a same way like account number target field in 4.6c?
    Thanks in advance
    Glenn

    Hi Shanumonu,
    Thx for the answer, you save my life!
    But I have another issued. I already implement SE11 instruction, but item with wrong note to payee number from MT940 keep cleared. Do you have suggestion for me?
    Thanks,
    Glenn

  • Show Error string for all the components in a form at a time

    How do I show all the error strings for all the components in the form when the submit button is clicked?

    This code answers your question:
    <?xml version="1.0"?>
    <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">
      <mx:Script>
        <![CDATA[
          import mx.events.ValidationResultEvent;
          import mx.validators.ZipCodeValidator;
          import flash.events.MouseEvent;
          public var v:ZipCodeValidator = new ZipCodeValidator();
          public var vResult:ValidationResultEvent;
          public function performValidation():void {
            v.domain = "US or Canada";
            v.listener=myZip;
            vResult = v.validate(myZip.text);
            if (vResult.type==ValidationResultEvent.INVALID) {
              myZip.dispatchEvent(new MouseEvent(MouseEvent.MOUSE_OUT));            
              myZip.dispatchEvent(new MouseEvent(MouseEvent.MOUSE_OVER));
        ]]>
      </mx:Script>
      <mx:TextInput id="myZip"/>
      <mx:Button label="Submit" click="performValidation();"/>
    </mx:Application>
    If this post answers your question or helps, please mark it as such. Thanks!
    http://www.stardustsystems.com
    http://www.stardustsystems.com/blog
    Adobe Flex Development and Support Services

  • Save Query - An error occurred while creating connection strings for the query

    A workbook trying to edit and reload I get the following error "Save Query - An error occurred while creating connection strings for the query" No Power Pivot data model or anything.

    I am getting the same error when editing a Power Query in an Excel spreadsheet. It happens when I change a Group By step to do a Sum instead of Count Rows.

  • VISA and Scan string for tokens

    Hi there,
    I am currently developing a piece of software which needs to take in data from an Arduino board via the serial port and parse the input accordingly.
    I have the 2 pieces of code working perfectly well separately, but I can not seem to figure out why they are not functioning properly together.
    Just now, the input is being retrieved fine and passed into the Scan string for tokens method, but it is not being split on the tokens, it is just outputting the string as a whole.
    The input is in the form of 1:0 2:0 3:1 etc. so I am trying to split it on any spaces found.  If I attach a string to the Scan strings for tokens it works fine, just not when I am attaching the data from the serial port to it.
    Any help would be appreciated.
    Attachments:
    input manipulation.vi ‏16 KB

    Hi,
    In the output which you are getting from the serial port, is there space between 1:0 and 2:0 and 3:1? If there is no space between them, then it wont be able to scan for tokens and will output the whole string. I don't have the hardware here and so don't know what exactly is the output which you are receiving. Try to see in the read buffer indicator whether the tokens are seperated by a space or not.
    I have attached your vi after adding a small part in it. If the problem is with the spacing then this will work fine for 1:0 2:0 3:1.
    Regards,
    Nitzz
    (Give kudos to good Answers , Mark it as a Solution if your problem is Solved) 
    Attachments:
    input manipulation.vi ‏18 KB

Maybe you are looking for

  • Should I purchase a Macbook Pro 15" Retina Display?

    Yeah so I've been saving up all my money from work (or w/e I have left) into buying myself a Macbook Pro Retina for video editing and graphics design but now I'm reading about this whole Image Retention/Ghosting issue. I'm just not sure if it's worth

  • How to reinstall itunes on Yosemite

    Hello, My MacBook Pro runs Yosemite 10.10.1 My current iTunes version is 12.0.0.140 iTunes installation is by default, I made no particular changes to it. My App Store application is 2.0 (376.0.5) and tells me there is a iTunes 12.0.1 upgrade availab

  • CD burns but won't read???

    hello, I have tried inserting numerous cd's into emac drawer in which only some will be read. the tray has no problem ejecting. The cd's that won't read, once inserted, make a double sounding "buzz" sound or "brr-brr" noise- not the usual spinning "w

  • SQL Developer 2.1.1 seems to be working good

    Just installed it and started testing. Looks like we can EXPORT data from SQL Server tables again. Also, appears we can see synonyms from OTHER USERS. This is a good thing.

  • Change the User ID running the SunOne Directory Server 6.3 on Windows 2003

    Hi Experts, I have an install of SunOne Directory Server Enterprise edition 6.3 running on Windows 2003 server. It was installed using the Zip distribution and is running as a user ID in the Active Directory the server is part of. We are trying to ch