We previously recommended Adobe's official video tutorial to learn flex. After all, it is in English and inconvenient. Later, I found that the flash Builder 4 Quick Start on the igrui forum is a Chinese language. It speaks very well and can be viewed together with Adobe's official video tutorials for a better understanding.
However, on the P73 page of this tutorial, there is a problem with the example of developing a custom player component using mxml, and errors such as "videoelement cannot be parsed as a component" may occur. After verification, the special correction is as follows:
1. In the example, there are about 5th rows of customplayer. mxml under the customplayer project and about 4th rows of customplayer. mxml under the customplayersample project:
Xmlns: MX = "Library: // ns.adobe.com/flex/halo" should be changed:
Xmlns: MX = "Library: // ns.adobe.com/flex/mx"
2. About 50th lines of customplayer. mxml under the customplayersample project:
Selectionchanged = "Play (event);" in <s: List> should be changed:
Change = "Play (event );"
3. About 6th lines of customplayer. mxml under the customplayer project:
Here, you need to download two files: audio. As and audioevent. As, and then paste them into the project,
Then xmlns: rojored = "com. rojored. View. Controls. *" should be changed:
Xmlns: rojored = "../COM. rojored. Controls .*"
4. About 163rd lines of customplayer. mxml under the customplayer project:
<Rojored: audio id = "audio"/>:
<Local: audio id = "audio"/>
In addition, add the following statement after the creationcomplete = "Init ();" in line 8th:
Xmlns: Local = "*">
5. About 170th lines of customplayer. mxml under the customplayer project:
<S: videoelement id = "video" should be changed:
<S: videoplayer id = "video"
In addition, around 141 rows:
Playobject is videoelement should be modified:
Playobject is videoplayer
6. About 217th lines of customplayer. mxml under the customplayer project:
Valueinterval = "0" should be changed:
Snapinterval = "0"
References:
(1) code correction that the customplayersample example cannot be compiled in "Flash Builder 4 Chinese Quick Start!
(2) Why can't videoelement be parsed as a component ??
(3) One of flex4 Study Notes
(4) Audio class of rojored
(5) rojored aggregator documentation