XML and AS2.0

OK I have been going down one road for this and have taken a
few wrong turns.
A few things about what we are looking at:
I am using Flash CS3 but I am using Action Script 1.0/2.0 for
compatability purposes.
What I have been able to do so far is create random instances
of a movie clip to appear over a set amount of time but I need to
go a bit further. The web application needs to be updated regularly
and the best way I can think of doing that is with keeping all the
variables in an XML. The problem is I am not sure how to format the
XML properly to get Flash to read it and load the variables.
I am creating an online version of a vision screening tool we
use. The test is graphically simple just a collection of a few
primitives on a dark background. There are basically two objects a
fixation point and a stimulus. What I need to be able to do is
this.
Display either movieclip at (x,y) for (z)ms where x,y,& z
are all variables loaded from an xml. I have asked questions along
this line before but this is a different scope in case anyone wants
to claim I double posted, this is quite different than they way I
was doing it before.
Any help with the XML or even any actionscript suggestions
would be greatly appreciated.
Thanks

Okay, you still need to check what _root[oValue] is:
trace (_root[oValue]);
Is it a movie clip, undefined, string?
shurleynova wrote:
>
quote:
Originally posted by:
Newsgroup User
> If you put this on the frame within the clip itself
(rather than on the
> clip), you could use:
>
> this.onEnterFrame=function() {
> _root[ovalue]._x=xValue;
> _root[ovalue]._y=yValue;
> }
>
> But maybe that's something you can implement when you
get the initial
> problem fixed.
>
> Patrick
>
> Patrick B wrote:
> > Your notation is a bit archaic but we can work with
it :)
> >
> > onClipEvent (enterFrame) {
> > setProperty(_root[oValue],_x,xValue);
> > setProperty(_root[oValue],_y,yValue);
> >
> > }
> >
> > Better still:
> >
> > onClipEvent (enterFrame) {
> > _root[oValue]._x=xValue;
> > _root[oValue]._y=yValue;
> >
> > }
> >
> > Just make sure xValue and yValue exist and are
numbers and you should be
> > okay. How does that work out?
> >
> > Patrick
> >
> >
>
>
> Ok I know my syntax is a bit rusty but I am slowly
learning to appreciate the
> dot notation as a much easier way to read the code.
>
> so I went ahead and place this code on a movie clip
>
> onClipEvent (enterFrame) {
> _root[oValue]._x=xValue;
> _root[oValue]._y=yValue;
>
> }
>
> I checked the output window and the action script to
make sure the xValue and
> yValue were being read as numbers and that it refelcted
that in the output I
> have attached the action script below. Also this is what
is in the output
> window:
>
> Data loaded: true
> object_type=stimuli
> x_coordinates=25
> y_coordinates=25
> z_display_interval=200
> object_type=stimuli
> x_coordinates=85
> y_coordinates=175
> z_display_interval=200
> object_type=stimuli
> x_coordinates=325
> y_coordinates=55
> z_display_interval=200
> object_type=stimuli
> x_coordinates=115
> y_coordinates=355
> z_display_interval=200
> object_type=fixation
> x_coordinates=289
> y_coordinates=229
> z_display_interval=200
>
> Maybe I am looking at this wrong and maybe there is one
other step I need to
> include is what I keep thinking but I dont knwo what it
is.
>
>
>
>
> var timelineXML=new XML();
>
> timelineXML._context=this;
> timelineXML.ignoreWhite=true;
>
> timelineXML.onLoad=function(success:Boolean) {
> trace ('Data loaded: '+success);
> this._context.parseXMLData(this.firstChild);
> }
> //onLoad
>
> function parseXMLData(data:XMLNode) {
> for (var
count:Number=0;count<data.childNodes.length;count++) {
> var currentNode:XMLNode=data.childNodes[count];
> var oValue:String=String(currentNode.attributes.omc);
> var xValue:Number=Number(currentNode.attributes.xp);
> var yValue:Number=Number(currentNode.attributes.yp);
> var zValue:Number=Number(currentNode.attributes.zms);
> trace ('object_type='+oValue);
> trace ('x_coordinates='+xValue);
> trace ('y_coordinates='+yValue);
> trace ('z_display_interval='+zValue);
>
> }
> }
> //parseXMLData
>
> timelineXML.load('input.xml');
>
http://www.baynewmedia.com
Faster, easier, better...ActionScript development taken to
new heights.
Download the BNMAPI today. You'll wonder how you ever did
without it!
Available for ActionScript 2.0/3.0.

Similar Messages

  • Not able to generate AS2 MDN when receiving custom XML via AS2

    Hi friends,
    I have setup the trading partner and the corresponding TP certificate import for receiving the custom XML via AS2 channel.
    I am receiving the custom xml properly to oracle b2b and able to receive the same to bpel as well. however in the oracle b2b console under reports tab i am seeing only one record for inbound document receive and i am not seeing the other record for the AS2 MDN going back to vendor. I have setup the AS2 channel under the external trading partner --> Channel using the vendor AS2 URL and selected all the security parameters while creating the Outbound AS2 channel.
    1. Not able to generate AS2 MDN when receiving custom XML via AS2.
    2. eventhough i am able to decrypt the inbound custom XML and ablr to recieve it in bpel also for processing, in the reports tab the inbound message state is changing to MSG_ERROR and it has the folloing error message:
    Error Code
    B2B-50037
    Error Description
    Machine Info: (***********)  Description: B2B inbound message processing error
    Error Level
    ERROR_LEVEL_COLLABORATION
    for AS2 MDN generation for custom XML receiving using As2 protocol, do we need to setup anything other than the outbound As2 Channel using the external vendor AS2 URL?
    Can you please help me how can i generate the AS2 MDN for the inbound custom XML document i have received and also why the inbound message is failing even though i am receiving the custom XML properly to bpel?
    Thanks,
    Amirineni.

    Hi Prasanna,
    Vendor has enabled the ACK mode as SYNC.
    Below are the headers for the inbound message to B2B. and we are able to receive the input message to bpel also.
    Protocol Transport Binding
    ChannelName=******** AS2-To=****AS2 TE=trailers, deflate, gzip, compress Date=Thu, 02 Oct 2014 14:26:31 GMT AS2-Version=1.2 Accept-Encoding=deflate, gzip, x-gzip, compress, x-compress AS2-From=****AS2 Disposition-Notification-Options=signed-receipt-protocol=optional, pkcs7-signature; signed-receipt-micalg=optional, sha1 Disposition-Notification-To=https://******/as2 Message-ID=<CLEO-20141002_142630452-31X54N@****_*****AS2.pcwbedi1-O> Content-type=application/pkcs7-mime; smime-type=enveloped-data; name=smime.p7m Content-length=747006 MSG_RECEIVED_TIME=Thu Oct 02 10:26:39 EDT 2014 Subject=EDI ECID-Context=1.005175bK7U^AXNJCAnf9Cx0002pW000yjX;kXjE1ZDLIPGIj2QCYV8QoKSSILRO_PQT_IS Proxy-Client-IP=****** Recipient-Address=https://******/b2b/httpReceiver User-Agent=RPT-HTTPClient/0.3-3I (Windows 2003) X-Forwarded-For=****** Content-Disposition=attachment; filename="smime.p7m" Host=****** EDIINT-Features=CEM, multiple-attachments, AS2-Reliability Connection=Keep-Alive X-WebLogic-KeepAliveSecs=30 X-WebLogic-Force-JVMID=-1497702782 From=****** Mime-Version=1.0
    Message Digest
    Message Digest
    Digest Algorithm
    sha1
    Transport Protocol
    HTTP
    Transport Protocol Version
    1.0
    Url
    http://******
    security
    Transport Headers
    ChannelName=****** AS2-To=******AS2 TE=trailers, deflate, gzip, compress Date=Thu, 02 Oct 2014 14:26:31 GMT AS2-Version=1.2 Accept-Encoding=deflate, gzip, x-gzip, compress, x-compress AS2-From=****AS2 Disposition-Notification-Options=signed-receipt-protocol=optional, pkcs7-signature; signed-receipt-micalg=optional, sha1 Disposition-Notification-To=https://******/as2 Message-ID=<CLEO-20141002_142630452-31X54N@****AS2_*****AS2.pcwbedi1-O> Content-type=application/pkcs7-mime; smime-type=enveloped-data; name=smime.p7m Content-length=747006 MSG_RECEIVED_TIME=Thu Oct 02 10:26:39 EDT 2014 Subject=EDI ECID-Context=1.005175bK7U^AXNJCAnf9Cx0002pW000yjX;kXjE1ZDLIPGIj2QCYV8QoKSSILRO_PQT_IS Proxy-Client-IP=***** Recipient-Address=*******/b2b/httpReceiver User-Agent=RPT-HTTPClient/0.3-3I (Windows 2003) X-Forwarded-For=******* Content-Disposition=attachment; filename="smime.p7m" Host=***** EDIINT-Features=CEM, multiple-attachments, AS2-Reliability Connection=Keep-Alive X-WebLogic-KeepAliveSecs=30 X-WebLogic-Force-JVMID=-1497702782 From=***** Mime-Version=1.0
    Thanks,
    Amirineni

  • How to edit bitmap which is imported in flash using xml and save the edited bitmap back to xml in flash.

    hi all
    It would be appreciated if any one let me know how to edit
    bitmap which is imported in flash using xml and save the edited
    bitmap back to xml in flash.
    Is it posible to save the bitmap data in flash?
    thanks in advance

    Yes you can... but like I said before you need to upload the
    data from the changes you make to a server.
    In terms of the solution... its unlikely that you'll find one
    specifically for your needs. You will have to learn whatever you
    don't know how already and maybe adapt some existing examples to
    your needs.
    To change the visual state of a movie clip... you just do all
    the regular things that you want to do to it using flash... scale,
    rotation, drawing API , textfields etc in actionscript. If you
    don't know how to how to do that stuff, then you need to learn that
    first. That's basic actionscript.
    You can capture the visual state of a movieclip using the
    BitmapData class. That includes a loaded jpeg. You can also
    manipulate bimatp data using the same class. You should read up on
    that if you don't know how to use it or check out the examples
    below for uploading info.
    For uploading to the server:
    Here's an as2 solution that took 15 secs to find using
    google:
    http://www.quasimondo.com/archives/000645.php
    If you're using as3, google search for "jpeg encoder as3" and
    look through that info. There are also historical answers in the
    forums here related to this type of thing that might help as
    well.

  • XML and Class Implementation?

    Hey everyone,
    I'm new to this forum and pretty new to AS.
    I've created a fairly simple navigation bar.
    SWF Sample
    What I'd really like to do make this entirely dynamic by
    loading the images, tab names and hyperlink via XML (or an array).
    That way, I could use the same SWF and edit it via XML. I
    understand AS pretty well, but haven't wrapped my head around
    implementing XML and extending classes and such.
    Any help or direction would be greatly appreciated. If you'd
    like the FLA, just let me know.
    Cheers,
    Michael

    Michael,
    > I understand AS pretty well, but haven't wrapped my
    > head around implementing XML and extending classes
    > and such.
    XML can get complicated, because it deals with external
    files, but on
    the other hand, the XML class, which defines your the XML
    object you'll
    need, is like any other class in the ActionScript 2.0
    Language Reference.
    The XML class entry is your one-stop shop for all the
    functionality of that
    object, including its properties (characteristics), methods
    (things it can
    do), and events (things it can react to).
    Here's a free tutorial on XML in Flash, from Community MX.
    http://www.communitymx.com/abstract.cfm?cid=E399FF13E4DD1CB3
    This was written before AS2 strong typing was in fashion. By
    that, I
    mean the post colon suffix you'll see after variable
    declarations (var
    myNum:Number = 5, rather than var myNum = 5). But even so,
    it's a good
    article and should give you a head start.
    As for writing and extending classes, I'll recommend Joey
    Lott's
    three-part ActionScript 2.0 Primer.
    http://www.person13.com/articles
    Between the two of those, you've got a bit of reading ahead
    of you, but
    it's well worth it. :)
    David Stiller
    Adobe Community Expert
    Dev blog,
    http://www.quip.net/blog/
    "Luck is the residue of good design."

  • Is it possible to convert HTML to XML in as2?

    Hi,
    I am trying to develop a stock widget to use in my mobile using flashlite 2.x.
    I have chosen "http://charting.nasdaq.com" to obtain 5days chart /6months chart..
    But I am not able to use XML object for this and parse.. The values are in table format.. So I have to use LoadVars.. but writing a AS2 code
    to obtain values like High/Low price of the stock or volume is very lengthy since the data obtained are not in XML format..
    i tried this
    var example_xml:LoadVars = new LoadVars();
    example.ignoreWhite = true;
    example_xml.load("http://charting.nasdaq.com/ext/charts.dll?2-1-14-0-0-75-03NA000000www-&SF:4|5-WD=539-HT=39 5--XTBL-");
    example_xml.onLoad = function(success) {
         if (success == true) {
              trace(example_xml);
    Is it possible to convert them to xml and use relevent methods or xml properties?
    If I use example_xml:XML = new XML() then tracing example_xml (as above) doesn't give any data
    Any help?

    I had a project a few years ago where I converted 10s of thousands of TestStand HTML files from TS 1.0 and 3.0.
    Most of what I did is specific to our internal data structures, but I'll try to help get you started.
    The general idea is to pick out the report header and data sections from each file, then eliminate the HTML formatting.
    The attached file will extract the Report Header and data sections.
    To use this, you will need to download this additional VI that I posted here in the regex board a few years ago.
    http://forums.ni.com/t5/BreakPoint/Regular-Expressions-Board/m-p/1269088#M14343
    Here is one more file that will parse out each data record and dtermine it's Name, status, type value, limits and duration/timestamp info
    Now is the right time to use %^<%Y-%m-%dT%H:%M:%S%3uZ>T
    If you don't hate time zones, you're not a real programmer.
    "You are what you don't automate"
    Inplaceness is synonymous with insidiousness
    Attachments:
    Parse TestStand HTML.vi ‏42 KB
    Parse TestStand HTML Data Section.vi ‏55 KB

  • Multiple plugtmp-1 plugtmp-2 etc. in local\temp folder stay , crossdomain.xml and other files containing visited websitenames created while private browsing

    OS = Windows 7
    When I visit a site like youtube whith private browsing enabled and with the add-on named "shockwave flash" in firefox add-on list installed and activate the flashplayer by going to a video the following files are created in the folder C:\Users\MyUserName\AppData\Local\Temp\plugtmp-1
    plugin-crossdomain.xml
    plugin-strings-nl_NL-vflLqJ7vu.xlb
    The contents of plugin-crossdomain contain both the "youtube.com" adress as "s.ytimg.com" and is as follows:
    <?xml version="1.0"?>
    <!DOCTYPE cross-domain-policy SYSTEM "http://www.macromedia.com/xml/dtds/cross-domain-policy.dtd">
    -<cross-domain-policy> <allow-access-from domain="s.ytimg.com"/> <allow-access-from domain="*.youtube.com"/> </cross-domain-policy>
    The contents of the other file I will spare you cause I think those are less common when I visit other sites but I certainly don't trust the file. The crossdomain.xml I see when I visit most other flashpayer sites as well.
    I've also noticed multiple plugin-crossdomain-1.xml and onwards in numbers, I just clicked a youtube video to test, got 6 of them in my temp plus a file named "plugin-read2" (no more NL file cause I changed my country, don't know how youtube knows where I'm from, but that's another subject, don't like that either). I just noticed one with a different code:
    <?xml version="1.0"?>
    -<cross-domain-policy> <allow-access-from domain="*"/> </cross-domain-policy>
    So I guess this one comprimises my browsing history a bit less since it doesn't contain a webadress. If these files are even meant to be deposited in my local\temp folder. The bigger problem occurs when they stay there even after using private browsing, after clearing history, after clearing internet temporary files, cache, whatever you can think of. Which they do in my case, got more than 50 plugtmp-# folders in the previous mentioned local\temp folder containing all website names I visited in the last months. There are a variety of files in them, mostly ASP and XML, some just say file. I have yet to witness such a duplicate folder creation since I started checking my temp (perhaps when firefox crashes? I'd say I've had about 50 crashes in recent months).
    I started checking my temp because of the following Microsoft Security Essential warnings I received on 23-4-12:
    Exploit:Java/CVE-2010-0840.HE
    containerfile:C:\Users\Username\AppData\Local\Temp\jar_cache2196625541034777730.tmp
    file:C:\Users\Username\AppData\Local\Temp\jar_cache2196625541034777730.tmp->pong/reversi.class
    and...
    Exploit:Java/CVE-2008-5353.ZT
    containerfile:C:\Users\Noname\AppData\Local\Temp\jar_cache1028270176376464057.tmp
    file:C:\Users\Noname\AppData\Local\Temp\jar_cache1028270176376464057.tmp->Testability.class
    Microsoft Security Essentials informed me that these files were quarantained and deleted but when going to my temp file they were still there, I deleted them manually and began the great quest of finding out what the multiple gigabytes of other files and folders were doing in that temp folder and not being deleted with the usual clearing options within firefox (and IE).
    Note that I have set my adobe flasplayer settings to the most private intense I could think of while doing these tests (don't allow data storage for all websites, disable peer-to peer stuff, don't remember exactly anymore, etc.). I found it highly suspicious that i needed to change these settings online on an adobe website, is that correct? When right-clicking a video only limited privacy options are available which is why I tried the website thing.
    After the inital discovery of the java exploit (which was discovered by MSE shortly after I installed and started my first scan with Malwarebytes, which in turn made me suspicious whether I had even downloaded the right malwarebytes, but no indication in the filename if I google it). Malwarebytes found nothing, MSE found nothing after it said it removed the files, yet it didn't remove them, manually scanning these jar_cache files with both malwarevytes and MSE resulted in nothing. Just to be sure, I deleted them anyways like I said earlier. No new jar_cache files have been created, no exploits detected since then. CCleaner has cleaned most of my temp folder, I did the rest, am blocking all cookies (except for now shortly), noscript add-on has been running a while on my firefox (V 3.6.26) to block most javascripts except from sites like youtube. I've had almost the same problem using similar manual solutions a couple of months ago, and a couple of months before that (clearing all the multiple tmp folders, removing or renaming jar_cache manually, running various antmalware software, full scan not finding a thing afterwards, installing extra add-ons to increase my security, this time it's BetterPrivacy which I found through a mozilla firefox https connection, I hope, which showed me nicely how adobe flash was still storing LSO's even after setting all storage settings to 0 kb and such on the adobe website, enabling private browsing in firefox crushed those little trolls, but still plugtmp trolls are being created, help me crush them please, they confuse me when I'm looking for a real threat but I still want to use flash, IE doesn't need those folders and files, or does it store them somewhere else?).
    I'm sorry for the long story and many questions, hope it doesn't scare you away from helping me fight this. I suspect it's people wanting to belong to the hackergroup Anonymous who are doing this to my system and repeating their tricks (or the virus is still there, but I've done many antivirus scans with different programs so no need to suggest that option to me, they don't find it or I run into it after a while again, so far, have not seen jar_cache show up). Obviously, you may focus on the questions pertaining firefox and plugtmp folders, but if you can help me with any information regarding those exploits I would be extremely grateful, I've read alot but there isn't much specific information for checking where it comes from when all the anti-virus scanners don't detect anything anymore and don't block it incoming. I also have downloaded and installed process monitor but it crashes when I try to run it. The first time I tried to run it it lasted the longest, now it crashes after a few seconds, I just saw the number of events run up to almost a million and lots of cpu usage. When it crashed everything returned back to normal, or at least that's what I'm supposed to think I guess. I'll follow up on that one on their forum, but you can tell me if the program is ligit or not (it has a microsoft digital signature, or the name micosoft is used in that signature).

    update:
    I haven't upgraded my firefox yet because of a "TVU Web Player" plugin that isn't supported in the new firefox and I'm using it occasionally, couldn't find an upgrade for it. Most of my other plugins are upgraded in the green (according to mozilla websitechecker):
    Java(TM) Platform SE 6 U31 (green)
    Shockwave for Director (green - from Adobe I think)
    Shockwave Flash (green - why do I even need 2 of these adobe add-ons? can I remove one? I removed everything else i could find except the reader i think, I found AdobeARM and Adobe Acrobat several versions, very confusing with names constantly switching around)
    Java Deployment Toolkit 6.0.310.5 (green, grrr, again a second java, why do they do this stuff, to annoy people who are plagued with java and flash exploits? make it more complicating?)
    Adobe Acrobat (green, great, it's still there, well I guess this is the reader then)
    TVU Web Player for FireFox (grey - mentioned it already)
    Silverlight Plug-In (yellow - hardly use it, I think, unless it's automatic without my knowing, perhaps I watched one stream with it once, I'd like to remove it, but just in case I need it, don't remember why I didn't update, perhaps a conflict, perhaps because I don't use it, or it didn't report a threat like java and doesn't create unwantend and history compromising temp files)
    Google Update (grey - can I remove? what will i lose? don't remember installing it, and if I didn't, why didn't firefox block it?)
    Veetle TV Core (grey)
    Veetle TV Player (grey - using this for watching streams on veetle.com, probably needs the Core, deleted the broadcaster that was there earlier, never chose to install that, can't firefox regulate that when installing different components? or did i just miss that option and assumed I needed when I was installing veetle add-on?)
    Well, that's the list i get when checking on your site, when i use my own browseroptions to check add-ons I get a slightly different and longer list including a few I have already turned off (which also doesn't seem very secure to me, what's the point in using your site then for anything other than updates?), here are the differences in MY list:
    I can see 2 versions of Java(TM) Platform SE 6 U31, (thanks firefox for not being able to copy-paste this)
    one "Classic Java plug-in for Netscape and Mozilla"
    the other is "next generation plug-in for Mozilla browsers".
    I think I'll just turn off the Netscape and Mozilla one, don't trust it, why would I need 2? There I did it, no crashes, screw java :P
    There's also a Mozilla Default plugin listed there, why does firefox list it there without any further information whether I need it or not or whether it really originates from Mozilla firefox? It doesn't even show up when I use your website plugin checker, so is there no easy way by watching this list for me to determin I can skip worrying about it?
    There's also some old ones that I recently deactivated still listed like windows live photo gallery, never remember adding that one either or needing it for anything and as usual, right-clicking and "visit homepage" is greyed out, just as it is for the many java crap add-ons I encountered so far.
    Doing a quick check, the only homepage I can visit is the veetle one. The rest are greyed out. I also have several "Java Console" in my extentions tab, I deactivated all but the one with the highest number. Still no Java Console visible though, even after going to start/search "java", clicking java file and changing the settings there to "show" console instead of "hide" (can't remember exact details).
    There's some other extentions from noscript, TVU webplayer again, ADblock Plus and now also BetterPrivacy (sidenote, a default.LSO remains after cleanup correct? How do I know that one isn't doing anything nasty if it's code has been changed or is being changed? To prevent other LSO's I need to use both private browsing and change all kinds of restrictions online for adobe flashplayer, can anyone say absurd!!! if you think you're infected and want to improve your security? Sorry that rant was against Adobe, but it's really against Anonymous, no offense).

  • Parsing XML and Storing values in instance variable

    hi,
    i'm new to XML.
    here i'm trying to parse an XML and store their element data to the instance variable.
    in my main method i'm tried to print the instance variable. but it shows "" (ie it print nothing ).
    i know the reason, its becas of the the endElement() event generated and it invokes the characters() and assigns "" to the instance variable.
    my main perspective is to store the element data in instance variable.
    thanks in advance.
    praks
    import java.io.*;
    import java.net.*;
    import java.util.*;
    import javax.xml.parsers.*;
    import org.xml.sax.*;
    import org.xml.sax.helpers.*;
    public class mysax extends DefaultHandler
         String ctelement;
         CharArrayWriter contents;
         String vname1,vrcbreg1,vaddress1,vcountry1,vtelephone1,vfax1;
         String vname,vrcbreg,vaddress,vcountry,vtelephone,vfax;
         public mysax()
              vname1 = null;
              vrcbreg1 = null;
              vaddress1 = null;
              vcountry1 = null;
              vtelephone1 = null;
              vfax1 = null;
              contents= new CharArrayWriter();
         public void doparse(String url) throws Exception
              SAXParserFactory spf = SAXParserFactory.newInstance();
    SAXParser sp = spf.newSAXParser();
    ParserAdapter pa = new ParserAdapter(sp.getParser());
    pa.setContentHandler(this);
    pa.parse(url);          
         public void startElement(String namespace,String localName,String qName,Attributes atts)
              ctelement = localName;     
         public void endElement(String uri,String localName,String qName) throws SAXException
         public void characters(char[] ch,int start, int length) throws SAXException
              try
                   if(ctelement.equals("name"))
                        vname = new String (ch,start,length);
                        System.out.println("The method "+vname1);
              }catch (Exception e)
                   System.out.println("The exception "+e);
         public static void main(String args[])
              try
              mysax ms = new mysax();
              ms.doparse(args[0]);
              System.out.println("the contents name "+ms.vname1);
              catch(Exception e)
                   System.out.println("this is exception at main" +e);
    my XML looks like
    <coyprofile_result>
    <company>     
    <name>abcTech</name>
    <rcbreg>123456789</rcbreg>
    <address>Singapore</address>
    <country>sg</country>
    <telephone>123456</telephone>
    <fax>123155</fax>
    </company>
    </coyprofile_result>

    I believe that the problem has to do with the value you assign to ctelement. You are assigning the value of localName to ctElement, however for the element: <name>...</name> the localname is empty string i.e. "", but qName equals "name". Because you are assigning empty string to ctElement, when you do the comparison in characters of ctElement to "name" it will always be false. So in startElement change it to ctElement = qName; Try it and see if it works. I have produced similar programs and it works for me.
    Hope this helps.

  • New to XML and Oracle

    Just trying to clarify some issues as I try and learn about XML, and specifically how it integrates into the DB.
    1 - Is there a way with Oracle tools for me to get an XSD of an existing 9i relational schema? We are not currently using the XML DB, but our middleware developers would like to have an up to date XSD to use for their internal mapping.
    2 - Is there any way that I can keep that XSD up-to-date automatically, so I get a new one whenever the schema gets updated?
    3 - If I wanted to investigate storing XML docs within the DB in native XML format, I need to have an XML DB, correct? Is this DB construct maintained seperatelly from my "normal" relational schema? or are they kept in sync by Oracle?
    I know these may all be real basic questions, but as I said, I'm new to XML and Oracle. I am reading as much as I can, but there are a lot of docs out there.
    Thanks,
    Mike

    Hi
    1. On my opinion such a tool doesn't exists. Some parts can be implemented elsewhere, but not as described by you... e.g. with XSU if you specify the parameter "withschema" the XSD of the executed statement is generated. Another example is to use DBMS_METADATA to dump the data dictionary in XML (but not XSD, of course you could write your own XSLT to do this transformation...).
    2. -
    3. If you use XSD-based tables the XSD and the relational model are stored separately in the data dictionary. Therefore if you change the XSD you have to drop/create the XSD-based table... no schema evolution yet.
    Chris

  • How to set buildID.xml and custom.properties in SDK

    Hello,
    I just completed a new build deployment of SAP ME5.2, because after I deployed the new version, I don't think I have set a
    correct version number.Can you someone give me a sample how to set the buildID.xml and custom.properties? I am a new on the SAP ME5.2
    The Base version is ME_Base_5.2.5.16.5_netweaver-71_Update.zip and
    MEClient_Base_5.2.5.16.5_netweaver-71_Update.zip. the HB customzation
    version is ME_xxxxxx_2.0.0.0.x_netweaver-71.
    Within the sap note 1484551, you mentioned we need change the
    SDKInstallDir/build/buildID.xml file, here is the context of the file:
    buildID.xml -
    <?xml version="1.0" encoding="UTF-8"?>
    <buildID xmlns:xs="http://www.w3.org/2001/XMLSchema">
    <customer>XXXXXX</customer>
    <revision>1.0.0.0</revision>
    <build>1</build>
    </buildID>
    buildID.xml -
    1. how can we change the revision and build?
    There is another file BuildToolDir/build/script/custom.properties, here
    is the file context:
    custom.properties----
    This file contains build properties used to configure the build
    system.
    The name of the software vendor implementing the customizations.
    vendor.name=xxxxxxxxx
    Vendor build identifier. This value is used to uniquely identify
    customizations built by a particular vendor for a particular customer
    and base
    application version.
    This is also used in path locations and in naming certain build
    artifacts, like the custom EJB module and the utility classes archive.
    vendor.id=xxxxxxxxx
    The installation of the J2EE engine installed in the development
    environment.
    ex. C:/usr/sap/CE1\J00
    j2ee.instance.dir=J2EEInstanceDir
    The web context path used to access the main web application. This
    is used by the build to set the
    context-root value in application.xml after an update has been
    imported.
    web.context.path=
    The web context path used to access the production XML interface web
    application. This is used by the build to set the
    context-root value in application.xml after an update has been
    imported.
    xml.context.path=
    The web context path to access resources from the web extension
    application, like images and work instruction HTML files.
    web-ext.context.path=web-ext
    The target database vendor. Valid values are 'oracle' or 'sqlserver'.db.vendor=ORACLE
    The JDBC driver configured for the application server.
    db.drivername=VMJDBC
    JDBC connection propertes for the WIP (Work In Process) database.
    This is the primary application database.
    db.wip.driverclassname=
    db.wip.driver.url=
    db.wip.host=
    db.wip.port=
    db.wip.sid=
    db.wip.user=
    db.wip.password=
    JDBC connection propertes for the ODS (Open Data Store) database.
    This is the offline reporting and archiving database.
    db.ods.driverclassname=
    db.ods.driver.url=
    db.ods.host=
    db.ods.port=
    db.ods.sid=
    db.ods.user=
    db.ods.password=
    Flag indicating whether to add DPMO NC codes to NC idat files when a
    new update is imported. This value is initially
    set by the installer according the the user selection.
    dpmo.nc.codes=
    The default locale used by the production system. The default locale
    is the locale used to display locale
    specific text and messages when the requested locale is not
    available. This property does not need to
    be set if the default locale is english.
    default.locale=en
    Used when running the build from Eclipse to locate the java compiler
    used by the WebLogic EJB compiler.
    jdk.home=C:/Program Files/Java/jdk1.5.0_20
    Compiler debug mode. If set to 'true', debug symbols will be
    compiled into the byte code.
    compile.debug=true
    Keystore alias
    security.alias=xxxxx
    Keystore password
    security.storepass=ChangeIt
    Key password
    security.keypass=ChangeIt
    Keystore type (jks=default,jceks,pkcs12)
    security.storetype=jks
    Optional source control build identifier that is to be displayed with
    standard version information.
    scs.build.ID=
    Optional extended version information to be displayed with standard
    version information.
    ext.info=
    custom.properties----
    2. How can we change this here?
    Regards,
    Leon Lu
    Edited by: Leon Lu on Aug 4, 2011 11:14 AM
    Edited by: Leon Lu on Aug 4, 2011 11:21 AM

    Hi,
    I created one request with logo in the header an page in the footer etc. and called StyleSheet. After you can import this formats by each request.
    You can do this in compound layout.
    Regards,
    Stefan

  • How to extract data from xml and insert into Oracle table

    Hi,
    I have a large xml file. which will have hundreds of the following transaction tags having column names and there values.
    There is a table one of the schema with coulums "actualCostRate","billRate"....etc.
    I need to extract the values of these columns and insert into the table
    <Transaction actualCostRate="0" billRate="0" chargeable="1" clientID="NikuUK" chargeCode="LCOCD1" externalID="L-RESCODE_UK1-PROJ_UK_CNT_GBP-37289-8" importStatus="N" projectID="TESTPROJ" resourceID="admin" transactionDate="2002-02-12" transactionType="L" units="11" taskID="5017601" inputTypeCode="SALES" groupId="123" voucherNumber="ABCVDD" transactionClass="ABCD"/>
    <Transaction actualCostRate="0" billRate="0" chargeable="1" clientID="NikuEU" chargeCode="LCOCD1" externalID="L-RESCODE_US1-PROJ_EU_STD2-37291-4" importStatus="N" projectID="TESTPROJ" resourceID="admin" transactionDate="2002-02-04" transactionType="L" units="4" taskID="5017601" inputTypeCode="SALES" groupId="124" voucherNumber="EEE222" transactionClass="DEFG"/>

    Re: Insert from XML to relational table
    http://www.google.ae/search?hl=ar&q=extract+data+from+xml+and+insert+into+Oracle+table+&btnG=%D8%A8%D8%AD%D8%AB+Google&meta=

  • Override JNDI names in persistence.xml and @resource annotation

    I have a Java EE 7 application that I am developing for use with both GlassFish and WildFly, but I have discovered that both application servers use a slightly different format for specifying JNDI names.
    In GlassFish the persistence.xml file references the data source jdbc/myDataSouce, but in WildFly the data source needs to be java:/jdbc/myDataSource.The same is also true for classes that are annotated with @Resource. In GlassFish the annotation for a class using JavaMail would be @Resource(name = "mail/myMailSession"), but to deploy onto WildFly this would need to be @Resource(name = "java:mail/myMailSession").
    The only solution I've got at present is using Maven to create two different releases of the EAR file, with one EAR file containing a persistence.xml file with the data source jdbc/myDataSouce for use with GlassFish, and the second EAR file containing a persistence.xml file with the data source java:/jdbc/myDataSource for use with WildFly. Unfortunately, I haven't found a solution for the @Resource annotation.
    I've taken a look at the documentation for glassfish-application.xml and glassfish-ejb-jar.xml and have tried using resource-ref to override the JNDI names but the application fails to deploy due to an error in the name.
    My question is does GlassFish provide any capability to override the JNDI names specified in the persistence.xml file and classes with the @resource annotation?
    Many Thanks
    Paul

    Have you been able to solve this? I'm attempting to understand what Web Server 7 can do with regard to Java Persistence and what elements of it require Glassfish.
    I've also spent great amounts of time in WS6.1 trying to figure out why a JNDI resource couldn't be found. The rules of thumb I've learned are:
    - Try dropping the *'java:/comp/env/* prefix; just use jdbc/pact part
    - Make sure all referrences (in web.xml and sun-web.xml) are identical with regard to that name.
    I'm hoping you're not still dealing with this (it's been two months!) but if anybody else stumbles on this, maybe it'll help them.
    Dave

  • Stateless session Bean - xml and ejb-jar.xml file ???

    Dear Experts,
    Stateless-session bean
    For Creating an ear file
    we need ejb-jar.xml and weblogic-ejb-jar.xml files
    Is these files are already available
    or we have to type these files ??
    Advance Thanks
    Rengaraj.R

    My best advice: surrender to use an IDE.
    You wonder sometimes at how much productivity (read as 'time') could be wasted by doing something that could be done automatically. For a learning experience or a once only exercise is fine but as a routine thing, not worth it.
    Cheers

  • HT1660 When I install itunes, the xml and media folders are placed on desktop not in my music folder on Vista where I want them to be

    So I've installed and uninstalled itunes 3 times, using control panel to unintall everything, then ccleaner to make sure nothing is left over.  No ipod service and stuff left.
    Each time I install, the defult folder where the Media Folder, and album art folder plus all the xml and other files are put on my desk top. 
    Opening up Itunes, preferences, changed folder to user/music/itunes it doesn't work, keeps defaulting back to desktop.  Help please
    OS is Windows Vista

    Good to hear you got it fixed. A common reason for this issue is a problem with security permissions. This is another approach that may help in such cases.
    Repair Permissions
    Right-click on your main iTunes folder and click Properties,  then go to the Securitytab and click Advanced. Use the Change Permissions... button grant to your account (or the Users group) and SYSTEM full control of this folder, subfolders and files, then tick the option to Replace permissions entries... which will repair permissions throughout the library. When complete switch to the General tab, click in the Read-only check box to clear it, then click Apply.
    If you don't have the option to change the permissions then use the Owner tab and Edit... button to take ownership from an account with administrator privileges. Tick the option to Replace owner on subcontainers and objects.
    Repeat with the media folder if it isn't stored inside the main iTunes folder.
    tt2

  • XML and Oracle 8i Lite

    Hi Wizards
    I'm in an endeavour to do the following things -
    1.Generate XML output from Oracle 8i Lite database
    2.Modify the XML and update the database taking the modified XML.
    My java platform is JDK 1.2. I've used the XML SQL Utility for Java, and in doing so i've been successful with the 1st step. I've used the Oracle 8.1.6SDK JDBC Driver which is compatible with JDK 2.The code fragment is like the following -
    import java.io.*;
    import java.sql.*;
    import java.math.*;
    import oracle.xml.sql.query.*;
    import oracle.jdbc.*;
    import oracle.jdbc.driver.*;
    public class orasql1
    public static void main(String args[]) throws SQLException
    Connection conn = null;
    String tabName = "emp";
    try {
    Class.forName("oracle.lite.poljdbc.POLJDBCDriver");
    conn = DriverManager.getConnection("jdbc:Polite:POlite", "SYSTEM", "manager");
    catch (Exception e) {
    System.out.println("Oracle Connection error\t:");
    System.out.println(e);
    System.exit(0);
    OracleXMLQuery qry = new OracleXMLQuery(conn, "select * from " + tabName);
    qry.setRowsetTag("SCHEMADOC_1");
    qry.setRowTag("EMPLOYEE");
    qry.setStyleSheet("emp.xsl");
    String xmlString = qry.getXMLString(true);
    conn.close();
    try {
    File output = new File("emp.xml");
    FileWriter xmlFile = new FileWriter(output);
    xmlFile.write(xmlString,0,xmlString.length());
    xmlFile.close();
    catch (Exception e) {
    System.out.println("Output file error\t:");
    System.out.println(e);
    System.exit(0);
    I am putting some sample code for step 2 in the following section -
    import oracle.xml.sql.dml.*;
    import java.sql.*;
    import oracle.jdbc.driver.*;
    import oracle.jdbc.*;
    import java.net.*;
    public class orasql2
    public static void main(String args[]) throws SQLException
    Connection conn = null;
    String tabName = "emp";
    String fileName = "emp.xml";
    try {
    Class.forName("oracle.lite.poljdbc.POLJDBCDriver");
    conn = DriverManager.getConnection("jdbc:Polite:POlite", "SYSTEM", "manager");
    catch (Exception e) {
    System.out.println("An error has occurred.");
    System.out.println("Please check your CLASSPATH variable..");
    System.out.println(e);
    System.exit(0);
    OracleXMLSave save = new OracleXMLSave(conn, tabName);
    URL url = save.createURL(fileName);
    save.setRowTag("SCHEMADOC_1");
    int rowCount = save.insertXML(url);
    System.out.println("Successfully inserted "+rowCount+" rows into "+tabName);
    conn.close();
    Compiling the above code is fine, no errors! But while running the application I get the error -
    Exception in thread "main" oracle.xml.sql.OracleXMLSQLException: java.lang.Class
    CastException: oracle.lite.poljdbc.OracleStatement
    at oracle.xml.sql.dml.OracleXMLSave.insertXML(OracleXMLSave.java:345)
    at oracle.xml.sql.dml.OracleXMLSave.insertXML(OracleXMLSave.java:248)
    at orasql2.main(orasql2.java:27)
    My question is whether this thing can be done at all using Oracle 8i Lite? If so then how?
    Waiting for ur advices.
    Biplab
    (An Indian, but at present in Houston, Texas)

    It looks like be a classpath issue. Would you check with the class name.

  • XML and XSD file to an internal table

    I had read a lot of thread  but i don't understand how to deal with xml/xsd in R3.
    I need someone that have a definite example for this escenary please.
    With OPEN DATASET took from the server XML and XSD file, and put it in two internal tables type string.
    What functions or method have to use, and how to use them, to charge the XML file in an internal table?
    This is an example of XML and XDS:
    XML
    AND CONTINUE
    Best Regards,

    I just tried to interpret your question, it was not obvious what you wanted.
    I guess what you mean is that you have defined (statically) a deep structure, and you want to decode the XML into it. That is called a transformation (transaction STRANS, statement CALL TRANSFORMATION). You have the choice between 2 transformation languages: XSLT and ST. Of course, it depends what release you are running.
    I advise you to play first with the ID transformation, to convert an ABAP deep structured data object into XML, so that you see what XML is generated, this one is called asXML. If you create your own transformation, when you call it, it will first convert automatically the data object to asXML, and the transformation has to do the rest of the job.
    You can do the opposite, i.e. converting from XML to a data object, according to the same principle (intermediate asXML).
    Well, there are lots of things to say, I recommend you to read articles and documentation on XSLT and ST (search on SDN).
    About XSD, it won't help (and I did never see any possibility to use it) to decode the XML, as you must anyway define the target data object statically (and there's no tool to generate the ABAP code of the data object definition from the XSD).
    Note that you may also use iXML libraries to parse the XML.
    Please tell us more.
    BR
    Sandra

Maybe you are looking for

  • Need links to open in different window

    Please forgive my outrageous ignorance with respect to webpage design/development and especially Dreamweaver CS3. I created a very basic website in Microsoft Office Publisher 2003 and I have it up and running (www.ftembroidery.com). It is my very fir

  • Netboot Problem

    Hello, I'm sending the following command in order to netboot across subnets to use DeployStudio. sudo bless --netboot --booter tftp://10.10.129.57/NetBoot/NetBootSP0/DeansTest.nbi/i386/booter --kernel tftp://10.10.129.57/NetBoot/NetBootSP0/DeansTest.

  • Changing pixel aspect ratio during cropping (LR3.2)

    When I crop sometimes the pixel aspect ratio changes here. I.e. the pic get stretched in horizontal or vertical way/or compressed. Any body seeing this also? After some time it does change to normal, but it makes cropping rather difficult when in a h

  • Service Po with different currencies

    Hi Experts, As per the requirement i want to do the Service PO. The scenario of the service PO is the each item in the service must be of the different type of the currency. For Ex 1) the service type is Contract of a building. in which it consists o

  • Why does my text and emails shrink every time I slide my finger to the left on my HP laptop?

    I can't figure out why this is happening or what I'm doing when it happens. I don't know if it is a quirk of my HP laptop touch pad, or of Firefox (latest version is installed) or that it is due to me using Windows 7. Can anyone please help me?