mercredi 26 novembre 2008

htmlText in TextArea

It seems normal that when you pass "<" or ">" in an HTML component for rendering, you get something wrong, but the implementation of the mx:TextArea is quite weird! It stops all the rendering! Meaning, if you have this character in the first HTML line, all the rest of your page doesn't appears! (This was a bug in the NuggViewer => fixed now)

How to use AIR files without administrator rights?

Or, to reformulate the question:
  • How to put an AIR application on an USB key?
  • How to use an AIR application without having to put some things in the window registry?
  • How to use an AIR application without having to launch the AIR runtime installer?
What I did:
  • I use the AIR Debug Launcher (ADL) from the AIR SDK: "It allows you to test an AIR application without having to package and install it"
  • You can find it in the AIR SDK directory: Bin\adl.exe
  • Just drag and drop (or use command line) your "xxxx-app.xml" file (from your compiled directory) on the ADL application

dimanche 23 novembre 2008

Binding of all attributes of an XML node to a DataGrid

I've wanted to bind all attributes (name and value) to a datagrid (see previous post about NuggViewer and BSP attributes). I'm didn't find an easy way to do it, so I used two "label Functions" (one for the name and another for the value). So, it gives something like:
Data:
<page APPLNAME="ZHRHAP_BSP_CE" PAGEKEY="BODY.DO" PAGENAME="body.do" AUTHOR="PTG76743" CREATEDON="20080708" CHANGEDBY="PTG76743" CHANGEDON="20080708" IMPLCLASS="CL_BSP_HAP_DOCUMENT_COH2" GENDATE="20080708" GENTIME="121613" PAGETYPE="C" CHANGETIME="120955" BROWSER_CACHE="0 " SERVER_CACHE="0 " LAYOUTLANGU="E" VERSION="A" DEVCLASS="$TMP" LANGU="E" DESCRIPT="Body Controller"/>

Flex code:
<mx:DataGrid dataProvider="{LV_XmlBSP_Page.@*}">
<mx:columns>
<mx:DataGridColumn headerText="Name" labelFunction="Lbl_Fction_AttrName" />
<mx:DataGridColumn headerText="Attribute" labelFunction="Lbl_Fction_AttrValue" />
</mx:columns>
</mx:DataGrid>
//------------------------------------------------------------------------------------------------
// Label function to display value and name of XML attributes
//------------------------------------------------------------------------------------------------
private function Lbl_Fction_AttrName(obj_data:XML, obj_dataGridColumn:DataGridColumn):String
{
return obj_data.name();
}

private function Lbl_Fction_AttrValue(obj_data:XML, obj_dataGridColumn:DataGridColumn):String
{
return obj_data.toXMLString();
}

Nugg Viewer - BSP enhancement


I've added a tab in the BSP part of the NuggViewer application. This tab allows you to see all the attributes of the page.

Site enhancement

Concerning the blog, I've added a counter and an "entry" in Google Analytics. The counter comes from: Compteur.cc.

mardi 18 novembre 2008

Adobe and mobile plateforms

To read: adobe is going to attack the market of mobile platforms and linux 64!

dimanche 16 novembre 2008

About the development ...

As I told you, I love to test new things. About one year ago, Microsoft released XAML, a declarative language to code interface for .Net program. To test it, I needed to find a little project useful for me... Then I remember that I was not happy when I had to find in a saved code source some stuffs...Why? b/c the source code was in a nugg file, and even if XML is supposed to be human readable, it wasn't the case with this file! => I've found my project. After some week-ends playing with XAML, I begin to think that the .Net framework was too complex for building a simple application. In the same time, I was discovering the power of WebDynPro Abap and the beautiful implementation of the MVC design pattern. So, I begun to test different framework like ROR (Ruby On Rails), Zend (Php)... and finally Flex. I found the language and the framework I was looking for. Indeed, the ActionScript 3 has all the power of an OO language, but has also a wide range of useful libraries (XML, List…). Flex support a simple but powerful databinding on graphical components.