Soucis de débutant en flex
Bonjour, j'ai quelques soucis sur un HTTPS que je ne comprends pas.
Je souhaite créer une petite application web "roadmap", et j'ai besoin de charger une liste de service dans une combo box.
J'ai deux composants, le premier "roadmap" où se trouve un bouton pour accéder au deuxième composant "addService".
Ma combobox se trouve dans addService et le XML que je souhaite y charger a cette forme là :
Code:
1 2 3 4 5
| <services>
<name> Management </name>
<name> Production </name>
<name> Ressources Humaines </name>
</services> |
Voici le code mxml de addService :
Code:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36
| <?xml version="1.0" encoding="utf-8"?>
<mx:TitleWindow xmlns:mx="http://www.adobe.com/2006/mxml" height="500" initialize="initializeHandler(event)" width="500">
<mx:Script>
<![CDATA[
import mx.events.CloseEvent;
import mx.managers.PopUpManager;
private function closeHandler(event:CloseEvent):void{
PopUpManager.removePopUp(this);
}
private function initializeHandler(event:Event):void{
serviceNameService.send();
}
]]>
</mx:Script>
<mx:HTTPService id="serviceNameService" url="http://127.0.0.1/flex/serviceList.xml"/>
<mx:TabNavigator x="0" y="0" width="400" height="350">
<mx:Canvas label="Ajouter une tâche" width="100%" height="100%">
<mx:Label x="10" y="10" text="Service :"/>
<mx:ComboBox id="service" dataProvider="{serviceNameService.lastResult.services.name}" x="123" y="5.5" width="157" height="31"/>
<mx:Label x="10" y="36" text="Nom de la tâche :"/>
<mx:TextInput x="120" y="34"/>
<mx:DateField x="120" y="64"/>
<mx:Label x="10" y="66" text="Début :"/>
<mx:Label x="10" y="96" text="Fin :"/>
<mx:DateField x="120" y="94"/>
<mx:Label x="10" y="122" text="Description :"/>
<mx:TextArea x="120" y="121" width="254" height="93"/>
<mx:Button x="120" y="222" label="Créer une nouvelle tâche"/>
</mx:Canvas>
<mx:Canvas label="Services" width="100%" height="100%">
</mx:Canvas>
</mx:TabNavigator>
</mx:TitleWindow> |
Lorsque la fenêtre se charge j'ai une erreur :
Citation:
[RPC Fault faultString="Security error accessing url" faultCode="Channel.Security.Error" faultDetail="Destination: DefaultHTTP"]
at mx.rpc::AbstractInvoker/http://www.adobe.com/2006/flex/mx/internal::faultHandler()[C:\autobuild\3.2.0\frameworks\projects\rpc\src\mx\rpc\AbstractInvoker.as:220]
at mx.rpc::Responder/fault()[C:\autobuild\3.2.0\frameworks\projects\rpc\src\mx\rpc\Responder.as:53]
at mx.rpc::AsyncRequest/fault()[C:\autobuild\3.2.0\frameworks\projects\rpc\src\mx\rpc\AsyncRequest.as:103]
at DirectHTTPMessageResponder/securityErrorHandler()[C:\autobuild\3.2.0\frameworks\projects\rpc\src\mx\messaging\channels\DirectHTTPChannel.as:389]
at flash.events::EventDispatcher/dispatchEventFunction()
at flash.events::EventDispatcher/dispatchEvent()
at flash.net::URLLoader/redirectEvent()
Je suppose qu'il n'arrive pas à trouver le XML ?
Merci de m'aider, je tourne en rond depuis un bout de temps maintenant, et si je créer un nouveau projet avec juste la combo box, ca fonctionne bien... c'est lassant.
Bonne journée à vous !