XML Parsing From A String (Not a File)

Hi all,
I've been looking throughout this forum and still can't find a total answer to my question. I was wondering if it is possible to do the following:
I want to pass in a string of XML code to a java stored procedure; the XML string looking like the following (for example):
<Table-Name="PersonalInfo">
<row>
<First-Name>Bob</First-Name>
<Last-Name>Smith</Last-Name>
<Age>55</Age>
</row>
</Table-Name>
We don't want to be passing in an XML file; we want to pass in the actual string of XML code that would be in the file.
Is it possible to put into the DOM format (like every example I've seen so far) by parsing an XML formatted string? If so, how would I go about doing that?
Thanks in advance!
Jadie

<Table-Name="PersonalInfo">
<row>
<First-Name>Bob</First-Name>
<Last-Name>Smith</Last-Name>
<Age>55</Age>
</row>
</Table-Name>This is exactly what JAXB is for! :)
With JAXB unmarshalling against an XSD file can be applied to any InputStream, etc.
Take a look at JAXB, and you'll find it'll be just what you're looking for. :)
In fact, here's a short segment of the XSD you'd write for the above:
<xsd:complexType name="PersonalInfo">
<xsd:sequence>
<xsd:element name="row" type="PersonalInfoRow" minOccurs="0" maxOccurs="unbounded"/>
<xsd:sequence>
</xsd:complexType>
<xsd:complexType name="PersonalInfoRow">
<xsd:sequence>
<xsd:element name="First-Name" type="xsd:string" minOccurs="1" maxOccurs="1"/>
<xsd:element name="Last-Name" type="xsd:string" minOccurs="1" maxOccurs="1"/>
<xsd:element name="Age" type="xsd:int" minOccurs="1" maxOccurs="1"/>
<xsd:sequence>
</xsd:complexType>
Also, perhaps redesign your XML a little, since each table will be different, simply use its name as the tags...i.e. <PersonalInfo></PersonalInfo> and change the <row> to <PersonalInfo> since <row> is pretty generic and will probably occur many times in other places.
Hope this helps you along your way. :)
-G

Similar Messages

  • Create Business Partner from XMl String not a file

    Hi,
    Is it possible to create a BP from an XML string. 
    I know about GetBusinessPartnerFromXml(string FileName, int index)
    but I dont want to save the string in a file before creating a BP from it
    Hope there's a method to do that

    Marc,
    This looks like it is a duplicate of this post, so I am closing this thread as it looks like you answered your own question!
    Create Business Partner from XMl String not a file
    Eddy

  • Parser Error Message: Could not load file or assembly 'Oracle.DataAccess, V

    I'm working on a 64 bit windows 7 ultimate system and I can't get the Oracle.DataAccess and Oracle.Web to load on the helloworld web page
    See error below. At the very end i have the gacutil output. Also, the same dll's work on a 32 bit windows 7 system. I've also tried to load the beta version of the odac 64 bit
    but it it gets a "java stopped working error"
    Thanks in advance
    WEB PAGE ERRORVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV
    Server Error in '/test/helloworld' Application.
    Configuration Error
    Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.
    Parser Error Message: Could not load file or assembly 'Oracle.DataAccess, Version=2.112.1.1, Culture=neutral, PublicKeyToken=89b483f429c47342' or one of its dependencies. The system cannot find the file specified.
    Source Error:
    Line 37:                     <add assembly="System.Xml.Linq, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
    Line 38:                     <add assembly="System.Core, Version=3.5.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
    Line 39:                     <add assembly="Oracle.DataAccess, Version=2.112.1.1, Culture=neutral, PublicKeyToken=89B483F429C47342"/>
    Line 40:                     <add assembly="Oracle.Web, Version=2.112.1.1, Culture=neutral, PublicKeyToken=89B483F429C47342"/></assemblies>
    Line 41:           </compilation>
    Source File: C:\inetpub\wwwroot\test\helloworld\web.config Line: 39
    Assembly Load Trace: The following information can be helpful to determine why the assembly 'Oracle.DataAccess, Version=2.112.1.1, Culture=neutral, PublicKeyToken=89b483f429c47342' could not be loaded.
    === Pre-bind state information ===
    LOG: User = IIS APPPOOL\DefaultAppPool
    LOG: DisplayName = Oracle.DataAccess, Version=2.112.1.1, Culture=neutral, PublicKeyToken=89b483f429c47342
    (Fully-specified)
    LOG: Appbase = file:///C:/inetpub/wwwroot/test/helloworld/
    LOG: Initial PrivatePath = C:\inetpub\wwwroot\test\helloworld\bin
    Calling assembly : (Unknown).
    ===
    LOG: This bind starts in default load context.
    LOG: Using application configuration file: C:\inetpub\wwwroot\test\helloworld\web.config
    LOG: Using host configuration file: C:\Windows\Microsoft.NET\Framework64\v2.0.50727\Aspnet.config
    LOG: Using machine configuration file from C:\Windows\Microsoft.NET\Framework64\v2.0.50727\config\machine.config.
    LOG: Post-policy reference: Oracle.DataAccess, Version=2.112.1.1, Culture=neutral, PublicKeyToken=89b483f429c47342
    LOG: Attempting download of new URL file:///C:/Windows/Microsoft.NET/Framework64/v2.0.50727/Temporary ASP.NET Files/test_helloworld/480589f5/895d06ab/Oracle.DataAccess.DLL.
    LOG: Attempting download of new URL file:///C:/Windows/Microsoft.NET/Framework64/v2.0.50727/Temporary ASP.NET Files/test_helloworld/480589f5/895d06ab/Oracle.DataAccess/Oracle.DataAccess.DLL.
    LOG: Attempting download of new URL file:///C:/inetpub/wwwroot/test/helloworld/bin/Oracle.DataAccess.DLL.
    LOG: Attempting download of new URL file:///C:/inetpub/wwwroot/test/helloworld/bin/Oracle.DataAccess/Oracle.DataAccess.DLL.
    LOG: Attempting download of new URL file:///C:/Windows/Microsoft.NET/Framework64/v2.0.50727/Temporary ASP.NET Files/test_helloworld/480589f5/895d06ab/Oracle.DataAccess.EXE.
    LOG: Attempting download of new URL file:///C:/Windows/Microsoft.NET/Framework64/v2.0.50727/Temporary ASP.NET Files/test_helloworld/480589f5/895d06ab/Oracle.DataAccess/Oracle.DataAccess.EXE.
    LOG: Attempting download of new URL file:///C:/inetpub/wwwroot/test/helloworld/bin/Oracle.DataAccess.EXE.
    LOG: Attempting download of new URL file:///C:/inetpub/wwwroot/test/helloworld/bin/Oracle.DataAccess/Oracle.DataAccess.EXE.
    Version Information: Microsoft .NET Framework Version:2.0.50727.4927; ASP.NET Version:2.0.50727.4927
    gacuil output
    VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV
    C:\Users\Administrator>C:\"Program Files"\"Microsoft SDKs"\Windows\v6.0A\Bin\x64
    \gacutil.exe /l Oracle.DataAccess
    Microsoft (R) .NET Global Assembly Cache Utility. Version 3.5.21022.8
    Copyright (c) Microsoft Corporation. All rights reserved.
    The Global Assembly Cache contains the following assemblies:
    Oracle.DataAccess, Version=2.112.1.1, Culture=neutral, PublicKeyToken=89b483f4
    29c47342, processorArchitecture=x86
    Edited by: burk_s on Jun 6, 2010 2:42 PM

    Hi Mubarak,
    Please firstly make sure you installed SharePoint Foundation 2010 with SP2 in a Windows Server 2012 R2. Since only SP2 slipstream installations are supported on Windows Server 2012 R2
    http://blogs.technet.com/b/stefan_gossner/archive/2014/05/03/sharepoint-2010-sp2-and-windows-server-2012-r2.aspx
    http://blogs.technet.com/b/stefan_gossner/archive/2013/09/19/slipstream-version-of-sharepoint-foundation-2010-with-sp2-included.aspx
    Regards,
    Rebecca Tu
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • How to create an XML document from a String.

    Can anyone help,
         In the Microsoft XML Document DOM there is a load function load(string) which will create an XML document, but now we are switching to Java and I do not know how to create and XML document from a string, this string �xml document� is passed to my program from a webservice and I need to read several xml elements form it in a web server.
    This string is a well formatted XML document:
    <?xml version="1.0" encoding="UTF-8"?>
    <Countries NumberOfRecords="1" LanguageID="en-us">
         <Country>
              <CountryCode>AU</CountryCode>
              <CountryName>AUSTRALIA</CountryName>
         </Country>
    </Countries>

    Thanks PC!
    I made it work using:
    DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
    DocumentBuilder builder = factory.newDocumentBuilder();
    factory.setIgnoringComments(true); // We want to ignore comments
    // Now use the factory to create a DOM parser
    DocumentBuilder parser = factory.newDocumentBuilder();
    //TransformThisStringBuffer is a string buffer wich contain the 'XML document (String)'
    InputStream in = new ByteArrayInputStream(TransformThisStringBuffer.toString().getBytes());
    // Parse the InputStream and build the document
    Document document = parser.parse(in);
    But which one is faster InputSource or InputStream, were would you put the "new InputSource(new StringReader(yourString))" in the above code?

  • Xml parser for pl/sql - not working w/DTD

    I need to parse xml documents from withing pl/sql. Almost all of the returned xml documents from the specific urls contain DTDs which seem to cause the parser to hang! Also, if there is an element with no value I get the Null values not allowed. Please, please someone help!

    LoadJava is giving following error while loading xmlplsql.jar
    resolving : Oracle/xml/parser/plsql/xmlnotationcover :
    ORA-29534: referenced object scott.oracle/xml/parser/plsql/XMLNodeCover could not be resolved.
    I think, it is refereing to a class XMLNotationCover, which should be already installed in database (scott/tiger).
    I am getting above error for several other classes. So there must be some jar file which include these classes.
    pls. send me name of this file and if problem is somewhere else give me soln to it.
    Thanking you.
    Mrinal
    null

  • Parser Error Message: Could not load file or assembly 'DreamweaverCtrls

    Hi,
    After attempting to view my first asp.net page I was greeted
    with the following error:
    Parser Error
    Description: An error occurred during the parsing of a
    resource required to service this request. Please review the
    following specific parse error details and modify your source file
    appropriately.
    Parser Error Message: Could not load file or assembly
    'DreamweaverCtrls, Version=1.0.0.0, Culture=neutral,
    PublicKeyToken=836f606ede05d46a' or one of its dependencies. The
    system cannot find the file specified.
    Source Error:
    Line 1: <%@ Page Language="VB" ContentType="text/html"
    ResponseEncoding="iso-8859-1" %>
    Line 2: <%@ Register TagPrefix="MM"
    Namespace="DreamweaverCtrls"
    Assembly="DreamweaverCtrls,version=1.0.0.0,publicKeyToken=836f606ede05d46a,culture=neutra l"
    %>
    Line 3: <MM:Insert
    Line 4: runat="server"
    Source File: /s4/admin/wiki1/detail.aspx Line: 2
    Assembly Load Trace: The following information can be
    helpful to determine why the assembly 'DreamweaverCtrls,
    Version=1.0.0.0, Culture=neutral, PublicKeyToken=836f606ede05d46a'
    could not be loaded.
    I have deployed the files using dreamweaver and it says "no
    files to deploy". I have a bin folder with the correct .dll in it,
    in the correct root folder. So whats happening??
    Please help
    Cheers
    G

    Are you testing on the server or locally. If the latter is
    true make sure
    that a copy of the controls is in a bin folder at the
    C:\inetpub\wwwroot
    level.
    Paul Whitham
    Certified Dreamweaver MX2004 Professional
    Adobe Community Expert - Dreamweaver
    Valleybiz Internet Design
    www.valleybiz.net
    "graham6117" <[email protected]> wrote in
    message
    news:e2ngbc$sib$[email protected]..
    > Hi,
    >
    > After attempting to view my first asp.net page I was
    greeted with the
    > following error:
    >
    > Parser Error
    > Description: An error occurred during the parsing of a
    resource required
    > to
    > service this request. Please review the following
    specific parse error
    > details
    > and modify your source file appropriately.
    >
    > Parser Error Message: Could not load file or assembly
    'DreamweaverCtrls,
    > Version=1.0.0.0, Culture=neutral,
    PublicKeyToken=836f606ede05d46a' or one
    > of
    > its dependencies. The system cannot find the file
    specified.
    >
    > Source Error:
    >
    >
    > Line 1: <%@ Page Language="VB"
    ContentType="text/html"
    > ResponseEncoding="iso-8859-1" %>
    > Line 2: <%@ Register TagPrefix="MM"
    Namespace="DreamweaverCtrls"
    >
    Assembly="DreamweaverCtrls,version=1.0.0.0,publicKeyToken=836f606ede05d46a,cultu
    > re=neutral" %>
    > Line 3: <MM:Insert
    > Line 4: runat="server"
    >
    >
    > Source File: /s4/admin/wiki1/detail.aspx Line: 2
    >
    > Assembly Load Trace: The following information can be
    helpful to determine
    > why
    > the assembly 'DreamweaverCtrls, Version=1.0.0.0,
    Culture=neutral,
    > PublicKeyToken=836f606ede05d46a' could not be loaded.
    >
    >
    > I have deployed the files using dreamweaver and it says
    "no files to
    > deploy".
    > I have a bin folder with the correct .dll in it, in the
    correct root
    > folder. So
    > whats happening??
    >
    > Please help
    >
    > Cheers
    >
    > G
    >

  • Parser Error Message: Could not load file or assembly 'Microsoft.Office.Access.Server.UI, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c' or one of its dependencies,

    Dear All,
       I have installed Sharepoint Foundation 2010 in my server 2012 R2 machine. and I restore my existing content database backup into new site collections. and I'm trying to browse the site collection in window, the below error shown.. 
    Parser Error
    Message: Could not load file or assembly 'Microsoft.Office.Access.Server.UI, Version=14.0.0.0,
    Culture=neutral, PublicKeyToken=71e9bce111e9429c' or one of its dependencies.
    <add assembly="Microsoft.Office.Access.Server.UI, Version=14.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c" />
     I tried to checked the assembly folder having the DLL or not. but its
    not available in the C:\Windows\assembly location. and I'm tried to resolved this issue by HOTFIX. but unfortunately, I can't find out the patch file for MOSF 2010 in server 2012 r2.
    Please help me on this issue. I'm very new to sharepoint...
    Any help will be more appreciated.
    Thanks,
    Mubarak

    Hi Mubarak,
    Please firstly make sure you installed SharePoint Foundation 2010 with SP2 in a Windows Server 2012 R2. Since only SP2 slipstream installations are supported on Windows Server 2012 R2
    http://blogs.technet.com/b/stefan_gossner/archive/2014/05/03/sharepoint-2010-sp2-and-windows-server-2012-r2.aspx
    http://blogs.technet.com/b/stefan_gossner/archive/2013/09/19/slipstream-version-of-sharepoint-foundation-2010-with-sp2-included.aspx
    Regards,
    Rebecca Tu
    TechNet Community Support
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact
    [email protected]

  • JAXB: Read XML data from a String?

    Hi,
    I get XML data not from file but as a string and I wanted to use JAXB to parse it and get my Java Objects.
    The unmarshall methods wants an "InputStream", but "StringBufferInputStream" is deprecated, so that I don't know a way to use my String as InputStream.
    Can someone give me a hint other then writing the data in a file first?

    Hi FrankSch,
    The unmarshall methods wants an "InputStream", but
    "StringBufferInputStream" is deprecated, so that I
    don't know a way to use my String as InputStream.
    Can someone give me a hint other then writing the data
    in a file first?Yes, the class StringBufferInputStream is deprecated, and the deprecation notice reads:
    Deprecated. This class does not properly convert characters into bytes. As of JDK 1.1, the preferred way to create a stream from a string is via the StringReader class.
    The JDK API usually mentions an alternative to the deprecated method/class and in this case, you should use java.io.StringReader. It has one constructor and should suite you nicely:
    StringReader(String s) That way, you get an InputStream object; you can now use JAXB.
    Hope this helps,
    -ike, .si

  • XML Parsing from Template

    Ok, I'm very new to Oracle, porting from SQL Server. Getting a bit lost.
    I have an XML template similar to :
    <?xml version="1.0"?>
    <xsql:query connection="demo" xmlns:xsql="urn:oracle-xsql" >
    SELECT 'Hello World' AS "GREETING" FROM DUAL
    </xsql:query>
    We have a Windows 2000 based Web server. The problem is that the above select statement is not being converted into a database action and is just displayed in the browser as a string.
    I have read about Servlets and XML Parsers and XML Developers Kits but am not sure what I need. Presumably something installed on our Windows Web Server? Is this correct? We do have Java support installed on the Oracle server.
    Hopefully when I understand what needs installing I will know where to find a file XSQLConfig.xml which will let me configure the database connection to the alias name 'demo'. I will then be ok creating an XSL stylesheet.
    We are using Oracle 8i.
    Thanks for any pointers, help, advice etc.

    This forum is dedicated to Oracle XML DB, which is a feature of Oracle9iR2. Questions related to earlier versions of the database are better posted in the XML forum under the technology heading

  • XML Parsing error - iTunes will not run config.xml missing

    I have a new error code that I cannot find an answer to on any forum. Here is the error message:
    XML Parsing error
    XML Parsing error inside file 'C:\Documents and Settings\lmorrison\Application Data\iTunesControl\config.xml
    Error: First Tag not found
    At line 0, column 0.
    First Tag should be 'itc'.
    This error message pops up when attempting to run iTunes. The only way I've been able to get it to run is to take the library.xml file, rename it as config.xml and paste it into the iTunesControl folder. That's good for one run only. Then I have to copy and paste it again every time I want to run iTunes.
    My issue is... I have no config.xml file. It's gone missing. No idea why. I have uninstalled iTunes and reinstalled. Same error. I wiped every single spec of iTunes off my computer down to removing all instances in the computer registry. Same error. I have installed and uninstalled versions of iTunes back to iTunes 6. Same error. I have wiped and installed from iTunes installation disc. Same error. Help! The only thing I can think of is to locate someone with a working iTunes and copy their config.xml file to my computer. Apple was no help at all and merely suggested installing the latest version of iTunes... yeah... thanx.
    Any ideas are appreciated.

    I don't even have this iTunesControl folder!
    C:\Documents and Settings\ username \Application Data\ iTunesControl
    Did you ever install this itunesControl program? Maybe that's why you have that folder and I don't. I just googled on iTunesControl.
    http://itunescontrol.com/
    edit - the only thing Apple installs is here:
    C:\Documents and Settings\ username \Application Data\Apple Computer
    Message was edited by: Katrina S.

  • Dreamweaver CS5 fatal error XML parsing: Invalid document structure, line:1, File: C:\User\Tyler\App

    XML parsing fatal error: Invalid document structure, line: 1, file: C:\User\Tyler\AppData\Roaming\Adobe\Dreamweaver CS5\en_US\Configureation\Workspace\Classic.xml
    I have gone through older disscussion forums and have followed the steps recommended by deleting the corrupted .xml file itself (in this case "Classic.xml") but imidiatly after when i try to open Dreamweaver again, i am prompted with the same fatal error message including the file that i have just deleted. Next i deleted the entire configure file and this did not help either.
    It is also odd that when i follow the path to find the corrupted .xml file from the prompt, the path is different in that i do not find the "Classic.xml" file through th "en_US\Configuration\Weorkspace" navigation, however i do find the corrupt "Classic.xml" file in the "configure" folder of the "Adobe Dreamweaver CS5" file.
    Im not sure what to do now and i would really like Dreamweaver back up and running so please help if you can!!!
    Thanks
    -Tyler

    Step 1: Close DW, Navigate to C:\User\Tyler\AppData\Roaming\Adobe\Dreamweaver CS5\en_US\Configureation\Workspace\ and delete that Classic.xml file
    Re-open DW. DW should auto-create your Workspace layout XML file again. See if it works fine.
    PROCEED TO STEP 2 ONLY IF STEP 1 DOESN'T SOLVE THE ISSUE
    Step 2: Navigate to C:\Users\Tyler\AppData\Roaming\Adobe\Dreamweaver CS5\en-US\Configuration and delete the entire 'CONFIGURATION' folder. Re-open DW. DW should auto-create your configuration folder based on predefined layouts and config options. This will definitely fix your issue.
    Reason for this issue: This issue would have been caused due to a malformed workspace layout configuration. That may happen due to customizations you may have done to the layout/ improper file permissions/ improper shutdown on Windows.
    See if these fixes resolve your issue and post your results here.
    Cheers,
    ST

  • Remove xml parser from the database

    I am deinstalling a version of xml and putting a newer version of
    it. how do i do that? I know that there is something like
    dropjava , but still there are other packages which are loaded
    into the schema. I want to clean out the earlier version and
    install the new version in a clean manner.
    Thanks
    nidhi
    null

    you'll need to write SQL to write SQL
    based on the USER_OBJECTS table
    where:
    SELECT 'drop java class '''&#0124; &#0124;
    dbms_java.longname(object_name)&#0124; &#0124;''';'
    from user_objects where
    OBJECT_TYPE = 'JAVA CLASS'
    and DBMS_JAVA.LONGNAME(OBJECT_NAME)
    LIKE 'oracle/xml/parser/%'
    This will spew out a set of DROP JAVA CLASS
    command which you can capture in a file
    using SQL*Plus':
    SPOOL somefilename
    command. Then run that spool file as a
    SQL script and all the right classes
    will be dropped.

  • Parsing from a string of XML?

    Hi there,
    I'm using DOM to parse some XML. However, the XML is not in a file, it's in a String. So the DocumentBuilder's parse(...) method takes an InputStream or File object but I'm looking to parse a String. Can anybody help me??
    Cheers,
    Sean

    Ok I found out a way to parse an XML string:
    DocumentBuilder builder = factory.newDocumentBuilder();
    StringReader sr = new StringReader(xmlString.toString());
    InputSource is = new InputSource(sr);
    document = builder.parse(is);
    But I'm getting the following error on the parse() line:
    [Fatal Error] :1:20: A pseudo attribute name is expected.
    org.xml.sax.SAXParseException: A pseudo attribute name is expected.
         at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
         at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
         at test.TestDOM.main(TestDOM.java:61)
    The XML string is:
    String xmlString = "<?xml version=\"1.0\"><tag><tag_id>250397</tag_id><reader_id>1</reader_id><rssi>74</rssi><date>7/19/2006</date><time>2:59:47 PM</time></tag>";
    Can anybody help?
    Cheers,
    Sean

  • I'm looking simple way XML-View from a string?

    Hi,
    there is a nice facility to show a XML-Tree in the Microsoft Internet-Explorer from a XML-file on the PC.
    Is there a simple way like this in ABAP?
    My mission is to read a XML-String from a table and to show the XML-Tree in the SAPGUI.
    I found the method CL_XML_DOCUMENT->DISPLAY, but I'm not sure how to export the XML-String to this class/object.
    Best and regards,
    Stefan

    hi,
    you can use
    call method CL_XML_DOCUMENT->display.
    data : l_string type string.
    data :lo_mxml type ref to cl_xml_document,
          m_document  type ref to if_ixml_document,
          l_dom       type ref to if_ixml_element,
          l_ele       type ref to if_ixml_element,
          l_ele1      type ref to if_ixml_element,
          m_doctype   type ref to if_ixml_document_type,
          g_ixml      type ref to if_ixml,
          l_text      type ref to if_ixml_text,
          ls_srctab1  type xstring,
          l_retcode type sysubrc.    "#EC *.
    create object lo_mxml.
    move 'cxml SYSTEM "http://b2b.xxxxx.com/"' to l_string.
    class cl_ixml definition load.
    g_ixml = cl_ixml=>create( ).
    m_document = g_ixml->create_document( ).
      call method m_document->create_document_type
        exporting
           name   = 'cXML'
        receiving
          rval   = m_doctype.
    call method m_document->set_document_type
        exporting
          document_type = m_doctype.
      l_dom = m_document->create_element( name = 'cXML' ).
      l_retcode = m_document->append_child( l_dom ).
      move gw_respond-payload_id to l_string.
    *____setting attribute payload id for cxml tag
      call method l_dom->set_attribute
        exporting
          name    = 'payloadID'
          value   = l_string
         NODE    = LO_NODE
        receiving
          rval = l_retcode.
    call method lo_mxml->display.
    cheers,
    sasi

  • Updating equation in formula node from a string or text file

    Is it possible to have a calculation performed based on an equation stored in a string (read from a text file). I am guessing not because the equation would need be compiled but thought I would ask.

    Hi,
    it depends on how complex the equation is.
    Rather than using a formula node, you could use the eval formula node vi instead. (Functions->Analyze->Mathematics->Formula), but you may needs to re-organise the text formula a little.
    Assuming you're using not the base package, and atleast LabVIEW version 6.1 that shouldn't be a problem.
    Hope that helps.
    Sacha Emery
    National Instruments (UK)
    // it takes almost no time to rate an answer

Maybe you are looking for