Ah, that works!

Thanks Jim.

-Greg

From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Jim 
Hayes
Sent: Monday, January 28, 2008 5:08 PM
To: [email protected]
Subject: RE: [flexcoders] Running a flex app from local file system


Try -use-network=false

Jim.

-----Original Message-----
From: [email protected]<mailto:flexcoders%40yahoogroups.com> on behalf 
of Greg Hess
Sent: Mon 28/01/2008 19:39
To: [email protected]<mailto:flexcoders%40yahoogroups.com>
Subject: RE: [flexcoders] Running a flex app from local file system

Thanks Guys,

Unfortunately, I am having difficulty getting both strategies to work.

1. Embed the xml file

- It seems xml file format (xml) is not specifically supported by Flex and will 
require me to set the MIME type and the embedded object is a ByteArrayAsset. Is 
this the only way?

- tried to embed both as a metadata tag and directive and the error states: no 
transcoder registered for mimeType

2. Use the compiler arg '-use-network false'
- it seems the argument -use-network does not support additional parameters 
such as 'false'. When I use just '-use-network' it does compile but errors at 
runtime loading the local XML file as before.

My mxml is as follows (loading 'images/gallery/photos.xml is giving the 
problem'):

<mx:HTTPService id="photosIn" url="images/gallery/photos.xml" 
result="photosInHandler(event)" />

The resulting ArrayCollection is used to bind as the dataProvider of a TileList.

Am I missing something? Just wanted an easy way to support launching off local 
file system and hoped I could have an easy strategy to toggle both deployment 
strategies (web server, local file system).

Any comments much appreciated.

-Greg

From: [email protected]<mailto:flexcoders%40yahoogroups.com> 
[mailto:[email protected]<mailto:flexcoders%40yahoogroups.com>] On 
Behalf Of Andrew D. Goodfellow
Sent: Monday, January 28, 2008 11:37 AM
To: [email protected]<mailto:flexcoders%40yahoogroups.com>
Subject: Re: [flexcoders] Running a flex app from local file system

Hi Greg,

I think if you go to "Project | Properties | Flex Compiler" and add " 
-use-network false" to the Additional Compiler Arguments that might do the 
trick.

You'll need to rebuild. I think the problem you are having is due to security 
constraint built into the Flash player. It will allow the swf to either load 
external resources via HTTP from the network OR from the local filesystem. Both 
are not allowed, you have to choose a setting for one or the other when you 
build/publish.

-Andy
On Jan 28, 2008 9:38 AM, Greg Hess <[EMAIL 
PROTECTED]<mailto:greg.hess%40axentra.com><mailto:[EMAIL 
PROTECTED]<mailto:greg.hess%40axentra.com>>> wrote:

Hi All,

I am working with a remote team and I need to send them the application 
prototype for review. I thought all I need to do is add all the files in the 
output dir to a compressed file and send via email ect... The prototype is 
loading a local XML file to populate an UI component to simulate a remote 
HTTPService call and it seems to be generating security violations accessing 
the local file system. The client workstations are Windows Vista.

How do I build or configure the application so it can be launched from the 
local files system?

Any comments much appreciated.

Thanks,

-Greg

__________________________________________________________
This communication is from Primal Pictures Ltd., a company registered in 
England and Wales with registration No. 02622298 and registered office: 4th 
Floor, Tennyson House, 159-165 Great Portland Street, London, W1W 5PA, UK. VAT 
registration No. 648874577.

This e-mail is confidential and may be privileged. It may be read, copied and 
used only by the intended recipient. If you have received it in error, please 
contact the sender immediately by return e-mail or by telephoning +44(0)20 7637 
1010. Please then delete the e-mail and do not disclose its contents to any 
person.
This email has been scanned for Primal Pictures by the MessageLabs Email 
Security System.
__________________________________________________________

Reply via email to