Solved

Flex accessing local data

Posted on 2009-05-17
12
818 Views
Last Modified: 2012-05-07
I am creating an application that draws on a lot of textual information, currently in a database. The app is to run locally, on end user machines only, not from a server, not connected to the web, and  built in flexbuilder 3. Therefore I need to access the data directly. I don't want to use AIR, but make this web-enabled as well. It looks like the only solution is to build the database containing all the content, in something local like Access, and then write it all out as an xml file, and access it directly from there. Not keen on this as editing the content will be a nightmare. Does anyone have any other solutions?
0
Comment
Question by:virgewest
  • 5
  • 3
  • 2
  • +1
12 Comments
 
LVL 46

Expert Comment

by:tbsgadi
Comment Utility
How about using Excel?
0
 
LVL 1

Expert Comment

by:jbake
Comment Utility
if you are familar with python and python database connections, you could also design your database (mysql, postgres, ...) get the data with python and export it as xml.
0
 

Author Comment

by:virgewest
Comment Utility
To tbsgadi: thanks, but how would excel help? can as3 directly query an excel table?
To jbake: thank you, but the problem is not with organising the data, but reading it locally, without exporting it to xml.
0
 
LVL 46

Expert Comment

by:tbsgadi
Comment Utility
I don't know whether you can directly access excel, but excel is very easy to edit & to export to xml.
0
 
LVL 1

Expert Comment

by:jbake
Comment Utility
0
 

Author Comment

by:virgewest
Comment Utility
The issue was whether I could avoid moving my data to xml, not how to get it into xxml.  I guess the answer is that xml is the only way to get data into flash. Is that right?  
0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 
LVL 1

Expert Comment

by:jbake
Comment Utility
If you want to store the data locally there is also the SharedObject:

Storing local data @ livedocs.adobe.com

Problem in this Case is getting the Data from the Database and converting it to SharedObjects. Which database do you use?

0
 

Author Comment

by:virgewest
Comment Utility
Data is currently in Access db. It will write out OK as xml, and I need to be able to query it with sql-like strings to get the content. So I think I'm stuck with xml. Maybe I have to write myself an xml editor for it!
0
 
LVL 19

Expert Comment

by:Jones911
Comment Utility
Instead of using Flex use Air which can access the local filesystem and also jad SQL light inbuilt.  Flex can access the local files systems with the 3.2 ro 3.3 sdk there are some new features but it also requires Flash 10.

Rather then creating a Flex app select AIR app in Flexbuilder and you have full file access to the local machine and can have local databases using SQL light without needing to revert o mySQl, XML or some cvs format.
0
 

Author Comment

by:virgewest
Comment Utility
Thanks jones911, but as I said in my first post, I need to avoid air and keep my app web-enabled, for the users who do have internet access, while not disadvantaging those who don't. Tough call, but I still think I end up with xml.
0
 
LVL 19

Expert Comment

by:Jones911
Comment Utility
Take a look at this post on reading and writing local files with Flex and Flash 10 ti should prove usefull.

http://www.mikechambers.com/blog/2008/08/20/reading-and-writing-local-files-in-flash-player-10/
0
 

Accepted Solution

by:
virgewest earned 0 total points
Comment Utility
Thanks for all the suggestions, but I think xml is the only answer. It just seems a drag to have to convert from a db to xml, then parse it all back to a db like array. Thanks anyway.
0

Featured Post

Free Trending Threat Insights Every Day

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

Introduction: I have seen many questions on EE and elsewhere, asking about how to find either gaps in lists of numbers (id field, usually) ranges of values or dates overlapping date ranges combined date ranges I thought it would be a good …
This article explains all about SQL Server Piecemeal Restore with examples in step by step manner.
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now