Skip to main content
March 3, 2009
Question

error : Severity and Description Path Resource Location Creation Time Id

  • March 3, 2009
  • 66 replies
  • 11254 views

i have this error :
Severity and Description Path Resource Location Creation Time Id
invalid character or markup found in script block. Try surrounding your code with a CDATA block. essai/src essai.mxml Unknown 1236103965593 182


my source is attach code


Many thanks for your help , 


Lionceau,

    This topic has been closed for replies.

    66 replies

    Participating Frequently
    March 16, 2009
    Lionceau,
    what exactly are you meaning by "this"? The first step of a good design is to be able to write down in ordinary language what it is you are trying to do. Then some people like to turn it into pseudocode, ie a series of logical steps and tests that are needed to achieve the goals, then you can easily turn that into actual code. When you are experienced then you tend to jump over some of those steps, but at present in your case I think it would be good to be more rigorous and systematic about it.

    Now, I think in your case you are trying to select files from one computer by means of a Flex application, save them to a server, and then download them onto a second one. The first stage is easy and you have basically done that. The second stage needs some server-side code: if you can't use cocomo then you must write something in a server-side scripting language such as ASP, JSP, PHP etc to manage that. I wouldn't go too far with the third stage until yuo have solved the second.

    Richard
    March 15, 2009
    yes i understand , thank you for your help

    my teacher say " yes it is good but i don't want cocomo , i would like this but without server cocomo "

    how i make this ?

    Lionceau,
    Participating Frequently
    March 12, 2009
    Lionceau,
    To repeat... This has to do with XML namespaces. If you don't understand the principle, just accept it for the time being. You will find it useful as and when you start including your own components, or those you download from elsewhere. Your namespace directives tell the compiler where to start looking for definitions if it is not already aware of them.
    Richard
    March 11, 2009
    xmlns:mx=” http://www.adobe.com/2006/mxml”

    this don't exist
    Participating Frequently
    March 9, 2009
    Lionceau,
    you wrote "but what is callLater() ???? i don'tuse this ?"
    Check in the Flex documentation under UIComponent. It is essential under some circumstances.
    And "xmlns:mx=” http://www.adobe.com/2006/mxml” ...don't exist !!!!"
    This has to do with XML namespaces. If you don't understand the principle, just accept it for the time being. You will find it useful as and when you start including your own components, or those you download from elsewhere.
    Richard
    March 6, 2009
    what i do for this???? :
    file1.browseForOpen(”pick a file, any file”);
    file2.browseForOpen(”pick a file, any file”);

    Lionceau,
    March 6, 2009
    http://www.adobe.com/2006/mxml

    don't exist !!!!


    Lionceau,

    March 6, 2009
    i look ,

    The trick to fix it is to call the second browse operation via callLater() (if your class extends UIComponent) or a timer (if not).
    so to fix the below you would change “checkConfig() ;” in the function file1Selected() to : this.callLater(checkConfig);




    Then i must use : <mx:WindowedApplication xmlns:mx=” http://www.adobe.com/2006/mxml” layout=”absolute” width=”674″ height=”343″ creationComplete=”checkConfig()”>


    private function checkConfig():void
    {
    if(filePath1 == null)
    {
    var file1:File = new File();
    file1.addEventListener(Event.SELECT,file1Selected);
    file1.browseForOpen(”pick a file, any file”);
    return;
    }

    if(filePath2 == null)
    {
    var file2:File = new File();
    file2.addEventListener(Event.SELECT,file2Selected);
    file2.browseForOpen(”pick a file, any file”);
    return;
    }
    }
    and i use this for my 3 buttons(upload , download , delete ) : checkConfig();


    this.callLater(checkConfig);

    i do this ?
    but what is callLater() ???? i don'tuse this ?

    Lionceau,
    Participating Frequently
    March 6, 2009
    Lionceau,
    do a Google search on "adobe flex error 2041" and see what you get. The very first hit in my list was a blog entry at ifeedme.com which you may find helpful. You need to start using resources creatively rather than just run into a problem and shout for help...
    Richard
    March 6, 2009
    i have ths error : Unable to browse for files. Error #2041


    i see nothing for this error

    What do you think for this ?


    Lionceau,