Flex - Error #1088 On Passing A Class As A Parameter For Web Service In Flash Builder
Feb 8, 2011
I need to pass a struct and a string in a web service. I am using a WebService components to do so.upon my search, there is no struct type in actionscript and so I used a class for that one.
public class UserInfo{
public var name:String;
public var dateAdded:Date;
}
and I'm filling it up so that I can pass it on the web service like this:
var newUser:UserInfo = new UserInfo();
newUser.name = "myName";
newUser.birthdate = new Date();
webServComponentId.operationToCall(newUser, "password");
Upon sending this request, it prompts me an error of Error #1088.
the component that is being called by webServComponentId.operationToCall(newUser, "password"); is this:
I'm doing a flex app in AS3.0 and I'm getting this error.
"TypeError: Error #1088: Il codice nel documento successivo all'elemento principale deve essere formato correttamente. at controls::FileUpload/onUploadDataHandler()"
That in english looks like: "the code in the document next to the main document has to be rightly formatted"
I am calling java servlets from flash using the following code [below is a sample Flash code for calling a java servlet in Flash which I am using]: String url_String="[URL]"; var req:URLRequest = new URLRequest(url_String);
In this case, the servlet is called/working fine only in my system where the flash application is deployed & not working when I execute the application in different system using the "IPAddress" of my system. So, What changes I need to make in above Flash code in order to call the same servlet successfully from my system and as well as from other systems? (OR)
Is there any need to pass the servlet-url's relative instead of absolute? If so, How can we pass relative-path of url's in Flash? && Can anyone explain me with an example? How to change my above code to pass the url 'relative' rather than 'absolute'? If I pass the url relatively, does my issue gets resolved?
I can't get the maxDisplayedLines to truncate the text at the end of my RichText object. It comes up with Error #2007 Paramater child must be non-null but I don't have a clue what would be null. The text I'm displaying is coming from textflow
and everything displays fine, even the thumbnails until I try to set the max lines. This is for mobile by the way.
the error is TypeError: Error #2007: Parameter child must be non-null. at flash.display::DisplayObjectContainer/addChild() at flashx.textLayout.factory::TextFlowTextLineFactory/callbackWithTextLines()[C:Vellumranchesv22.0devoutputopenSource extLayoutsrcflashx extLayoutfactoryTextFlowTextLineFactory.as:267]
I'm using the data/services in Flash Builder 4 to access the php functions of a site within an Air based Crud, and figuring out the most efficient ways to work with the data objects that come back.
[Code]...
The data comes back as an associative array, which is fine if I want everything from it to be treated the same. But I'm not sure how I am supposed to pull a particular column from the array without having to go through a for loop to parse through it.. since right now the contact name would be at allContacts[i].name.
Basically I want to make a list of the names from the allContacts, so I want an array of allContacts[i].name to set as the data provider for a element. Is there any way to get that done without having to write a for loop to convert it into a new array or writing a new php function?
I have been tinkering around with ServiceStack to expose some web services and have been very impressed. One potential consumer of these services will be a Flex application. Flash Builder (the Flex IDE) has a tool that auto-generates proxy AS3 classes for SOAP web services based on the wsdl - at this point in time only for SOAP 1.1.
If I recreate the HelloWorld tutorial, and try to use the SOAP 1.1 wsdl to autogenerate classes, I get the following errors in Flash Builder. There was an error during service introspection. The part 'parameters' has an invalid value 'HelloResponse' defined for its element. Element declarations must refer to valid values defined in a schema. The part 'parameters' has an invalid value 'Hello' defined for its element. Element declarations must refer to valid values defined in a schema. I am sure this is a problem with Flash Builder's tool. I am wondering if anyone has been successful in auto-generating AS3 classes from a ServiceStack wsdl?
I have a custom class being constructed from my main class. In the custom class it has another custom class that is passed in as a parameter. I would like to strictly type the parameter variable but when I do, 'the type is not a compile type constant etc'.This, I understand, is because the custom class used as a parameter has not yet been constructed.It all works when I use the variable type ( * ) to type the parameter.I suspect this is a design flaw, in that I am using an incorrect design pattern.It is actually hand-me-down code, having received a large project from someone else who is not entirely familiar with oop concepts and design patterns.
I have considered using a dummy constructor for the parametered class in my main class but the passed in class also takes a custom class (itself with a parametered constructor). I am considering using ... (rest) so that the custom classes' parameters are optional.Is there any other way to control the order of construction of classes? Would the rest variables work?edit)in main.as within the constructor or another function
var parameter1:customclass2; customclass1(parameter1); in customclass1 constructor:
I'm using a PHP script to read an RSS feed in my Flex 4 app. The script works when I put the URL of the feed in the actual script, but I can't get it to work when I try to send the URL as a parameter from a HTTPService in Flex. Can anyone tell me what I'm doing wrong? Here is the HTTPService from Flex 4 that I'm using:
I'm trying to use ASP.NET to retrieve data from the sql server, place in inside an xml and sends the xml to flash to display the data.
However, I'm getting
TypeError: Error #1088: The markup in the document following the root element must be well-formed. at news_fla::mainTimeline/loaded() at flash.events::EventDispatcher/dispatchEventFunction() at flash.events::EventDispatcher/dispatchEvent() at flash.net::URLLoader/onComplete()
[Code]...
it works. But i dont wan a .xml file residing in the server. so i hope that the .xml file would be cleared off as soon as the request is done. Did i do something wrong?PS: I don't know if i post this in the correct section but since it's related to AS3, thats why i post it here. sorry if i made a mistake.
I would like to use different service definitions in a Flex app depending on whether I'm running on:
My local developer machine The test tier The QA tier The production tier
My services are all AMFPHP remote objects, living on different hosts and at different locations depending on which tier I'm on. How can I have my flex app choose the 'correct' tier at runtime to connect to?
This is the response to my question/error I get, but I don't know how to implement it, It turns out that my issues were caused by having two instances of the same data service class in two different components that were used in the same page. If I changed the components to share the same instance of the data service, then everything works just fine. how to define a service in the main application or elsewhere which can be shared between components?
Is there some sort of configuration settings in FlashBuilder 4.5 where you can easily switch between webservice urls? Right now I have to delete and recreate the web service every time I switch from local to production and vice versa.
I need to call an HTTP service using Flex that has variable arguments. I'm using Flash Builder 4 (Gumbo) to create the service definition, but there's no UI for variable arguments, and the subclass of HTTPServiceWrapper that it creates doesn't seem to support it.
I'm trying to import a web service with the Flex builder feature (Data > Import Web Service). The process proceeds as expected and the classes are generated based on the web service description. The code is generated with compile errors in it though.There are 20 errors of 2 varieties. I've included a sample of the errors below.It looks like an error in the auto gen. The auto gen code is trying to dispatch an object of ArrayCollection type. As far I know that isn't possible. rror examples:
1067: Implicit coercion of a value of type net.responsys:ListTablesForCampaignResultEvent to an unrelated type flash.events:Event. Responsys/src/net/responsysResponsysWS57.as 1119: Access of possibly undefined property headers through a reference with static type
I'm trying to pass some properties to a component I've created in Flash Builder 4. In my example below I want to pass the "label" property to update the label property of the Button.
I have a SplitViewNavigator with two split views. In one of the views I have a list and in another one I have questions. User must solve the question and when user click send button, he will see another question.
But when user click to send button in one view, how can i know this in the other view? I'm a newbie in Flash Builder and I'm searching for this for hours.
I am trying to migrate a project from Flash Builder 4.0 to Flash Builder 4.5. After Flash Builder prompts me to choose my new SDK, I choose 4.5, Then I get the following error:" error "The required skin state 'disabledWithPrompt' is missing".
I experienced the following error when loading xml using AS3. All I did was to remove "</xml>" from my xml.
TypeError: Error #1088: The markup in the document following the root element must be well-formed. at toffees_fla::MainTimeline/onLoaded() at flash.events::EventDispatcher/dispatchEventFunction() at flash.events::EventDispatcher/dispatchEvent() at flash.net::URLLoader/onComplete()
This is my AS3 code: var xmlLoader:URLLoader = new URLLoader(); xmlLoader.addEventListener(Event.COMPLETE, onLoaded); var xmlData:XML; function onLoaded(e:Event):void { xmlData=new XML(e.target.data); trace(xmlData); [Code] .....
I am new to flex and SAP. I am designing a dashboard in flex. I have retrieved data from SAP query_view_data and I am able to show it in charts. However now I want to pass parameter to SAP web service to retrieve data between two dates. I am trying to this with the following code:
protected function adg1_creationCompleteHandler(event:FlexEvent):void { var IInfoprovider:String="0FIGL_O02";
I'm trying to connect to a very simple .NET WCF web service (created in .NET 4.0) within Flash Builder Burrito and the process hangs on "Introspecting the service". I get no errors -- it just hangs. The web service is on my local network, although not on my local machine.
I have an asp.net page where I get the user_id from who's logged in. Now I need to pass this user_id to a flex application that runs in an asp.net page as a .swf. How can I get this user_id in a variable in my flex application.Or what is the best way to get the user_id into flex.
var myXML:XML = new XML(); var myOtherXML:XML = <Greeting> Hi <Greeting> var myOtherXML2:XML = <Name> James <Name> myXML.appendChild(myOtherXML) //TypeError: Error #1088: The markup in the document following the root element must be well-formed.
I'm using flex 4 to build a program and I am getting this error on one module I call. Does this refer to the module document (.mxml) or the actually xml file the module it calling?
i have a problem about RDS and blazeds, when i use flash builder 4.5 to connect the server data, there is a rds error (403 or 404),but i can ping the http://10.25.129.151:8400/testdrive/test/" on Chrome or ie. So i don't know how to configure the rds in flash builder 4.5 or i will must configure others?
I have a main mxml file (flex4) and want to pass a parameter (user_name) to a component in a directory called components. When I run the program, the user_name is NOT being sent from the main to the component file. (Interestingly, if you make the component visible, you can see the parameter has been passed).
I have hacked much larger files down to get the following two files: Main <?xml version="1.0" encoding="utf-8"?> <s:Application xmlns:mx="library://ns.adobe.com/flex/mx" minWidth="955" minHeight="600" [Code] .....
I wrote an app using adobe flash builder that makes an http data service call to a website.
When I build and launch the app it loads in my browser (the address in the broswer is C:Userspath omyapp.html) and works perfectly. However, when I upload the app to my website or even launch it from outside the project build directory, the HTTP service call fails with the popup
Of course I googled this error and realized it may have something to do with a 'crossdomain.xml' in my web root directory. I tried this and it continued to fail. Below was my crossite domain file