How to apply the Data Visualization license on command-line in Flex 3 !

February 20, 2008

In the last post, I talked about the various licensing changes in Flex 3 & FB3. I said that the way to create charting applications n Flex3, is to get a FB Pro license (as charting is not a separate product anymore) and enter the serial number in FB3 and then develop as usual. I also mentioned that the license.properties file has now been moved to a global location in Flex3from its usual “/frameworks” path in Flex 2.

Now, what if you are one of those IDE haters or prefer VI, EMACS, TextPad over any IDE then this causes a problem for you. You might have the FB Pro license number which includes the Charting & Data Visualization component license, but you might not have FB installed. Then the license.properties file does not exist and so you will get a Trial-Watermark on your chart as below, despite having the license key. This will not happen in Flex2, as the license.properties file resides in the SDK directory itself.

DV Watermark

The way to go, is to use the flex-config.xml file. flex-config.xml is the configuration file contains most of the default compiler settings for the application and component compilers. In Flex3, we have added a license tag, where you can specify the compiler option for your Flex serial number.

<licenses>
<license>
<product>flexbuilder3</product>
<serial-number>
your serial number here</serial-number>
</license>
</licenses>

So, the compiler will now pick up the options from the config file, even though license.properties file does not exist.

The good news for those who have FB installed and still want to use the command-line compiler is that the compiler also checks for the existence of the license.properties file, so you may not have to do the above steps and it would work as is for you without problems…

Update (04/23/2008):

The path to find the licence.properties file on various OS’s in the final Flex3 release is as below:

OS Location
Windows XP C:\Documents and Settings\All Users\Application Data\Adobe\Flex\license.properties
Windows Vista C:\ProgramData\Adobe\Flex\license.properties
Mac OSX /Library/Application Support/Adobe/Flex/license.properties
Linux ~/.adobe/Flex/license.properties

You can get more details on this article in the livedocs…


Changes in Flex 3 licensing model

February 19, 2008

There have been several changes from Flex2.0.1 to Flex 3. In this post, I’ll discuss about the packaging changes in Flex Builder(FB) and the changes in licensing for the product.

Packaging changes in Flex 3

In Flex 2, we had the following types of packaging…

  • Flex Builder 2
  • Flex Builder 2 with Charting
  • Flex Charting 2

    In Flex 3, it has become as below…

    • Flex Builder Standard
    • Flex Builder Professional

      This means that the Flex Charting product that existed in 2.0.1, no longer exists as a standalone buy in Flex 3. Instead, it is packaged in the Data Visualization package (which includes Charts & its enhancements, AdvancedDataGrid, OLAPGrid… etc) which is available only with the Flex Builder Pro.

      Over and above the standard edition, the professional edition will provide premium features like Charting and Visualization components, the Profiler, and the Flex Test Automation Framework. If you need more info about prices and stuff, you can check out this post by Ted. A thing to note here is that the Automated Testing Framework is available only with the FB Pro & also that this would be the only way of buying the Automation framework of rhe product…

      FB & Data Visualization Licensing and the “licenses.properties” file

      Now, let’s talk about the licensing. In Flex2, if you had the charts.swc then you could write applications using the charting framework. But this would lead to a trial watermark to be displayed on the chart as below, which would make it useless for production applications.

      Charting Watermark

      The way to get rid of this was to get a Flex Charting license and then add it in the “Manage Flex Licenses” tab in Flex Builder 2 or add it in the license.properties file in the “\sdk\frameworks” directory.But with FB3, a whole new set of work flows emerge.

      1. If you need to use charting in FB3 using Flex3 SDK, things are a breeze. You can install FB Pro, and enter the serial no in the “Manage Flex Licenses” tab in the “Help” Menu and you are ready to roll.

      2. But, FB3 also supports multiple-sdks in it. It comes pre-installed with Flex 3 & Flex 2.0.1 sdks (you can find it in the “\sdks” directory). So you may want to still continue working with Flex 2.0.1 project in FB3. If that project has charting, you will still see the watermark, even if you enter the FB3 Pro serial. This is because the Flex 2.0.1 SDK takes the charting serial from the licence.properties file in its SDK directory (“\sdks\2.0.1\frameworks”). So the way to work around this is to enter your Flex 2 charting license in the file.

      Also, another thing to note is that if you want to manually enter the FB license in the license.properties file in Flex3, the file is now stored in a global location in the OS and not in the frameworks directory in the SDK path. The path to the license.properties file for various OS’ are given below.

      • “../Documents and Settings/All Users/Application Data/Adobe/Flex” directory on Windows
      • “Library/Application Support/Adobe/Flex” directory on MAC
      • “$HOME/.adobe/Flex” on Linux

      How do I get Data Visualization Charting Components for FB Linux?

      October 3, 2007

      I was reading the FB Linux FAQs and came across the question that became the title of this post. The answer was…

      While the Data Visualization and Charting components are not part of the Flex Builder Linux Alpha, it is possible to purchase a Flex Builder 3 Professional license (either Mac or Win) and move the licensed datavisualization.swc file over to your Linux installation. This process has been explained by various users in our forums and is acceptable under the terms of your Flex Builder 3 license.

      This answer didn’t make me happy. I tried googling for the exact solution, but in vain. So I decided to post the solution myself. Here it is. The trick to make this work lies in 2 swc files existant in your Flex SDK Folder.

      Pre-Requisite: You need to have an SDK with Data Visualization Charting Components already installed.

      When you install FlexBuilder on Windows/MAC, it already comes the Data Visualization Charting Components installed, but with a watermark on them. If you have the serial number, then the watermark goes away. Now this is what you need to do…

      Caution: Please make sure that your SDK installations on Linux & Win/Mac are compatible before you follow the steps below. To do this go to [FB Install Folder]/sdks/3.0.0/bin folder and type the following on the command-line (or terminal) to ascertain the version numbers are the same.

      mxmlc -version (on WIN)

      ./mxmlc -version (on MAC/Linux)

      Steps to Install Data Visualization Charting Components for Linux

      1. Go to the [FB Install Folder]/sdks/3.0.0/ folder on your WIN/MAC
      2. Get the following files…
        • [FB Install Folder]/sdks/3.0.0/frameworks/libs/datavisualization.swc
        • [FB Install Folder]/sdks/3.0.0/frameworks/locale/en_US/ datavisualization_rb.swc
        • [FB Install Folder]/sdks/3.0.0/frameworks/license.properties
      3. Copy this to your FB Linux installation in the same directory structure as above

      This should get Data Visualization Charting Components working on Linux, complete with code-hinting. Let me know if you have any problems.

      Addendum: I had overlooked the need for continuing to use Charts in Flex2.0.1 on FlexBuilder. In that case, you can copy the file [FB Install Folder]/sdks/2.0.1/frameworks/libs/charts.swc to the same location in the 2.0.1 SDK delivered with the FB Linux. You can also copy the file [FB Install Folder]/ sdks/ frameworks/ license.properties from your 2.0.1 SDK in Windows to the same location in the 2.0.1 SDK in Linux. This should get rid of the watermark if you have a license.