Question

J'essaie de compiler gui / flex / songs.mxml dans la quatrième édition du livre Thinking in Java de Bruce Eckel et j'obtiens une erreur de compilation avec Flex 3.4. .

Voici une version simplifiée de l'exemple qui donne la même erreur:

<?xml version="1.0" encoding="utf-8"?>
<mx:Application
  xmlns:mx="http://www.adobe.com/2006/mxml"
  backgroundColor="#B9CAD2">
    <mx:MediaPlayback id="songPlayer"
      contentPath=""
      mediaType="MP3"
      height="70"
      width="230"
      controllerPolicy="on"
      autoPlay="false"
      visible="false" />
</mx:Application>

Voici l'invocation et l'erreur:

>mxmlc.exe songs.mxml
Loading configuration file C:\javaTools\flex_sdk_3.4\frameworks\flex-config.xml
C:\songs.mxml(5): 
Error: Could not resolve <mx:MediaPlayback> to a component implementation.

        <mx:MediaPlayback id="songPlayer"

Qu'est-ce que je fais mal ici?

Était-ce utile?

La solution

Ce composant n’est plus disponible dans flex, je crois depuis flex 3.0. Un composant d’affichage vidéo est intégré, mais vous devez configurer les contrôles correspondants. Si vous voulez un composant prédéfini plus complet, vous devez en importer un à partir de Flash. Voici un bon tutoriel d’adobe sur la marche à suivre - http: // www. adobe.com/devnet/flex/articles/video_flex.html

Licencié sous: CC-BY-SA avec attribution
Non affilié à StackOverflow
scroll top