Harish Sivaramakrishnan

on technology, music & life.

Archive for the ‘flex’ Category

Will be talking at Great Indian Developer Summit

leave a comment

I, along with Ramesh will be talking at the Great Indian Developer Summit ’08 from May 19-23 at Bangalore. We will be giving a focused session of Flex, AIR and other platform technologies of Adobe. We are also going to have a demo stall running through the 5 days and also plan to have the team to be present there. If you are going to be there, do drop in to the Adobe stall. I am going to be there all the five days and also hoping to meet many of the RIA developers.

The summit also will feature  Yakov Fain from Farata systems talking about building enterprise applications using Flex and Mike Grushin will be talking about developing flex applications over Microsoft technology stack. Ram and Rupesh from Adobe will be talking about Adobe ColdFusion and Adobe Java technologies in the Java thread of the summit. This is certainly something you don’t want to miss!

Raghu and I will be in Bangalore BarCamp 6 [BCB6] as well (19-20 April ’08) If you want to catch up on any flex / AIR / Adobe platform related stuff, catch hold of me at the venue or drop me a mail at hsivaram [at] adobe [dot] com or call me at +91 9980338894. Will be delighted to meet you. :) See you in BCB6 and (or) GIDS.

Written by harish

April 15th, 2008 at 8:22 am

Adobe RIA Architect Summit '08 Rocked! Thanks one and all!!

4 comments

Wooah! What a day it was!! The summit totally rocked! It was the culmination of weeks of planning, re-planning efforts and also the result of some incredible execution. Mind you, this was organized by the engineering team and we had no event management support whatsoever. Okay – back to how the event went.

I landed up at the venue around 7 AM (man! thats early!) and I already had butterflies in my stomach as I was to be the MC of the event. I have done it few times before but not for a corporate event like this. Coming from an engineering background and being used to make a living writing code, this was an exciting challenge for me. It was incredible to see the folks had already set up the registration desks. The stage looked fantastic and the scene was set for a great event that followed.

The delegates started walking in at 8:30 around and we had a full house around 9:15. The event started at 9:30 AM and we had Ananth, Director of Flex & cold fusion engineering address the crowd with the welcome note. This was followed by a key note session from Naresh Gupta, MD, India R&D center, Adobe talk about the past present and future of RIAs. Naresh’s presentation covered the entire spectrum of how applications evolved through the years.

Then came David Wadhwani – GM & VP of the platform business unit at Adobe. David spoke about Adobe’s platform strategy and how adobe technologies will revolutionize the RIA world in the years to come, just the way it has been all this while! The AIR demos from David’s session kept the audience captivated and I could literally see jaws dropping when the thermo preview video was played. The session rocked and the loud applause testified it!

Ben Forta (Dir Evangelism) came, spoke and he conquered! Ben dint have a PPT at all!! He built applications (not one, but three) Ben’s presentation was racy, super cool and the crowd just loved it! Ben’s fans in this part of the world got a chance to click a few pictures of his, which he graciously obliged.

James ward did a fantastic session on connecting back ends with Flex applications. I was amazed by the speed at which James wrote those applications. The crowd loved his session and James was patient to answer many many questions that folks asked. I did a lot of socializing with the delegates during the lunch time and also managed to shoot some prospective 30 on air videos as well.

The afternoon sessions started with customer showcases from Ivy Comptech, Borland, Business Objects, Instacoll and Cognizant. It was great to see our customers talk about how our technology helped them build successful businesses. James came back and did the session on RIA best practices. This session had an even longer Q & A and James once again was kind enough to answer them all. The “getting the ACT together” session followed, where we had Mr Neil – professor at KMIT talk about the importance of academia in RIA training. Mrinal spoke about the community activities and Himanshu Modi of techpoint multimedia spoke about training.

The last session for the day was AIRkitectur by Sunil and Raghu which also had a mini skit which kept the crowd entertained. We also had a lot of folks getting their Flex 2.0 books autographed by James and many folks getting their pics clicked along with Ben and James. Meet the Flex team and customer stall showcases followed and it was around 7:30 when the summit closed.

Overall, it was a great day and it was fantastic to have James, Ben and David join us for this event. And not to forget the great audience without which this event could have never been such a great success!

Written by harish

April 9th, 2008 at 10:18 am

Posted in flex,rant

Adobe RIA Architect Summit 2008

leave a comment

It’s summit time again folks ! You might recollect the RIA Leadership Summit that happened when Shantanu was in Bangalore, which saw industry leaders from various IT Companies from across India attended the talk about Adobe’s vision and plans for the Rich Internet Application space. Since then, the India RIA scene has been more dynamic than ever and there has been an increasing demand for insights into architecture & design principles around RIAs. As an acknowledgment to this Adobe brings “The RIA Architect Summit“.

What is in it for me?:

  • Hear Naresh Gupta (MD, Adobe India), David Wadhwani (VP, Platform BU, Adobe) share the exciting future of RIAs using Flex & AIR
  • Meet acclaimed evangelists James Ward & Ben Forta
  • Hear about the success stories of leading IT Enterprises who have adopted Flex & AIR.
  • Experience RIAs built on Adobe platforms and hear from the teams that built them

Who should attend ? :

Architects, Technical Managers and Strategic Decision Makers

When & Where? :

Date : 03 April ‘08

Venue : The Chancery Pavillion, Bangalore

How do I get in?: 

Register ASAP at http://adoberiarch.eventbrite.com/

Hurry! Registrations on a First Come First Serve basis…

Written by harish

March 14th, 2008 at 1:53 pm

Posted in flex

Flex Engineer –> Evangelist (Platform Products)

leave a comment

After almost 3 years working with the Flex Engineering team (and a brief stint with the Adobe Media Player team) I have accepted a  new role as an Evangelist for the platform products of Adobe (Flex , AIR …) It has been  incredible working in the Flex engineering team, and I am going to sorely miss being there! But on the upside, It is going to be exciting times ahead as Flex / AIR is quite hot and happening in India and there is a lot of interest around Adobe technologies. My work will be predominantly India centric and I am looking forward to meeting folks in India working in Flex / AIR.

get in touch with me for your flex / AIR related queries, I will be delighted to assist – hsivaram [at] adobe [dot] com

Written by harish

March 11th, 2008 at 9:22 am

Posted in flex,Flex India,rant

Source code for TaskScheduler chart in Flex

70 comments

Update: Do check out the Flex 4 prototype of of the gantt chart here.

Wish you all a very happy new year! I have been incredibly busy through the last few months working on the Adobe media player and I am quite excited about the upcoming launch. Keep watching Adobe labs website for more info on the same. In the meanwhile I got several comments, mails and even angry remarks for not posting the source code of the gantt chart / task scheduler chart that I had posted here a few months back. Thanks for the interest shown, guys! I deeply apologize for the delay in posting the same as the code was *not at all* ready for public display :) However, I am posting the code with sample usage in AS-IS form for you to try out. I am still working on this and will post the final version later once I have some more free time.

In the meanwhile, go ahead and use the code and let me know if it works / helped you.

Download Source

Written by harish

January 29th, 2008 at 12:31 pm

Posted in components,flex

Where is flexgeek?

2 comments

Its been a long time since I posted anything here. I have been quite busy lately! I am working out of the Adobe San Jose office and doing some really exciting work on the Adobe Media Player engineering. Its a super-sexy application! Do test drive it when it becomes avaliable for dowload (watch Adobe Labs or this space for more info on the same!)

I have been getting quite a few mails and comments to add the code for the gantt chart and the task scheduler component. I will soon do that. Till then keep flexing your moxie and rock on!

Written by harish

September 21st, 2007 at 7:37 am

Posted in flex

Task Scheduler Chart using AdvancedDataGrid (moxie)

31 comments

Soure now available here!

Few days back I had posted an example of a Gantt chart component developed using the AdvancedDataGrid of moxie. I was playing around with the component for the horizontal scrolling performance analysis and finally ended up writing this small component.

This is a simple engineering work items display which shows the tasks for each engineering role with drill down capabilities. Double Clicking the quarter information column will drill down the data for that column (double click to collapse) . Clicking on the month info will get you the day-wise breakdown of the tasks. (double click the top column to collapse). I intend to develop this as a full fledged component once I am done with my current commitments at work. Watch out this space for more updates and also source code. For the time being, check out the application here.

download Download Source


Written by harish

June 28th, 2007 at 8:12 am

Posted in flex

Tips & Tricks : AdvancedDataGrid – grouping & summary rows

30 comments

This is the first among the series of articles that I intend to write about the new AdvancedDataGrid control of Flex 3.0 (moxie). You would require Flex 3 beta 1 to compile and run this example. If you dont have moxie yet, download it here

Displaying grouped (hierarchical) data & summary rows in AdvancedDataGrid

One of the key features of the new AdvancedDataGrid (will be referred to as ADG from hereafter) is its inbuilt capablility to display hierarchical data. This is made possible through the new set of collections classes that have been added. The following example helps you learn two things:

  • How to create a grouped data from the flat data that is supplied to ADG
  • Create summary rows based on the data.

Lets now look at the example :)

The example in this article has an ADG which display the quarterly revenue details of companies and the number of licences sold by each one of them stored as an XMLList. This XMLList is supplied as the dataProvider for the ADG. (This is all similar to what you would do in the DataGrid).


Now, Lets try and group this data based on the field quarter. Lets look at the code that will let us do that

//Make a grouping collection
var mygroup:GroupingCollection=new GroupingCollection();
//Set the source to the array collection (this case dataProvider)
mygroup.source = colgrouped_adg.dataProvider;
//Create a new grouping
var group:Grouping = new Grouping();
//Group on Quarter
var gf:GroupingField = new GroupingField(“Quarter”);
//Set the fields to the grouping
group.fields = [gf];
//Finally, Set the group to the grouping property of groupedCollection
mygroup.grouping = group;
//Refresh the group
mygroup.refresh();
//Set the dataProvider to the grouping collection
colgrouped_adg.dataProvider = mygroup
//Call validateNow() to redraw the dg.
colgrouped_adg.validateNow()

The steps are as follows:

  • create a grouping collection
  • set the source to a flat collection (this case the ADG DataProvider)
  • create an instance of grouping
  • create a grouping field and pass the field that you want the data to be grouped on
  • set the fields property of the grouping to the groupField
  • set the grouping property of the grouping collection to grouping instance
  • refresh the grouping collection
  • set the dataProvider of ADG to the grouping collection
  • call validateNow() on ADG to update the display


Now, Lets write some code to calculate the summary of the total number of licences sold by *ALL* companies. Here we go!

var sr:SummaryRow = new SummaryRow();
//Set the summaryObjectFunction
//This function tells ADG to add a summary row in addition to the existing data
sr.summaryObjectFunction = objFunc;
//Set the summary field. The field on which the summary will be calculated.
var sf:SummaryField = new SummaryField(“Licenses”);
//Summary Function – the function that calculates the summary row display
sf.summaryFunction = func;
//set the summary rows fields property to summaryField
sr.fields = [sf];
//Place the summary row (Last means data First, summary Last!)
sr.summaryPlacement = “last”;
//Group on Quarter
var gf:GroupingField = new GroupingField(“Quarter”);
//set the summary row(s) to groupingField
gf.summaries=[sr]

Thats fairly straight forward. Here are the steps you need to follow to get a summary row in your ADG.

  • Create a summary row instance
  • Set the summaryObjectFunction to include a summary in your ADG data
  • Create a summary field, the field on to which the summary calculation formula needs to be applied.
  • Write a summary function which contains the logic to calculate the summary
  • set the summaryField to the fields propety of summary row
  • Define summaryPlacement “First / Last” First will put summary before data, last will add it after the data
  • Finally set the summary rows to the groupingField.

The SummaryObjectFunction looks like this: (This method returns a SummaryObject)

private function objFunc():SummaryObject
{
var obj:SummaryObject = new SummaryObject();
obj.summary = true;
return obj;
}

Finally, the summary function. summaryFunction accepts 3 parameters (its a callback, you may never have to pass params to it, but be sure that you write the signature correctly) an iterator,a field and an operation. (operations include build-in methods like ADD).

private function func(itr:IViewCursor,field:String, str:String=null):Object
{
var sum:Number=0
while(!itr.afterLast)
{
//trace(itr.current)
var value:Number = Number(itr.current.Licenses);
if(!isNaN(value))
{
sum+= value
}
itr.moveNext()
}
return sum
}

Thats it! We are done and what we get will look like this :)

I have included the sample application as well as full source code for this example. Do take a look at it. I hope this one was useful for all those who are exploring the new ADG. Do look out for more tutorials on this topic.

Download Source

Do check out my Simple Gantt chart built on AdvancedDataGrid

Written by harish

June 14th, 2007 at 8:03 am

Simple GanttChart using AdvancedDataGrid of Flex 3.0 (Moxie)

61 comments

Update: Do check out the Flex 4 prototype of of the gantt chart here.

Flex 3.0 (Moxie) beta is out and I am sure most of you would have started playing around with the cool new features of Moxie. <mx:AdvancedDataGrid> is the new, improved DataGrid – a super cool component in moxie. Its a very exciting moment for me because I was part of the engineering team that designed and developed this control :) . I spent a few hours yesterday to see if I can use this control to write a simple Gantt chart, given the fact that the AdvancedDataGrid lets you have column spanned itemRenderers , groupedColumns and hierarchical display. I took a similar approach to what Doug had done in his example of a gantt chart.

This is what I got!! :)

ADG-Gantt sample

This is a rough prototype that I wrote and I sure dint spend much time designing this application. I will try and get this one as a component when I have a little more of free time.

Things I loved about AdvancedDataGrid doing this small app :)

  • AdvancedDataGrid Rocks!
  • The new groupingCollection APIs make hierarchical display of data Child’s play
  • The rendererProviders property and the column spanning lets you customize itemRenderers in a much advanced way than DataGrid
  • <mx:AdvancedDataGridColumnGroup> lets you group the columns seamlessly!

The horizontal scrolling is a little slow, but we are sure working on it to get it a lot faster than what it is now! (hey, its just a beta!)

You can download the source code from here.[Adobe Share] If you cant figure out much from the data, its just a timeline of set of tasks and their respective percentages. Red shows delayed. Orange shows delayed start, green shows timely completion, grey - not yet started and blue – in progress.

The code that I have written requires many rounds of cleaning up before I can share it publicly :p (I will do that soon!). In the meanwhile, do check this space for a new series of tips & tricks and tutorials on working with the new AdvancedDataGrid.

All of ya keep flexing your “moxie” till then!

Written by harish

June 13th, 2007 at 12:29 pm

Tips & Tricks – adding a combobox to a datagrid header as headerRenderer

16 comments

I am sure many of you would have tried dropping a ComboBox as a headerRenderer to a DataGrid. Well, if you try to directly drop in a ComboBox you will get an RTE and the ComboBox just doesn’t work! I got this request from one of the flex users here that they need to drop a ComboBox on a datagridcolumn to provide a UI for filtering the data in the datagrid.

After looking at the code for a while, I figured out that the set data method of the combobox checks if it is dropped in as an itemRenderer and what’s more, it sets the data irrespective of whether the value recieved in the set data is a datagrid column or not. In the case of dropping the ComboBox, the data setter sets the data to the DataGridColumn and when the program progresses it throws an RTE which says it couldnt find the property name on the headerRenderer instance.

The solution:

I subclassed the ComboBox control to make MyComboBox and wrote an override for the data Setter. I just added the following type check before the data setter in the super is called

if(value is DataGridColumn)
{
//do not call super; that is it!!
}
else
{
super.data = value
}

Thats pretty much it! The ComboBox will now correctly display in the header. I have written a simple example that has a ComboBox on the Datagrid column header which can be used to filter data. Note: I have turned off sortable columns and draggable columns in this example.

Disclaimer: This sample contains a small example of the concept, the application in itself has not been tested for bugs. People copy pasting the whole code and urged to exercise  Download Source

Written by harish

June 7th, 2007 at 12:07 pm

Posted in flex,tips & tricks