In Flex, an application can be created from database by
following the steps as follows:
STEP 1. Create a new Flex Project and name it as for example,
“FLEXDB”. Select the
application type as “Web Application (runs in Flash
Player)” and Application server type as
STEP 2. Go to Data->Create application from database.
Select the project as
FLEXDB”.Create a new Connection to SqlServer 2005 and
specify the database and name that connection
as”TestConn”. Then select any table (for example
DashboardRegion) from the list of tables and click
STEP 3. Select the Server language as “C# with Web
Services”. Click “Finish”.
STEP 4. Then the following files and folders will be created
under the project “FLEXDB”
• DashboardRegion.mxml -- is a design page.
• DashboardRegionScript.as -- defines web service
object and capture the results and assigns the results to the
corresponding UI Component.
• DashboardRegionConfig.as -- calls the Web Service
• DashboardRegion.asmx -- calls the Class Files
• Web.config – defines the Connection string
• App_Code is a folder which contains the following
o DashboardRegion.cs that interacts with SQL Server 2005 and
return the results.
o TestConn.cs that defines connection to SQL Server 2005.
STEP 5. Run the application “DashboardRegion.mxml
”.We can see the Database results
Fetched and displayed in the corresponding UI Component in
Now we are trying to create a Similar Flex Application using
For this, we have to follow similar steps mentioned as above
with a slight modification in STEP 1. It will be as follows:
STEP 1. Create a new Flex Project and name it as for
example, “FLEXDB”. Select the
application type as”Desktop Application (runs in Adobe
AIR)” and Application server type as “ASP.Net”.
The remaining steps are same as above.
When we try to run the application
“DashboardRegion.mxml”, it is throwing an error saying
“DashboardRegion-app.xml” file is missing. To solve
this issue we tried creating “DashboardRegion-app.xml”
file manually, the application is running but, again throwing an
error saying “Unable to load WSDL. If currently online,
please verify the URI and/or format of the WSDL