Example Servlet XML loader?

I was wondering if anyone might have a good example of a servlet based XML loader routine. I have to write a load routine that will take a XML file, read it into a DOM and then navigate throught doing various validations before putting the info (via jdbc) into a back end database.
I'd like an interface where I can specify the file, have it indicate the progress, pick validations options, etc. via a screen interface. It will also have to be flexible enough to specify those same interface parameters via a config file also.
Anyway, just wondering if someone has already done something similiar that I could use as a starting point?
Thanks,
Dave

I am using servlet to read an XML from the request object. My client who developing the jsp pages are embeded the xml as a String in a form. I'll have to get the String value then generate a Document object to pass to use it.
I am in the stage of concept proof that I should be able to use HTTPTunneling to write an XML object direct to the outputstream, then read the inputstream to cast it back.
What kinda routine are you using? I would like to know if there is any easier ways, thanks!
Kevin

Similar Messages

  • Servlets & XML-RPC Example

    Since I am not having any luck on the Java & XML forum (http://forum.java.sun.com/thread.jsp?forum=34&thread=512728&tstart=0&trange=15)
    I thought I would try here. Does anyone know of a good example on the web they can point me to that shows XML-RPC with servlets as I cannot find any and the examples dir from the Apache distribution of XML-RPC (which is supposed to have such an example) is MIA. Thanks.

    hello,
    I am looking for the same servlet xml-rpc example, Have you found it ?
    nojkan

  • XML Load Document in EXE does not run

    LV 8.0 (or 8.01).
    This has got to be a trivial installation problem. I wrote a simple VI that reads in an XML file using the XML Load Document vi. It runs like a charm. I then built an exe. Loading the exe results in the following set of errors:
    Unable to Locate Component
    This application has failed to start because xerces-c_2_2_0.dll was not found. Re-installing the application may fix this problem.
    This is then followed by:
    LabVIEW: Resource File not found
    The file 'DOMUserDefRef.dll' is not a valid LabVIEW file
    As it turns out, I just received my 8.01 CDs, so why not? I installed the upgrade, repaired the internet toolkit, sprinkled some distilled water on my keyboard, but the problem did not go away. I then un-installed ALL of LabView, re-installed 8.00, did the hokey pokey, problem is still there.
    Am I missing some vital step? If so, I would love to find out where this is documented.
    I've reduced the problem to just having the XML Load Document vi connected to the Close Reference VI. See the attached VI.
    Thanks,
    fredb.
    Attachments:
    XMLBug.vi ‏13 KB

    Hi Casey;
    The XML Load Document is part of the XML ToolKit - that comes with the Internet Toolkit from NI. I'm not sure how I can post NI's toolkits here. They are available in the Toolkit CD (part of the Professional Suite). (I tried to get a screen shot in here - can't even do that!).
    I'll attach a sample XML Doc I've created. It is created by parsing the LVPROJ file in order to find all the dynamic VI's. I'll build one based on a very simple demo project and attach it here. I was able to parse most of it by using the get tag method, but when I went to use the get value - that would always return a blank string - so I gave up, found an example using the internet toolkit - and off I went.
    I do have a workaround (not too elegant) - I create a simple text file each time I write the XML file. I then read the txt file from within the EXE.
    Thanks for looking into this. I did get a pointer from my excellent field engineer (Lesley Yu) who suggested I take a look at...
    http://digital.ni.com/public.nsf/websearch/694A29D​C644542BC86256E29007CCAC1?OpenDocument
    This recommends I explicitly register the dll. I have not had a chance to try this. I did completely uninstall LV and re-install it. That wasn't it.
    Thanks again,
    fredb.
    Attachments:
    Demo.zip ‏1 KB

  • Question about servlet.xml setting

    <?xml version="1.0" encoding="UTF-8"?>
    <!-- Example Server Configuration File -->
    <Server port="8025" shutdown="TEARSDOWN">
    <!-- Comment these entries out to disable JMX MBeans support used for the
    administration web application -->
    <Listener className="org.apache.catalina.core.AprLifecycleListener"/>
    <Listener className="org.apache.catalina.mbeans.ServerLifecycleListener"/>
    <Listener className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener"/>
    <Listener className="org.apache.catalina.storeconfig.StoreConfigLifecycleListener"/>
    <!-- Global JNDI resources -->
    <GlobalNamingResources>
    <!-- Test entry for demonstration purposes -->
    <Environment name="simpleValue" type="java.lang.Integer" value="30"/>
    <!-- Editable user database that can also be used by
    UserDatabaseRealm to authenticate users -->
    <Resource auth="Container" description="User database that can be updated and saved" factory="org.apache.catalina.users.MemoryUserDatabaseFactory" name="UserDatabase" pathname="conf/tomcat-users.xml" type="org.apache.catalina.UserDatabase"/>
    <Resource name="jdbc/mp" auth="Container"
    type="javax.sql.DataSource" driverClassName="oracle.jdbc.driver.OracleDriver"
    url="jdbc:oracle:thin:@172.25.43.224:1521:mp"
    username="mpuser" password="mp" maxActive="20" maxIdle="10"
    maxWait="-1"/>
    <Resource name="jdbc/passport" auth="Container"
    type="javax.sql.DataSource" driverClassName="com.mysql.jdbc.Driver"
    url="jdbc:mysql://218.1.14.134:3306/xmnext_passport?autoReconnect=true"
    username="zhouzhijun" password="zhouzhijun*1234567" maxActive="20" maxIdle="10"
    maxWait="-1"/>
    </GlobalNamingResources>
    <!-- Define the Tomcat Stand-Alone Service -->
    <Service name="Catalina">
    <!-- Define a non-SSL HTTP/1.1 Connector on port 8080 -->
    <Connector URIEncoding="utf-8" acceptCount="100" connectionTimeout="20000" disableUploadTimeout="true" enableLookups="false" maxHttpHeaderSize="8192" maxSpareThreads="75" maxThreads="150" minSpareThreads="25" port="8084" redirectPort="8443"/>
    <!-- Define an AJP 1.3 Connector on port 8009 -->
    <Connector enableLookups="false" port="8009" protocol="AJP/1.3" redirectPort="8443"/>
    <!-- Define the top level container in our container hierarchy -->
    <Engine defaultHost="localhost" name="Catalina">
    <Realm className="org.apache.catalina.realm.UserDatabaseRealm" resourceName="UserDatabase" />
    <!-- a Realm is setUp for JOSSO -->
    <Realm className="org.josso.tc55.agent.jaas.CatalinaJAASRealm"
    appName="app1"
    userClassNames="org.josso.gateway.identity.service.BaseUserImpl"
    roleClassNames="org.josso.gateway.identity.service.BaseRoleImpl"
    debug="1" /> // I am not sure realm can set twice like this?
    <Host appBase="webapps" autoDeploy="false" name="localhost" unpackWARs="true" xmlNamespaceAware="false" xmlValidation="false">
    <!-- a Valve for JOSSO -->
    <Valve className="org.josso.tc55.agent.SSOAgentValve" debug="9" /> when I set this valve, the tomcat seems running abnormal...
    </Host>
    </Engine>
    </Service>
    </Server>
    Could you help me to check this file setting? Just check this "servlet.xml". Thank you very much!

    <?xml version="1.0" encoding="UTF-8"?>
    <!-- Example Server Configuration File -->
    <Server port="8025" shutdown="TEARSDOWN">
    <!-- Comment these entries out to disable JMX MBeans support used for the
    administration web application -->
    <Listener className="org.apache.catalina.core.AprLifecycleListener"/>
    <Listener className="org.apache.catalina.mbeans.ServerLifecycleListener"/>
    <Listener className="org.apache.catalina.mbeans.GlobalResourcesLifecycleListener"/>
    <Listener className="org.apache.catalina.storeconfig.StoreConfigLifecycleListener"/>
    <!-- Global JNDI resources -->
    <GlobalNamingResources>
    <!-- Test entry for demonstration purposes -->
    <Environment name="simpleValue" type="java.lang.Integer" value="30"/>
    <!-- Editable user database that can also be used by
    UserDatabaseRealm to authenticate users -->
    <Resource auth="Container" description="User database that can be updated and saved" factory="org.apache.catalina.users.MemoryUserDatabaseFactory" name="UserDatabase" pathname="conf/tomcat-users.xml" type="org.apache.catalina.UserDatabase"/>
    <Resource name="jdbc/mp" auth="Container"
    type="javax.sql.DataSource" driverClassName="oracle.jdbc.driver.OracleDriver"
    url="jdbc:oracle:thin:@172.25.43.224:1521:mp"
    username="mpuser" password="mp" maxActive="20" maxIdle="10"
    maxWait="-1"/>
    <Resource name="jdbc/passport" auth="Container"
    type="javax.sql.DataSource" driverClassName="com.mysql.jdbc.Driver"
    url="jdbc:mysql://218.1.14.134:3306/xmnext_passport?autoReconnect=true"
    username="zhouzhijun" password="zhouzhijun*1234567" maxActive="20" maxIdle="10"
    maxWait="-1"/>
    </GlobalNamingResources>
    <!-- Define the Tomcat Stand-Alone Service -->
    <Service name="Catalina">
    <!-- Define a non-SSL HTTP/1.1 Connector on port 8080 -->
    <Connector URIEncoding="utf-8" acceptCount="100" connectionTimeout="20000" disableUploadTimeout="true" enableLookups="false" maxHttpHeaderSize="8192" maxSpareThreads="75" maxThreads="150" minSpareThreads="25" port="8084" redirectPort="8443"/>
    <!-- Define an AJP 1.3 Connector on port 8009 -->
    <Connector enableLookups="false" port="8009" protocol="AJP/1.3" redirectPort="8443"/>
    <!-- Define the top level container in our container hierarchy -->
    <Engine defaultHost="localhost" name="Catalina">
    <Realm className="org.apache.catalina.realm.UserDatabaseRealm" resourceName="UserDatabase" />
    <!-- a Realm is setUp for JOSSO -->
    <Realm className="org.josso.tc55.agent.jaas.CatalinaJAASRealm"
    appName="app1"
    userClassNames="org.josso.gateway.identity.service.BaseUserImpl"
    roleClassNames="org.josso.gateway.identity.service.BaseRoleImpl"
    debug="1" /> // I am not sure realm can set twice like this?
    <Host appBase="webapps" autoDeploy="false" name="localhost" unpackWARs="true" xmlNamespaceAware="false" xmlValidation="false">
    <!-- a Valve for JOSSO -->
    <Valve className="org.josso.tc55.agent.SSOAgentValve" debug="9" /> when I set this valve, the tomcat seems running abnormal...
    </Host>
    </Engine>
    </Service>
    </Server>
    Could you help me to check this file setting? Just check this "servlet.xml". Thank you very much!

  • XML loader and UTF-16 - throws Content is not allowed in prolog

    Hi,
    Our ECC system is updated to unicode system recently. Now the iDoc downloaded from ECC is having a tag <?xml version="1.0" encoding="utf-16"?>.
    The XML Loader in the transaction throws an exception "Cannot perform action on XML document Content is not allowed in prolog. Exception: [Content is not allowed in prolog.]". If I change the encoding manually as "utf-8" and executing the transaction, it is working fine.
    Please let me know how to solve the issue.
    Thanks,
    Raman N

    Where should I enhance the webservice to make it able to handle zipped XML documents? Shouldn't take the AXIS library take care of this automatically?
    This is the web.xml document I use.
    <?xml version="1.0" encoding="UTF-8"?>
    <web-app id="WebApp_ID" version="2.4" xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd">
    <display-name>
    NDW2</display-name>
    <servlet>
    <display-name>
    Apache-Axis Servlet</display-name>
    <servlet-name>AxisServlet</servlet-name>
    <servlet-class>
    org.apache.axis.transport.http.AxisServlet</servlet-class>
    </servlet>
    <servlet>
    <display-name>
    Axis Admin Servlet</display-name>
    <servlet-name>AdminServlet</servlet-name>
    <servlet-class>
    org.apache.axis.transport.http.AdminServlet</servlet-class>
    <load-on-startup>100</load-on-startup>
    </servlet>
    <servlet-mapping>
    <servlet-name>AxisServlet</servlet-name>
    <url-pattern>/servlet/AxisServlet</url-pattern>
    </servlet-mapping>
    <servlet-mapping>
    <servlet-name>AxisServlet</servlet-name>
    <url-pattern>*.jws</url-pattern>
    </servlet-mapping>
    <servlet-mapping>
    <servlet-name>AxisServlet</servlet-name>
    <url-pattern>/services/*</url-pattern>
    </servlet-mapping>
    <servlet-mapping>
    <servlet-name>AdminServlet</servlet-name>
    <url-pattern>/servlet/AdminServlet</url-pattern>
    </servlet-mapping>
    <welcome-file-list>
    <welcome-file>index.html</welcome-file>
    <welcome-file>index.htm</welcome-file>
    <welcome-file>index.jsp</welcome-file>
    <welcome-file>default.html</welcome-file>
    <welcome-file>default.htm</welcome-file>
    <welcome-file>default.jsp</welcome-file>
    </welcome-file-list>
    </web-app>

  • XML Loader

    Hi all,
    Any help you can offer on this would be much appreciated...
    I'm tearing my hair out here.
    I'm trying to make a quick little function to load XML data
    from an individual url when called, and want to define:
    - The XML's url.
    - The variable to put the XML into.
    - The function to run after it is loaded.
    Have a look:
    <mx:Script>
    <![CDATA[
    //Alert class...
    import mx.controls.Alert;
    //Remote events class...
    import mx.rpc.events.*;
    //Remote http class...
    import mx.rpc.http.HTTPService;
    //New http service object...
    private var xmlService:HTTPService;
    [Bindable]
    //System configuration XML and variables...
    public var configXml:XML = new XML();
    public var ownerName:String = new String();
    //Load XML function (url to load from, function to run when
    loaded, error code to display)...
    public function loadXml(url:String, output:String,
    next:Function):void {
    //Create new http service...
    xmlService = new HTTPService();
    //Define the url to load XML from...
    xmlService.url = url;
    //Define the use of a proxy...
    xmlService.useProxy = false;
    //Format of the returned data...
    xmlService.resultFormat = "xml";
    //What to do when the data has loaded...
    xmlService.addEventListener("result",
    function(event:ResultEvent):void{
    //Put the loaded xml into the dynamic variable sent by the
    click function...
    this[output] = XML(event.result);
    //Run the next function...
    next();
    xmlService.send();
    public function showXml():void{
    Alert.show(configXml, "Configuration");
    ]]>
    </mx:Script>
    Which is then called by something like:
    <mx:Button click="loadXml('configuration.xml', 'configXml',
    showXml);" />
    It works fine on using a dynamic function name (next - >
    showXml) but not on a dynamic variable name (output ->
    configXml)... however I don't think this is the problem, the
    problem comes in when it tries to write back to the configXMl
    variable, the scope of it is wrong, I have tried "this[output]",
    "[output]" and as many AS ways i can think of, but any suggestions
    would be great...
    FYI - The XML loads in fine, it just doesn't move from the
    "output" variable to the "configXml" variable.
    I would like to be able to define the variable the xml is
    outputted to from the function attached to the button.
    Any help is very much appreciated.
    Thanks
    Oz

    One XMLLoader that I know about is the example program that we build in Chapter 12 of my "Building Oracle XML Applications" book.
    Steve Muench
    Development Lead, Oracle XSQL Pages Framework
    Lead Product Manager for BC4J and Lead XML Evangelist, Oracle Corp
    Author, Building Oracle XML Applications
    null

  • SEVERE: Servlet  threw load() exception

    I am trying to load servlet in Tomcat 5.5 . It is throwing an exception as follows. The LicenseAuthentication class exists in WEB-INF/Class directory. So it is not the problem.
    1. In lib folder there is no servlet.jar. If I put that I am getting different exception.
    2. In my servlet In init(), doPost() and doGet method implementation.
    3. In web.xml I had put the <load-on-start> parameter as 1.
    Can someone help immediately ? I am stuck with this issue for long time ?
    Thanks
    Murali
    =================================================
    <servlet>
    <servlet-name>License</servlet-name>
    <servlet-class>LicenseAuthentication</servlet-class>
    <load-on-startup>1</load-on-startup>
    </servlet>
    <servlet-mapping>
    <servlet-name>License</servlet-name>
    <url-pattern>/License</url-pattern>
    </servlet-mapping>
    =======================================================
    SEVERE: Servlet threw load() exception
    java.lang.NoClassDefFoundError: LicenseAuthentication$1
         at java.lang.Class.getDeclaredConstructors0(Native Method)
         at java.lang.Class.privateGetDeclaredConstructors(Class.java:2389)
         at java.lang.Class.getConstructor0(Class.java:2699)
         at java.lang.Class.newInstance0(Class.java:326)
         at java.lang.Class.newInstance(Class.java:308)
         at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1089)
         at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:966)
         at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:3956)
         at org.apache.catalina.core.StandardContext.start(StandardContext.java:4230)
         at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:760)
         at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:740)
         at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:544)
         at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:920)
         at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:883)
         at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:492)
         at org.apache.catalina.startup.HostConfig.start(HostConfig.java:1138)
         at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:311)
         at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:120)
         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1022)
         at org.apache.catalina.core.StandardHost.start(StandardHost.java:736)
         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1014)
         at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:443)
         at org.apache.catalina.core.StandardService.start(StandardService.java:448)
         at org.apache.catalina.core.StandardServer.start(StandardServer.java:700)
         at org.apache.catalina.startup.Catalina.start(Catalina.java:552)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:295)

    This is just Java 101. The NoClassDefFoundError simply means that the mentioned class is missing in the runtime classpath (while it was available in the classpath during compilation, this is the key difference with ClassNotFoundException).
    In the future, please start a new topic for each independent question instead of resurrecting old topics or hijacking other's topics.

  • Smartview XML Load Error

    Recently when connecting to SmartView, some users are receiving the following error:
    XML Load Error: Invalid XML Declaration
    Do you want to connect with Username/Password
    Yes No
    If you hit yes, sometimes it lets you log in after 2 or 3 tries, other times you need to completely shut down out of Excel and try again.
    It does not happen all the time or to all users.
    Smartview version 9.3.1.5.0.025
    Any else get this error or know what to do to correct it.
    Thanks

    Are you using more than one server for load balancing? If yes try checking the following:
    I've seen where one server is working and one is not.
    To check which one is working go to the connection manager and add a new connection manager that points directly to the one server:
    Somthing like this (hscuschlws00099 is the name of the server in this example)
    http://hscuschlws00099/hfmofficeprovider/hfmofficeprovider.aspx
    Then try using Smartview on each connection to each server. If one works and the other doesn't you can narrow it down to the one server.

  • XML load error - when moving table data after upgrade

    Greetings:
    Background:
    Previously in our 2.2 instance, we would use the Data Load/Unload feature of APEX to move data in the form of XML from instance 1 to instance 2. This woks well because it moves images also (BLOB)
    What Changed:
    Recently we did the upgrade to APEX 3.0. The tool is working well, but we are having issues uploading XML data in the same manner we used to. The process wizard works up until time for execution.. the following error message is seen.
    XML load error.
    Return to application.
    Assumption:
    I do not believe this is an XML file issues because the file I am testing the process with is from the EMP table, and is from the UNLOAD option on the same DB and SCHEMA.. (testing is unloading the data, than re-loading the same data to the same place)
    Internally some permissions or something internal must be missing.
    Assistance or suggestions on where to look is greatly appreciated.
    Regards,
    Tim

    Tim,
    Sorry for the delay - that silly day job keeps getting in the way.
    Here is a small procedure you could use to take the XML data file format exported from Application Express and import into your table. This uses the Java-dependent DBMS_XMLSAVE package, which avoids the issue mentioned above.
    create or replace procedure load_xml(
        p_clob   in clob,
        p_schema in varchar2,
        p_table  in varchar2 )
    is
        l_insCtx dbms_xmlsave.ctxType;
        l_rows   number;
    begin
        l_insCtx := dbms_xmlsave.newContext(p_schema || '.' || p_table);
        dbms_xmlsave.setDateFormat(l_insCtx,'yyyy-MM-dd''T''HH:mm:ss.SSS');
        l_rows := dbms_xmlsave.insertXML( l_insCtx, p_clob);
        dbms_xmlsave.closeContext(l_insCtx);
    end load_xml;I then ran the following quick test on apex.oracle.com just for verification.
    declare
        l_xml varchar2(32000);
    begin
        l_xml := '<?xml version="1.0"?>
    <ROWSET>
    <ROW>
      <ID>11645117496276327</ID>
      <FLOW_ID>30072</FLOW_ID>
      <NAME>F11645117496276327/no_image_found.gif</NAME>
      <FILENAME>no_image_found.gif</FILENAME>
      <MIME_TYPE>image/gif</MIME_TYPE>
      <CREATED_BY>JOEL</CREATED_BY>
      <CREATED_ON>2007-03-14T05:06:38.000</CREATED_ON> 
      <BLOB_CONTENT>474946383961C800...(data removed for this example)...41000003B</BLOB_CONTENT>
    </ROW>
    </ROWSET>';
        load_xml( l_xml, 'MY_DB_USER', 'MY_APEX_FILES' );
    end;It's now simply a matter of how you get your XML file(s) into a CLOB to call this procedure. The options include:
    1) Just pass in a VARCHAR2 as I did in the example above, which would limit you to roughly 32K.
    2) You could use DBMS_LOB.LOADCLOBFROMFILE to read it from the database server filesystem.
    3) You could upload the file via an APEX application (or some other means within APEX), you could convert the BLOB to a CLOB, and then call this procedure. If you need help with this method, let me know.
    Don't forget - as yet another alternative, you could always contact Oracle Support to see what could be done about that underlying database bug.
    I hope this helps.
    Joel

  • Swapping xml loaded Images to scene elements?

    Hi there!
    I have a small quick question about xml loaded images.
    Can you append/attach/swap the images to elements in your scene?
    I would like to manually animate a movieclip using keyframes and motion tweens. For example, to have a movieclip FLY! accross the screen! lol But I want the image on it to be of one that has been dynamically loaded.
    I can't seem to work out how to replace an image on a movieclip from a dynamically loaded image.
    Is it even possible?
    Thanks heaps for your time you guys!

    If the original image is the only object within the movieclip, you can use removeChildAt(0) to get rid of it, and use addChild(your_new_image) to replace it.

  • How do I script SWF files instead of JPG files in XML loader?

    I have a SWF loader (greensock.com platform) and a thumbnail image scroll underneath it made of small image buttons. Each image button has a link which loads a new SWF file into the SWF loader above. Here is the code for each button which loads the bigger SWF file into the loader above:
    Button3.addEventListener(MouseEvent.CLICK, Button3_PlayPopUp);
    function Button3_PlayPopUp(event:MouseEvent): void {
        //setting the sourceVar
        sourceVar="3.swf";
        //making the SWFLoader load
        //as setting the soureVar after the SWFLoader is created won't do anything unlesss
        //I also re-create the SWFLoader with the new sourceVar when the button is clicked
        loader_howToLoader2.url = sourceVar;
        loader_howToLoader2.load(true);
    Then I decided to load all button via XML loader. I followed the tutorial on XML loaders which deals with loading jpg images and assigning URL links to them in the following manner first in XML file:
    <image src="appThmb_imgs/appThmb_imgs117x175/A-illuminatorUpLit_117x175.jpg" title="UpDownGlowingVase" url="http://www.888acolyte.com"/>
    and then in AS3 like this:
    var xmlLoader:URLLoader = new URLLoader();
    thisOne.link = imageList[item].attribute("url");
    function clickScrollerItem(e:MouseEvent):void {
    //trace("clicked item " + e.currentTarget.itemNum + " - visit url: " + e.currentTarget.link);
    var urlRequest:URLRequest = new URLRequest(e.currentTarget.link);
    try {
    navigateToURL(urlRequest);
    catch (e:Error) {
    // handle error here
    trace(e);
    My question is: How do I apply the code to each individual small thumbnail button to load a bigger image into the SWF loader above? Do I have to add something to XML file or this way it will never work with jpg images? Can url in XML file set the source var (//setting the sourceVar), since they are all individual and then somehow apply the making SWL loader to load part (//making the SWFLoader load) as a standard somewhere in the AS3 code?

    O.K. Here is my COMPLETE function.
    xmlLoader.addEventListener(Event.COMPLETE, LoadXML);
    function LoadXML(e:Event):void {
        trace("xml load complete");
        xmlData = new XML(e.target.data);
        //trace(xmlData.image); //we'll see each image xml element listed in the output panel with this xmlList
        buildScroller(xmlData.image); //rather than trace the xmlList, we send it to our buildScroller function
    //build scroller from xml
    function buildScroller(imageList:XMLList):void{
        trace("build Scroller");
        //var scroller_x:int=0;
        for (var item:uint = 0; item<imageList.length();item++) {
            var thisOne:MovieClip = new MovieClip();
            //thisOne.img_width=imageList[item].attribute("width");
            //outline
            var blackBox:Sprite = new Sprite();
            blackBox.graphics.beginFill(0xFFFFFF);
            blackBox.graphics.drawRect(-1, -1, 86, 128);//-1,-1 places rectangle 1px left and up.86, 128 draws rectangle 1px wider on all sides of placed image dimenstions of 84x126
            thisOne.addChild(blackBox);
            //scroller_x += thisOne.img_width + 20;
            //var currentX = currentImageWidth+spaceBetween;//modified line to adjust variable thumb widths
            thisOne.x = (84 + padding) *item;//84 is the width of the loaded images and 15 (which was before paddign var) is the padding
            //thisOne.x = scroller_x;//modified line to adjust variable thumb widths
            thisOne.itemNum = item;
            thisOne.title = imageList[item].attribute("title");
            thisOne.link = imageList[item].attribute("url");
            thisOne.src = imageList[item].attribute("src");
            thisOne.alpha = 0;//makes all thumb images at alpha=0 before they are fully loaded
            //trace(thisOne.itemNum, thisOne.title, thisOne.link, thisOne.src);
            //Loading and Adding the Images
            //image container
            var thisThumb:MovieClip = new MovieClip();
            //add image
            var ldr:Loader = new Loader();
            //var url:String = imageList[item].attribute("src");
            var urlReq:URLRequest = new URLRequest(thisOne.src);
            trace("loading thumbnail "+item+" into Scroller: " + thisOne.src);//url
            ldr.load(urlReq);
            //assign event listeners for Loader
            ldr.contentLoaderInfo.addEventListener(Event.COMPLETE,completeHandler);//tells us when the loading is complete
            ldr.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, errorHandler);//tells us if there are any typo errors when the loading is complete
            thisThumb.addChild(ldr);
            thisOne.addChild(thisThumb);
            //create listeners for this thumb
            thisOne.buttonMode = true;//makes boxes act as buttons
            thisOne.addEventListener(MouseEvent.CLICK, clickScrollerItem);//makes boxes act as buttons
            thisOne.addEventListener(MouseEvent.MOUSE_OVER, overScrollerItem);//traces the title when the mouse is over the bounding box in the Output Panel
            thisOne.addEventListener(MouseEvent.MOUSE_OUT, outScrollerItem);//traces the title when the mouse is out the bounding box in the Output Panel
            //add item
            scroller.addChild(thisOne);
    But I am not sure if I expressed myself clearly. All what you have indicated happens. Images are being loaded and url strings are working. I can not figure out how to tweek the code so instead of url specified in xml file I can load swf image into the SWF loader on the same screen?

  • Data Services Fix Pack 12.2.1.2 issued to resolve XML loader problem

    We've had a few customers contacting us about the following error message:
    "The message type for datastore <my_ds> has not been set". Please notify Customer Support"
    Note that the text "<my_ds> will be the name of the XML loader you have in your dataflow.  This error occurs when you are adding a new loader to a dataflow that is an XML type. 
    The customers that have reported this issue were all building real-time jobs and the loader type was XML Message Target.
    In order to address this issue you will need to download and install the latest update which is 12.2.1.2.  The above issue was introduced in 12.2.1.1 (3.2 SP1).  You will ONLY have to install the client components (Designer) in order to address this issue.  no updates are necessary to the server side of the application to address this problem.
    An SAP Note has also been written up on this issue:  [1423045|https://bosap-support.wdf.sap.corp/sap/support/notes/1423045]
    Thanks,
    Ryan

    there is a connection timeout when trying to contact the laptop.the last lines it shows are:
    PCI: setting IRQ 0 as level-triggered
    ALI15X3: not 100% native mode: will probe irqs later
    ide0: BM-DMA at 0x8080-0x8087, BIOS settings: hda: DMA, hdb:pio
    ide1: BM-DMA at 0x8088-0x808f, BIOS settings: hdc: pio, hdd: pio
    hda: IC25N060ATMR04-0, ATA DISK drive

  • Making a call over HTTPS with LoadVars, XML.load(), and WebService - Yes or No?

    Hello, do LoadVars, XML.load(), or WebService support HTTPS-based endpoints, Yes or No?
    BACKGROUND
    ============
    I've been trying to get a LoadVars to actually make a call to an HTTPS endpoint. There is nothing in the documentation that says it can't. I know that there's also XML.load() and WebService class, but from the looks of it they don't do HTTPS.
    During my tests I have absolutely no issues with making calls to the same service over HTTP. When I change it to HTTPS I don't see HTTPStatus or even failures. Also, netstat on my server will show a connection being established with the endpoint when using HTTP but not when using HTTPS. I've also tried setting SSLVerifyCertificate to "false" in my Server.xml and after a restart of AMS it doesn't help, same symptom.
    I've also googled and looked through all Adobe forum posts that I can find:
    https://forums.adobe.com/message/4938426#4938426
    https://forums.adobe.com/thread/1661461
    https://forums.adobe.com/thread/782037
    https://forums.adobe.com/message/74981
    https://forums.adobe.com/message/5107735#5107735
    https://forums.adobe.com/message/7815#7815
    https://forums.adobe.com/message/53870#53870
    https://forums.adobe.com/message/87797#87797
    WebService Class - http://stackoverflow.com/questions/5619776/webservice-and-fms
    The best I found from the posts above is a non-commital answer from adobe staff at https://forums.adobe.com/message/4938426#4938426 and a 3rd party person saying that Webservice doesn't work at http://stackoverflow.com/questions/5619776/webservice-and-fms.
    All I need is an official supported/not-supported from the Adobe staff. Shouldn't be to hard after 5 years or so of ignoring the questions in the forum right?

    Adobe, please provide some details to your current and possibly potential customers, in at least one of the many unanswered posts about making HTTPS requests from AMS.
    P.S.
    realeyes_jun,
    RealEyes Media has been an inspiration to me for many years, and I would like to thank them for their efforts to better the media streaming community.
    Also, would it be possible to please release the source to REDbug?

  • V15 XML Loader Access To Path Not Allowed

    We are just starting to test our V15 sandbox system that has just been upgraded.  We have a transaction that works fine in our older environment (V12.2) but the same transaction fails in V15. The first sequence in the transaction is an XML Loader that tries to load and XML configuration file from the local MII server where the transaction is running.  The action fails with a Access to path /directoryNameHere/fileNameHere.xml is not allowed error.
    As far as we can tell, all of the filesystem/OS level permissions (Linux in our case) are the same as they are in our old environment.
    Other than file/directory permissions, any ideas why this might fail?  Has anything changed in V15 that would potentially impact this?
    We are not specifying a Credential Store alias (listed as optional).
    Thank you,
    Mike

    At some point a 'Default File Path' parameter was added as a system property and it's value may be causing your issue.
    System Properties - SAP Manufacturing Integration and Intelligence - SAP Library
    Default File Path
    DefaultFilePath
    The path on the file system (along with the subfolders) used to store files that need to be accessed by the following workbench actions for read/write operations:
    File I/O
    CreateDirectory
    CreateZipArchive
    DeleteFile
    GetFileList
    WriteFile
    FTPInput
    FTPOutput
    ADS Printing
    E-Mail
    Send Mail
    Read Mail
    LoggingXML Tracer
    Web
    HTMLSaver
    XMLSaver
    TextSaver
    ImageSaver
    HTMLLoader
    XMLLoader
    TextLoader
    ImageLoader
    Note
    Access to the files under the previous path (and the subfolders) will be lost if the path is changed.
    If the path is empty, you can access the file system, provided the file system provides read/write permissions. The same holds good for prior releases.

  • XML loader in custom Scrollpane

    I'm working on my first website, and have mostly been using tutorials on Lynda.com which has been hugely helpful.  I need several different scrollpanes in the site, one of which is a typical thumbnail gallery that uses XML to load the thumbnail images and displays full-size images & text when thumbnails are clicked.  With a Lynda tutorial I was able to write the appropriate code and use the canned scrollpane in Flash, but even after changing some of the properties I really don't like how it looks.  I found another tutorial (http://www.developphp.com/Flash_tutorials/show_tutorial.php?tid=265) that shows a scrollpane I like better (after some modifications), and I've got it working perfectly elsewhere on the site.. but I'm wondering if/how I can integrate the XML code I've already written into this new scrollpane so I can replace the canned one?  If anyone has any tips or can give me any advice I'd really appreciate it.. 
    Thank you!
    I'm using Flash CS4/AS3
    Macbook Pro
    This is the code for the canned one with all the XML:
    var titleArray:Array = new Array();
    var descriptionArray:Array = new Array();
    var largeimageArray:Array = new Array();
    var thumbimageArray:Array = new Array();
    var imageNum:Number=0;
    var totalImages:Number;
    //xml
    //load xml
    var XMLURLLoader:URLLoader = new URLLoader();
    XMLURLLoader.load(new URLRequest("insituportfolio/mainInSituGallery.xml"));
    XMLURLLoader.addEventListener(Event.COMPLETE, processXML);
    function processXML(event:Event):void {
    var theXMLData:XML=new XML(XMLURLLoader.data);
    totalImages=theXMLData.title.length();
    for (var i:Number = 0; i < totalImages; i++) {
    titleArray.push(theXMLData.title[i]);
    descriptionArray.push(theXMLData.description[i]);
    largeimageArray.push(theXMLData.largeimage[i]);
    thumbimageArray.push(theXMLData.thumbimage[i]);
    loadThumbnail();
    mainScrollPane.source=thumbsMain;
    // load thumbs
    function loadThumbnail():void {
    trace(imageNum);
    var thumbLoader:Loader = new Loader();
    thumbLoader.load(new URLRequest(thumbimageArray[imageNum]));
    thumbLoader.y = 100*imageNum;
    var thislargeimage:String = largeimageArray[imageNum];
    var thistitle:String = titleArray[imageNum];
    var thisdescription:String = descriptionArray[imageNum];
    thumbLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, thumbLoaded);
    function thumbLoaded(event:Event):void {
    thumbsMain.addChild(thumbLoader);
    thumbsMain.buttonMode=true;
    mainScrollPane.update();
    thumbLoader.addEventListener(MouseEvent.CLICK,loadMainImage1);
    function loadMainImage1(event:MouseEvent):void {
    largeUILoader.source=thislargeimage;
    selectedTitle.text=thistitle;
    selectedDescrip.text=thisdescription;
    //add to imageNum (1);
    imageNum++;
    if (imageNum<totalImages){
    loadThumbnail();
    And this is the code for the Scrollpane I'd like to use:
    // Scroll My Content function - AS3
    function scrollMyContent () {
    // Cache the TextField as a bitmap to improve performance.
        content_mc.cacheAsBitmap = true;
    // Event Listeners
    scrollDragger.addEventListener(MouseEvent.MOUSE_DOWN, scrollDraggerPress);
    stage.addEventListener(MouseEvent.MOUSE_UP, mouseUpOnStage);
    // Set variables
    var scrollbarHeight:Number = scrollbarBG.height;
    var contentHeight:Number = content_mc.height;
    var scrollDraggerHeight:Number = scrollDragger.height;
    var maskHeight:Number = contentMask.height;
    var scrollAmout:Number = (contentHeight-maskHeight)/(scrollbarHeight-scrollDraggerHeight);
    var topBound:Number = scrollbarBG.y;
    var bottomBound:Number = scrollbarBG.height-scrollDraggerHeight+scrollbarBG.y;
    var startPos:Number = content_mc.y;
    var leftBound:Number = scrollbarBG.x;
    var absNumSet:Number = 0;
        // When scrollDragger gets pressed we do this
    function scrollDraggerPress(event:MouseEvent):void {
            // Set bounds using some of the scroller BG properties claimed above
    var bounds:Rectangle = new Rectangle(leftBound, topBound, 0, bottomBound);
    scrollDragger.startDrag(false, bounds);
    stage.addEventListener(MouseEvent.MOUSE_MOVE, reportStageMouse);
    function reportStageMouse(event:MouseEvent):void {
    absNumSet = Math.abs(scrollbarBG.y - scrollDragger.y);
    content_mc.y = Math.round(absNumSet * - 1 * scrollAmout + startPos);
    // When mouse is released while dragging we do this
    function mouseUpOnStage(event:MouseEvent):void {
    stopDrag();
    scrollMyContent();

    Thank you, that's helpful... so if I just swap the source, do I just drop in the code for the xml after?  Or should it go elsewhere?
    I'm sorry, I realize this is probably a very basic question.

Maybe you are looking for

  • Deleting line item from sales order

    Hi to All, I am an SD support consultant,i had an issue please help me out, When i am trying to delete one line item from the sales order i am getting error message that line item cannot be deleted because of planned order.

  • DNS server configuration on solaris 10

    Please, can somebody give me the way, step by step to configure a DNS server on solaris 10. i want to have the directories and files that it is necessary to modify and the modification to have a domain name "deptech.lan" with ip adress of the DNS ser

  • Logon page customisation

    Dear Friends I have a requirement that the employees has to give the option of changing password in the logon screen .so for this i have developed one custom zapplication in webdynpro abap . i have created an iview for this . Now i got the par file i

  • One small error but it is the same error all the way down through the if's

    This program is so close to finally running after I have spent well over 8 hours trying to figure out the code now I am getting an aggravating error saying " ; " expected all the way down throughout my if statements. Can anyone please tell me what to

  • How to install graphical desktop interface on Oracle linux server 6.2

    Hi I have installed Oracle Linux server 6.2 how i install graphical desktop interface on server class installation