Flex :: Possible To Include Example Mxml In ASDoc?
Mar 25, 2011Is it possible with ASDoc to include example MXML code in your comment?[code]
View 2 RepliesIs it possible with ASDoc to include example MXML code in your comment?[code]
View 2 RepliesI have an MXML component that includes a .as file with
<fx:Script source="myfile.as" />
Running asdoc throws a whole bunch of errors like
"Error: The private attribute may be used only on class property definitions."
"Error: The public attribute can only be used inside a package."
Solution 1 is to move the AS code into the MXML file. Kind of defeats the objective of using external .as files for MXML components in the first place, so really a last resort option. Code inside a mxml file is messy (I really don't want logic mixed in with mxml), and would also require using the < !--- ---> asdoc syntax.
Solution 2 is to have the MXML component inherit from a normal class file. That would mean no private members in the base class, only internal (meaning a separate package for the component to be safe) or protected. This would make things tedious to say the least.
Are there any other work-arounds or possibly a beta/nightly version of asdoc that fixes the problem? I am using the Flex 4.1.0.16076 SDK, the "latest production quality release".
Update:Just tried using asdoc from the svn trunk, (4.5.0 rev. 16942) and the problem persists.
I would like to include an MXML file in my MXML file in the same way you can include an external file in AS3 using the include directive. Using the include directive brings the code from the external file into the original file at compile time placing it in the same scope. For example,
Application.mxml:
<Application>
<source="external.mxml"/>
[code].......
Does MXML get compiled down to as3 and then converted to flash bytecode? Also, is there a significant performance penalty to compiling mxml vs compiling as3?
View 3 RepliesI am working on a custom Flex 4 component which is an aggregation of two existing flex components. I would like to be able to specify my own custom properties for the component as well as access the existing public subcomponent properties via MXML. For instance I might want to adjust the font color or style for the label and text input. toy component which aggregates both a label and a text input:
<?xml version="1.0" encoding="utf-8"?>
<s:Group xmlns:fx="http://ns.adobe.com/mxml/2009"
xmlns:s="library://ns.adobe.com/flex/spark"
[code]....
I am trying to override a Button class, i have a few properties which i wish directly initialise with the mxml description of the component, like :[code]which function is triggered ( in order to override it ) when all properties with mxml description is fully initialised with their values ?
View 1 RepliesMy operation system is Window XP in Chinese. I'm running flex sdk > asdoc in command line. Asdoc picks up the system default language. How can I force it to be run in English language environment?
View 1 RepliesHow do you add sample xml to asdoc function/class comments in Flex? They can obviously be added, but they wont show in the hover asdoc comments in Flash Builder 4. [code]...
View 1 RepliesI have a canvas based component, so when I check the asdoc comments, they have inherited comments of Canvas. can we remove that inherited comments, and add our own AsDoc comments..
View 1 RepliesWhat I'd like to do: create an MXML component with some children, then extend it via MXML to create a new component with more children, without losing the original set.In other words
create a component bc.mxml
<?xml version="1.0" encoding="utf-8"?>
<s:BorderContainer xmlns:fx="http://ns.adobe.com/mxml/2009"
[code].....
i have defined some functions in a component mxml file let us say addbutton() now i want to call this function in main mxml file.
View 2 RepliesCan ASDoc be set to document private members ala JavaDoc?
View 1 RepliesI want to add a comment to some elements in a Flex document, and process the comments using ASDoc. I can easily do this for the script portion, but I end up with a ton of ugly "This property can be used as the source for data binding." messages for each element I declared in Flex. Is there any way to embed a comment into a flex element so that it can be read by ASDoc? I have tried using the standard
<!-- -->
notation, but that didn't seem to work.
EDIT: The notation seems to be swallowed up as an HTML comment..
As the title says - is it possible to document my ActionScript packages / namespaces using the ASDoc comments and the included asdoc command line tool?
View 1 Repliesmain.mxml
[Bindable]
private var _dp:ArrayCollection = new ArrayCollection([
[code].....
cannot get the comments to show in actionscript file when running asdoc.. is this a known bug?
[Bindable]
/** test comment */
public var currentSearchTextValue:String;
does not show anything in the generated documentation.
A Flex components values are initlized by init methord. In an application flow, How to refresh a mxml component data value ; as init is callled at the start up it self only.
eg. of mxml componet may be as simple as button label or text as complex as repeater whose data provider is a web service ( means a fresh quesy should be made to pull the data and refresh the dataprovider of repeater )
suppose i have 3 buttons(for example say, productin, marketing, sales ) on my main.mxml..once i click on one button it should take me to abc.mxml page with production data, once again if i click on second button it should take me to the same abc.mxml but with marketing data. same as for 3rd button also, how can i achieve this ?
View 2 RepliesI've been trying to create a custom mxml component that extends another custom mxml component (i.e.MyMXMLComponent -> BaseMXMLComponent -> Group). I've been reading that trying to add visual children to MyMXMLComponent caused error with Flex 3 but that's no longer the case with Flex 4.
What I want to know is whether this is a supported/fixed/documented feature of Flex 4? or just some undefined behavior in Flex 4 that may get changed with future updates?
if this is supported and documented feature, does anyone have link pointing to adobe document stating it as such?
This is a project I'm working on for a simple demo tutorial application in Flex. I am using mxml pages. You can see to the left that I will have my main application and then other mxml files (In the Examples Package) as the examples that will be loaded into the main application mxml. How can I dynamically pull the value from the object in the list to load the child mxml file into the container that I have further down in the application?
View 1 RepliesI saw it in this site...[URL].. it says "Include code from external sources using #include".umm... does it mean I can use C code, etc. within flash??
View 1 RepliesI saw it in this site...[URL]it says "Include code from external sources using #include".does it mean I can use C code, etc. within flash?
View 1 RepliesI have a method in CustomPanel.mxml and I need to use id which is available in Main.mxml. Below is my sample code
Main.mxml
<local:CustomDivideBox id="div1">
Custompanel.mxml[code]....
I want the comboBox to be placed in one of the columns of the datagrid header.The datagrid should be filtered according to the value selected in the comboBox.e.
View 1 RepliesI am looking to subclass RemoteObject. Instead of:
<mx:RemoteObject ... >
<mx:method ... />
<mx:method ... />
[code].....
I wanna creating a flex application. In that application left, down and right side will be same all pages but on center screen will be changed in order to click event. Is that possible? When i click button on the center screen, center screen will show another MXML (call another MXML but left, right and down side will be same). How can i do that?
View 1 RepliesI currently have a Flex project that was done in Eclipse, using the following compiler settings:
Flex Build Path: (Source Path) includes source folders from other areas, i.e common_components, which aren't projects on their own but just folders with various code I need to share. This works fine but I want to migrate to using ant. I have read in places on how to include libraries, via compiler.include-libraries, but as this isn't a library but rather just bunch of folders with .as and MXML files, how do I accomplish this?
I'm working on a general code library for ActionScript 3.0 called as3lib which includes several extensions to the core API and some useful functions. I've written several unit tests (using FlexUnit) to make sure everything is working correctly.
What is the best way to organize these tests in the library? Currently, I have all my code in src/ and my tests in test/ but I've set up a secondary Flex project to run the unit tests. I am also manually adding and removing the test files from the library when I want to run the tests.
Preferably one where the compiled library doesn't include the test files but I don't need two separate projects to test them.
In the simplest of Flex Projects, create an MXML Flex Module and then load it using the ModuleManager.Create an ActionScript class that extends Module and then configure your project to compile that into a Module.Load this new module instead. The project compiles, but crashes when running with the following error:"Error: Could not find compiled resource bundle 'containers' for locale 'en_US'."I believe the compiler is failing to compile the required class definitions into ActionScript only module, while it succeeds for the MXML module.I can see that my skeleton MXML module is slightly larger than my ActionScript module (66KB vs. 45KB).
View 3 RepliesI created flex application that loads a image. I compiled this app and ran in the computer where it was created. it works. when i try in a different system, the image does not load. I think it's chekcing for the image path.how to include image as part of the application
View 2 Replies