[flexcoders] Re: FileReference to ByteArray

2008-09-30 Thread aytuganov
Thanks Jon.
I discovered this issue and found the way to solve my task with java
servlet. But now I have other problem. 
I can add listeners for COMPLETE, IO_ERROR,HTTP_STATUS,
DataEvent.UPLOAD_COMPLETE_DATA events. But I can not find the way to
receive a respond from servlet with the generated filename if  my file
that I have just uploaded.
Thanks in advance.

--- In flexcoders@yahoogroups.com, Jon Bradley [EMAIL PROTECTED] wrote:

 
 On Sep 26, 2008, at 4:48 AM, aytuganov wrote:
 
  Does somebody know is it possible to select file using
  FileReference.browse() and than set it to ByteArray instance.
  (There is an object that has an ByteArray property. I have to set this
  property and send the object to server using RemoteObject - but it's
  not a matter)
 
 In Flash 10.
 
 You have no access to the content of a FileReference object or item  
 in any version of Flash earlier than v10. That's a resounding answer  
 of no.
 
 There may be ways to hack the HTTPHeader information to include  
 additional content information when the FileReference is uploaded.  
 Otherwise, you'll need to send that data separately to the server.
 
 good luck,
 
 jon





[flexcoders] Resolved Re: Have a question about Weborb

2008-09-30 Thread bhaq1972
hi Tim

I'd like to try out you've done. Is there a tutorial anywhere you 
can recomend.

regadrs
Bod

--- In flexcoders@yahoogroups.com, timgerr [EMAIL PROTECTED] 
wrote:

 OK, I found out how to do this.  When updating a row I have to 
specify
 the row id, I think that is all. That is how I got it to work.
 
 So if I have this 
 _master = ActiveRecords.Test.findByIdAndName('6','tessa');
 _master[0].Email = [EMAIL PROTECTED];
 _master[0].Name = tessa;
 _master[0].Id = 6;
 
 
 I then create the test method (I think that is what you call it)
 var i:Test = new Test();
 i.Name = Tess;
 i.Email = [EMAIL PROTECTED];
 i.Id = 6;
 var asyncToken:AsyncToken = null;
 asyncToken = i.save();
 asyncToken.addResponder(new mx.rpc.Responder (OnCreated,OnFault));
 
 That is it, that is how I got it to work.  Man this Weborb rocks.  
I
 have a few other questions that I will be posting
 
 
 
 --- In flexcoders@yahoogroups.com, timgerr tim.gallagher@ 
wrote:
 
  Let me make this a little more clear:
  I am good at looking at code so here is what I am doing.  I want 
to
  call a database row using findby and ad that information into an 
array
  collection:
  private var _master:ArrayCollection = new ArrayCollection(); 
  _master = ActiveRecords.Test.findByIdAndName('6','tessa');
  
  so now master[0] has Id, Email, Name
   so if I wanted to change the name from tessa to
  tess, not sure what to do.
  
  Thanks for the read.
  timgerr
  
  
  --- In flexcoders@yahoogroups.com, timgerr tim.gallagher@ 
wrote:
  
   Mark, Thanks for the reply, I am getting closer to learning 
how to do
   an update.
   
   I am good at looking at code so here is what I am doing.  I 
want to
   call a database row using findby and ad that information into 
an array
   collection:
   private var _master:ArrayCollection = new ArrayCollection(); 
   _master = ActiveRecords.Test.findByIdAndName('6','tessa');
   
   so now master[0] has Id, Email, Name
   so if I wanted to change the email from tsa@ to
   tsa@, I do this?
   
   private var uDate:Test = new Test();
   uDate.Name = 'tessa';
   uDate.Id   = '6';
   udate.Email = 'tesa@';
   
   var asyncToken:AsyncToken = null;
   asyncToken = uDate.save();
   
   How does webord know the difference between an updated and new 
record?
   
   Thanks for the help,
   timgerr
   
   
   
   --- In flexcoders@yahoogroups.com, Mark Piller mark@ wrote:
   
Hi Tim,

For any instance of Active Record on the client side you can 
change
the properties and then call save() on that instance. It 
will update
the record in the database and also issue client 
synchronization
 event
so other clients that have the same record would be updated.
 Instances
of active record are loaded with any of the findXXX methods.

Hope this helps.

Mark
   
  
 





[flexcoders] How to stop the updateDisplay event propagation?

2008-09-30 Thread Manu Dhanda

Hi,

I am having mouse pointer flickering issue while one of the component is
still preparing it's data. And that flicking is caused because I am
assigning renderer's through a for loop to a grid.

Can someone give me a pointer like what I need to do?
Because I am really tired of looking for this issue and kinda unable to find
the right approach to resolve this problem :(

Thanks,
Manu.
-- 
View this message in context: 
http://www.nabble.com/How-to-stop-the-updateDisplay-event-propagation--tp19738415p19738415.html
Sent from the FlexCoders mailing list archive at Nabble.com.



Re: [flexcoders] How to stop the updateDisplay event propagation?

2008-09-30 Thread jitendra jain
Provide with some test code..
 Thanks,

with Regards,
Jitendra Jain




- Original Message 
From: Manu Dhanda [EMAIL PROTECTED]
To: flexcoders@yahoogroups.com
Sent: Tuesday, 30 September, 2008 2:25:00 PM
Subject: [flexcoders] How to stop the updateDisplay event propagation?



Hi,

I am having mouse pointer flickering issue while one of the component is
still preparing it's data. And that flicking is caused because I am
assigning renderer's through a for loop to a grid.

Can someone give me a pointer like what I need to do?
Because I am really tired of looking for this issue and kinda unable to find
the right approach to resolve this problem :(

Thanks,
Manu.
-- 
View this message in context: http://www.nabble. com/How-to- stop-the- 
updateDisplay- event-propagatio n--tp19738415p19 738415.html
Sent from the FlexCoders mailing list archive at Nabble.com.

 


  Add more friends to your messenger and enjoy! Go to 
http://in.messenger.yahoo.com/invite/

Re: [flexcoders] catching uncaught exception

2008-09-30 Thread Tom Chiverton
On Friday 26 Sep 2008, Stefaan_Nachtergaele wrote:
 Java has a method on the thread class:
 setUncaughtExceptionHandler(Handler). This way you can ensure that all
  exception will be handled. Does  flex have something like this?

No.

-- 
Tom Chiverton
Helping to efficiently orchestrate synergies





This email is sent for and on behalf of Halliwells LLP.

Halliwells LLP is a limited liability partnership registered in England and 
Wales under registered number OC307980 whose registered office address is at 
Halliwells LLP, 3 Hardman Square, Spinningfields, Manchester, M3 3EB.  A list 
of members is available for inspection at the registered office. Any reference 
to a partner in relation to Halliwells LLP means a member of Halliwells LLP.  
Regulated by The Solicitors Regulation Authority.

CONFIDENTIALITY

This email is intended only for the use of the addressee named above and may be 
confidential or legally privileged.  If you are not the addressee you must not 
read it and must not use any information contained in nor copy it nor inform 
any person other than Halliwells LLP or the addressee of its existence or 
contents.  If you have received this email in error please delete it and notify 
Halliwells LLP IT Department on 0870 365 2500.

For more information about Halliwells LLP visit www.halliwells.com.



--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Alternative FAQ location: 
https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! 
Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* Your email settings:
Individual Email | Traditional

* To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)

* To change settings via email:
mailto:[EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED]

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/



Re: [flexcoders] Upload file to server from AIR app

2008-09-30 Thread Tom Chiverton
On Monday 29 Sep 2008, gilbert_mizrahi wrote:
 I am getting a I/O Error: Error #2038.

What's the full text and stack trace ?

-- 
Tom Chiverton
Helping to adaptively brand interfaces





This email is sent for and on behalf of Halliwells LLP.

Halliwells LLP is a limited liability partnership registered in England and 
Wales under registered number OC307980 whose registered office address is at 
Halliwells LLP, 3 Hardman Square, Spinningfields, Manchester, M3 3EB.  A list 
of members is available for inspection at the registered office. Any reference 
to a partner in relation to Halliwells LLP means a member of Halliwells LLP.  
Regulated by The Solicitors Regulation Authority.

CONFIDENTIALITY

This email is intended only for the use of the addressee named above and may be 
confidential or legally privileged.  If you are not the addressee you must not 
read it and must not use any information contained in nor copy it nor inform 
any person other than Halliwells LLP or the addressee of its existence or 
contents.  If you have received this email in error please delete it and notify 
Halliwells LLP IT Department on 0870 365 2500.

For more information about Halliwells LLP visit www.halliwells.com.



--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Alternative FAQ location: 
https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! 
Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* Your email settings:
Individual Email | Traditional

* To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)

* To change settings via email:
mailto:[EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED]

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/



[flexcoders] Debug mode or normal mode?

2008-09-30 Thread Manu Dhanda

Hii guyz,

How do u identify from inside your application whether your app is running
in Debug Mode or Normal Mode?

Thanks.
-- 
View this message in context: 
http://www.nabble.com/Debug-mode-or-normal-mode--tp19739663p19739663.html
Sent from the FlexCoders mailing list archive at Nabble.com.



Re: [flexcoders] Debug mode or normal mode?

2008-09-30 Thread jitendra jain
when your application is running on the server while in debug mode you will 
have the following address in your browser window
 
http://localhost:8081/myApp/main.html?debug=true
 
for normal mode it will be:
 
http://localhost:8081/myApp/main.html
 
and also right click on the flash player to see the context menu has option 
debugger. From this u can know that flash player supports debugging. Let me 
know your more questions if any..
 Thanks,

with Regards,
Jitendra Jain




- Original Message 
From: Manu Dhanda [EMAIL PROTECTED]
To: flexcoders@yahoogroups.com
Sent: Tuesday, 30 September, 2008 4:08:01 PM
Subject: [flexcoders] Debug mode or normal mode?



Hii guyz,

How do u identify from inside your application whether your app is running
in Debug Mode or Normal Mode?

Thanks.
-- 
View this message in context: http://www.nabble. com/Debug- mode-or-normal- 
mode--tp19739663 p19739663. html
Sent from the FlexCoders mailing list archive at Nabble.com.

 


  Bollywood news, movie reviews, film trailers and more! Go to 
http://in.movies.yahoo.com/

[flexcoders] determine if image source exists

2008-09-30 Thread bhaq1972
How can I check if a the jpg source defined by a string really exists. 
eg

var image1:Image = new Image();
var sHello:String = images/hello.jpg;

if(sHello exists) // this is the bit i need help on
{
  image1.source = sHello;
}


tia
bod




Re: [flexcoders] determine if image source exists

2008-09-30 Thread jitendra jain
Use Embed keyword that will help embedding the image in a class while 
compiling.[Embed(assets/status.png)]
private var status:Class;Thanks,

with Regards,
Jitendra Jain




- Original Message 
From: bhaq1972 [EMAIL PROTECTED]
To: flexcoders@yahoogroups.com
Sent: Tuesday, 30 September, 2008 5:35:19 PM
Subject: [flexcoders] determine if image source exists


How can I check if a the jpg source defined by a string really exists. 
eg

var image1:Image = new Image();
var sHello:String = images/hello. jpg;

if(sHello exists) // this is the bit i need help on
{
image1.source = sHello;
}

tia
bod

  image.source=status; 


  Connect with friends all over the world. Get Yahoo! India Messenger at 
http://in.messenger.yahoo.com/?wm=n/

Re: [flexcoders] determine if image source exists

2008-09-30 Thread Paul Andrews
..but understand that it's no longer an external asset and will be embedded in 
your swf. If the png changes after you publish the swf, the change won't be 
picked up until you republish.
  - Original Message - 
  From: jitendra jain 
  To: flexcoders@yahoogroups.com 
  Sent: Tuesday, September 30, 2008 1:10 PM
  Subject: Re: [flexcoders] determine if image source exists


  Use Embed keyword that will help embedding the image in a class while 
compiling.
  [Embed(assets/status.png)]

  private var status:Class;

   image.source=status; 
  Thanks,

  with Regards,
  Jitendra Jain





  - Original Message 
  From: bhaq1972 [EMAIL PROTECTED]
  To: flexcoders@yahoogroups.com
  Sent: Tuesday, 30 September, 2008 5:35:19 PM
  Subject: [flexcoders] determine if image source exists


  How can I check if a the jpg source defined by a string really exists. 
  eg

  var image1:Image = new Image();
  var sHello:String = images/hello. jpg;

  if(sHello exists) // this is the bit i need help on
  {
  image1.source = sHello;
  }

  tia
  bod





--
  Did you know? You can CHAT without downloading messenger. Click here  

Re: [flexcoders] determine if image source exists

2008-09-30 Thread jitendra jain
Yes, Paul you are absolutely right. Please take a note of this while handling 
with images specially dealing with Embed keyword.
 Thanks,

with Regards,
Jitendra Jain




- Original Message 
From: Paul Andrews [EMAIL PROTECTED]
To: [EMAIL PROTECTED]
Sent: Tuesday, 30 September, 2008 5:55:50 PM
Subject: Re: [flexcoders] determine if image source exists


 
..but understand that it's no longer an external asset and will be embedded in 
your swf. If the png changes after you publish the swf, the change won't be 
picked up until you republish.
- Original Message - 
From: jitendra jain 
To: [EMAIL PROTECTED] ups.com 
Sent: Tuesday, September 30, 2008 1:10 PM
Subject: Re: [flexcoders] determine if image source exists

Use Embed keyword that will help embedding the image in a class while 
compiling..[Embed(assets/ status.png )]
private var status:Class; image.source= status; Thanks,

with Regards,
Jitendra Jain




- Original Message 
From: bhaq1972 [EMAIL PROTECTED] com
To: [EMAIL PROTECTED] ups.com
Sent: Tuesday, 30 September, 2008 5:35:19 PM
Subject: [flexcoders] determine if image source exists


How can I check if a the jpg source defined by a string really exists. 
eg

var image1:Image = new Image();
var sHello:String = images/hello. jpg;

if(sHello exists) // this is the bit i need help on
{
image1.source = sHello;
}

tia
bod



Did you know? You can CHAT without downloading messenger. Click here 
__.._,_.___ 
Messages in this topic (3) Reply (via web post) | Start a new topic 
Messages 
--
Flexcoders Mailing List
FAQ: http://groups.yahoo..com/group/flexcoders/files/flexcodersFAQ.txt
Alternative FAQ location: 
https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
 
Change settings via the Web (Yahoo! ID required) 
Change settings via email: Switch delivery to Daily Digest | Switch format to 
Traditional 
Visit Your Group | Yahoo! Groups Terms of Use | Unsubscribe 
Recent Activity
*  60
New MembersVisit Your Group 
Yahoo! Finance
It's Now Personal
Guides, news,
advice  more.
Real Food Group
Share recipes,
restaurant ratings
and favorite meals.
Best of Y! Groups
Check it out
and nominate your
group to be featured.
. 
 


  Share files, take polls, and make new friends - all under one roof. Go to 
http://in.promos.yahoo.com/groups/

[flexcoders] Re: Problem referring to TextInput in itemRenderer

2008-09-30 Thread oneworld95
Hi, Tracy. I was hoping there'd be an answer! Here's the thing: The user
first does a Browse to choose a file, then clicks the Upload button.
Then, if the upload was successful, we refresh the datagrid. What if the
user doesn't click Upload on that item, but instead scrolls the grid?
I've found articles talking about issues with the recycling,

* http://www.adobe.com/devnet/flex/articles/itemrenderers_pt1.html
*
http://blogs.adobe.com/aharui/2007/03/thinking_about_item_renderers_1.ht\
ml
Thanks.

--- In flexcoders@yahoogroups.com, Tracy Spratt [EMAIL PROTECTED] wrote:

 Ah, yes.



 Item renderers are recycled.  Only the ones actually visible even
 exist.  If you have any state in an item renderer that is row / item
 specific, you must ensure that that state is set from a value in the
 dataProvider item, in the set data() override.  Further, if a user
 interacts with the renderer and changes the visual state, like
entering
 a text value in a TextInput, you must update the dataProvider item
with
 that value.



 I would advise doing a bit of reading on itemRenderers before going
much
 further.



 Tracy



 

 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED]
On
 Behalf Of oneworld95
 Sent: Monday, September 29, 2008 4:05 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Problem referring to TextInput in itemRenderer



 Hi. I'm trying to refer to the TextInput control of a specific row
 when the user clicks a button in that row's itemRenderer. I can change
 the text in that row's TextInput, but then when I scroll I noticed
 that other rows (at random) have their TextInput control set to the
 same value. If I scroll up all the way, the item I had edit no longer
 has its new value! I also tried reading the value from the event
 parameter but had same result.

 Here's the MXML followed by the click handler,

 mx:DataGridColumn id=myCol headerText=Test width=250
 mx:itemRenderer
 mx:Component
 mx:HBox horizontalGap=2
 mx:TextInput id=txtPhoto /
 mx:Script
 ![CDATA[
 import mx.controls.listClasses.ListBase;
 ]]
 /mx:Script
 mx:Button id=btnBrowse label=Browse click=
 outerDocument.doBrowse( event, this )/
 mx:Button id=btnUpload label=Upload
 click=outerDocument.doSubmit( event )/
 /mx:HBox
 /mx:Component
 /mx:itemRenderer
 /mx:DataGridColumn

 // Called when the Browse button is clicked
 public function doBrowse( event:Event, hbox:HBox ):void
 {
 var text:TextInput = hbox.getChildAt(0) as TextInput;
 text.text = testing;
 return;
 }




[flexcoders] extend titlewindow ?

2008-09-30 Thread greg_knight_66

hi all,

i am looking for an example illustrating how to extend/modify the 
header of the titlewindow.  im assuming this is possible?  
specifically, i am looking to add a minimize button.

thanks for your help.

greg



[flexcoders] Re: Problem referring to TextInput in itemRenderer

2008-09-30 Thread oneworld95
[I tried using the Rich-Text Editor but somehow my reply didn't end up
here. So a second attempt...]

I've read up on the itemRenderers recycling issue here,
 - http://www.adobe.com/devnet/flex/articles/itemrenderers_pt1.html
 -
http://blogs.adobe.com/aharui/2007/03/thinking_about_item_renderers_1.html

The problem is compounded by this: The user does a Browse for a file,
then clicks the Upload button. If the upload was successful, we write
to the dataprovider. 

What if I pull the file browse/upload component out of the datagrid
and put it by itself? So when a user clicks a row, we update that one
set of controls outside of the datagrid. Is this a good way of doing
it? Thanks. 

--- In flexcoders@yahoogroups.com, Tracy Spratt [EMAIL PROTECTED] wrote:

 Ah, yes.
 
  
 
 Item renderers are recycled.  Only the ones actually visible even
 exist.  If you have any state in an item renderer that is row / item
 specific, you must ensure that that state is set from a value in the
 dataProvider item, in the set data() override.  Further, if a user
 interacts with the renderer and changes the visual state, like entering
 a text value in a TextInput, you must update the dataProvider item with
 that value.
 
  
 
 I would advise doing a bit of reading on itemRenderers before going much
 further.
 
  
 
 Tracy
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of oneworld95
 Sent: Monday, September 29, 2008 4:05 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Problem referring to TextInput in itemRenderer
 
  
 
 Hi. I'm trying to refer to the TextInput control of a specific row
 when the user clicks a button in that row's itemRenderer. I can change
 the text in that row's TextInput, but then when I scroll I noticed
 that other rows (at random) have their TextInput control set to the
 same value. If I scroll up all the way, the item I had edit no longer
 has its new value! I also tried reading the value from the event
 parameter but had same result.
 
 Here's the MXML followed by the click handler,
 
 mx:DataGridColumn id=myCol headerText=Test width=250
 mx:itemRenderer
 mx:Component
 mx:HBox horizontalGap=2
 mx:TextInput id=txtPhoto /
 mx:Script
 ![CDATA[
 import mx.controls.listClasses.ListBase;
 ]]
 /mx:Script 
 mx:Button id=btnBrowse label=Browse click=
 outerDocument.doBrowse( event, this )/
 mx:Button id=btnUpload label=Upload
 click=outerDocument.doSubmit( event )/
 /mx:HBox
 /mx:Component
 /mx:itemRenderer
 /mx:DataGridColumn
 
 // Called when the Browse button is clicked
 public function doBrowse( event:Event, hbox:HBox ):void
 {
 var text:TextInput = hbox.getChildAt(0) as TextInput;
 text.text = testing;
 return;
 }





[flexcoders] Sound class - File headers, IOErrors, and 404s

2008-09-30 Thread horizens
Hi, all

I'm developing an mp3 player for a rather large music search engine.
The files that are played are found on the web, so it's increasingly
difficult to gracefully determine to the validity of them.

This file for instance:

http://boxstr.com/files/2863558_hqzwk/lil%20wayne%20freestyle.mp3

This is a file that our spider picked up and cached at some point. Now
when a user loads this track into the player today, it's obviously a
dead link and is actually a gif. What's also troubling is that in this
case, Flash doesn't ever receive a 404 for the mp3 file. It actually
tries to load the file.

The problem is that I'm getting really inconsistent results when
dealing with bad links. Some sites will send back a 200 even though it
should be a 404. The sound class in AS3 doesn't seem adequate for
dealing with with type of scenario. The IOErrorEvent.IO_ERROR only
fires is it gets back a 404 or if the connection is dropped.

Does anyone have a solution to deal with broken links? Is there any
way to check the file/mime type returned? Right now I have a jenky
solution that checks the total bytes with a timer. This is definitely
not ideal as it doesn't account for users with slow connections. I'd
love a seamless solution that will detect a bad link, report it as
invalid, and immediately move on to the next track in a playlist.

Thanks very much.




Re: [flexcoders] determine if image source exists

2008-09-30 Thread Scott Melby

You can use a Loader and attempt a load as follows:

 /**
 * The Loader used to load images.
 */
 private var _imageLoader:Loader = new Loader();

...


 var urlRequest:URLRequest = new URLRequest(someURLString);

 try

 {
   _imageLoader.load(urlRequest);
 }
 catch (imageLoadError:Error)
 {
   trace(Unable to load image at ' + someURLString + ':  + 
imageLoadError.message);

  }

You will need to listen to the loader for events.  If it loads, your 
source is ok, if not you will likely get the ioError event... unless you 
have a security issue in which case you will catch the SecurityError 
that gets thrown.


hth
Scott




bhaq1972 wrote:


How can I check if a the jpg source defined by a string really exists.
eg

var image1:Image = new Image();
var sHello:String = images/hello.jpg;

if(sHello exists) // this is the bit i need help on
{
image1.source = sHello;
}

tia
bod

 




[flexcoders] Re: flex dynamic instantiation of classes or class names

2008-09-30 Thread flexaustin
Thanks for the advice. That one is good to remember.



--- In flexcoders@yahoogroups.com, Josh McDonald [EMAIL PROTECTED] wrote:

 Don't store things in dictionary unless you need to use an object as
the key
 (in most cases you don't). In fact I nearly only use dictionary when
I need
 the weak reference function. Because Dictionary works using === and
not ==
 to compare keys, you can get weird conditions where things don't
match up
 when you think they should if you're using strings or numbers as keys.
 
 When using an id (string or int) as the key, you want to use a plain old
 object... Just start with var map : Object = {} instead of var d :
 Dictionary = new Dictionary()
 
 -Josh
 
 On Tue, Sep 30, 2008 at 12:04 AM, flexaustin [EMAIL PROTECTED] wrote:
 
  Here is my try.
 
 private var nodeDict:Dictionary = new
  Dictionary(true);
 
 private function createNodes(vgrph:VisualGraph,
  arrayCollOfNodes:ArrayCollection):void{
 
 for (var i:int=0; i 
  arrayCollOfNodes.length; i++){
 var nData:nodeVO =
  arrayCollOfNodes.getItemAt(i) as nodeVO;
 var ivn:IVisualNode =
  vgrph.createNode( nData.id as String,
  nData.xml );
 ivn.isVisible = true;
 // need to store this in a
  dictionary so that edges function
  below can access the items...Maybe some other way.
 nodeDict[nData.id] = ivn;
 
 }
 }
 
 private var edgeDict:Dictionary = new
  Dictionary(true);
 
 private function createEdges(vgrph:VisualGraph,
  arrayCollOfEdges:ArrayCollection):void{
 
 for (var i:int=0; i 
  arrayCollOfEdges.length; i++){
 var eData:edgeVO =
  arrayCollOfEdges.getItemAt(i) as edgeVO;
 var ive:IVisualEdge =
  vgrph.linkNodes( nodeDict[eData.fromIDVO],
  nodeDict[eData.toIDVO] );
 ive.data = edge
assocation=edge
  /;
 
 // this might be better
served to
  move it in the init function or
  its own function.
 if (i == 0)
vgrph.currentRootVNode =
  i as IVisualNode;
  }
 }
 
 
  --- In flexcoders@yahoogroups.com, flexaustin flexaustin@ wrote:
  
   Is it possible to instantiate objects with dynamic names?
  
   So instead of:---
  
   var n:Object = new Object;
  
  
   Something like:-
  
   for (var i:int=0; i  array.length; i++){
  var n(i):Object = new Object;
   }
  
   I need to create instance of certain type object, but then reference
   those objects later by their name. I would like to create them then
   store them in a dictionary and reference them later so maybe
using the
   dictionaries methods to access them would be better?
  
  
   So do something like so:
  
   for (var i:int=0; i  array.length; i++){
  var n(i):Object = new Object;
  myDict[n(i)] = n(i);
   }
  
   then later do this:-
  
   var g1:something = b.link ( myDict[n1], myDict[n2])
  
  
   TIA!
  
 
 
 
  
 
  --
  Flexcoders Mailing List
  FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
  Alternative FAQ location:
 
https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
  Search Archives:
  http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
  Links
 
 
 
 
 
 
 -- 
 Therefore, send not to know For whom the bell tolls. It tolls for
thee.
 
 http://flex.joshmcdonald.info/
 
 :: Josh 'G-Funk' McDonald
 :: 0437 221 380 :: [EMAIL PROTECTED]





[flexcoders] Re: Upload file to server from AIR app

2008-09-30 Thread gilbert_mizrahi
I found the error is caused because 
var fileToUpload:File = new File(path+captureTest.flv);
is expecting a File object and not a String (path+captureTest.flv).

The problem I have is that I have no idea what constitutes a File
Object. Using the File.browse the file selected passed an event and
the upload method can take thee File object as event.target, but again
I don't know how that object is made in case I want to create one
without using the browse method for File.

I traced the event.target, but it is giving me [Object,
FileReference].Hence I am clueless.

Gilbert


--- In flexcoders@yahoogroups.com, Tom Chiverton [EMAIL PROTECTED]
wrote:

 On Monday 29 Sep 2008, gilbert_mizrahi wrote:
  I am getting a I/O Error: Error #2038.
 
 What's the full text and stack trace ?
 
 -- 
 Tom Chiverton
 Helping to adaptively brand interfaces
 
 
 
 
 
 This email is sent for and on behalf of Halliwells LLP.
 
 Halliwells LLP is a limited liability partnership registered in
England and Wales under registered number OC307980 whose registered
office address is at Halliwells LLP, 3 Hardman Square, Spinningfields,
Manchester, M3 3EB.  A list of members is available for inspection at
the registered office. Any reference to a partner in relation to
Halliwells LLP means a member of Halliwells LLP.  Regulated by The
Solicitors Regulation Authority.
 
 CONFIDENTIALITY
 
 This email is intended only for the use of the addressee named above
and may be confidential or legally privileged.  If you are not the
addressee you must not read it and must not use any information
contained in nor copy it nor inform any person other than Halliwells
LLP or the addressee of its existence or contents.  If you have
received this email in error please delete it and notify Halliwells
LLP IT Department on 0870 365 2500.
 
 For more information about Halliwells LLP visit www.halliwells.com.





[flexcoders] Re: TabNavigator - have to click twice on tab to display page

2008-09-30 Thread donald_d_hook
_rico - you may be right.  Thanks!


--- In flexcoders@yahoogroups.com, rleuthold [EMAIL PROTECTED] wrote:

 Maybe the issue is related to this bug - 
http://bugs.adobe.com/jira/browse/SDK-15974
 
 _rico
 
 --- In flexcoders@yahoogroups.com, donald_d_hook donald_d_hook@ 
wrote:
 
  Tracy - thanks - thats what I have started to do...
  
  I appreciate the feedback from you and everyone else - thanks!
  
  --- In flexcoders@yahoogroups.com, Tracy Spratt tspratt@ 
wrote:
  
   This is definitely not normal behavior, so you must have 
something
   unusual going on.  We haven't seen any code so we are just 
stabbing 
  in
   the dark.
   

   
   Rip out everything until it works, start adding it back til it 
  breaks.
   

   
   Tracy
   

   
   
   
   From: flexcoders@yahoogroups.com 
[mailto:[EMAIL PROTECTED] 
  On
   Behalf Of Tim Hoff
   Sent: Friday, September 26, 2008 12:52 PM
   To: flexcoders@yahoogroups.com
   Subject: [flexcoders] Re: TabNavigator - have to click twice on 
tab 
  to
   display page
   

   
   
   So, when you click the 2nd tab, does the 2nd tab remain 
selected, or
   does it switch back to the first tab? If it stays on the 2nd 
tab, 
  are
   you still seeing the content from the first tab, or is it just 
  blank;
   until you click the 2nd tab again?
   
   -TH
   
   --- In flexcoders@yahoogroups.com 
  mailto:flexcoders%40yahoogroups.com
   , donald_d_hook donald_d_hook@
   wrote:
   
TH -
   
No, I m not doing that, thats what I thought it was 
originally.
   
Thanks
   
--- In flexcoders@yahoogroups.com
   mailto:flexcoders%40yahoogroups.com , Tim Hoff TimHoff@ 
wrote:


 Cool, one other thing to check would be if you are manually 
  setting
the
 selectedIndex of the TabNavigator anywhere. Just guessing 
  though;
 without seeing the code.

 -TH

 --- In flexcoders@yahoogroups.com
   mailto:flexcoders%40yahoogroups.com , donald_d_hook 
  donald_d_hook@
 wrote:
 
  TH -
 
  THanks - I will give it a shot and see.
 
 
  --- In flexcoders@yahoogroups.com
   mailto:flexcoders%40yahoogroups.com , Tim Hoff TimHoff@ 
wrote:
  
  
   Sounds suspiciously like a callLater() solution. Have 
you 
  tested
   whether the creationComplete event is actually firing, 
  before
you
  click
   tab2, for all of the child components? Sometimes not 
setting 
  the
  data,
   in a timely fashion, can also make a view appear blank.
  
   -TH
  
   --- In flexcoders@yahoogroups.com
   mailto:flexcoders%40yahoogroups.com , Manu Dhanda 
  manuraj.dhanda@
   wrote:
   
   
Hi Tracy,
   
It's really an issue with TabNavigator and we had 
faced 
  it.
I won't say that I need to click the tab twice, but I 
need 
  to
  switch
   back to
Tab1 and then come back to Tab2 to see the content on 
my 
  2nd
Tab.
   
And yes, already tried with creationPolicy='all', but 
it 
  din't
  worked.
   
-Manu.
   
   
Tracy Spratt wrote:

 Are you programatically doing anything with the 
content 
  of
tab
  2?



 Do you understand about deferred instantiation and
  creationPolicy?



 Tracy



 

 From: flexcoders@yahoogroups.com
   mailto:flexcoders%40yahoogroups.com 
  [mailto:flexcoders@yahoogroups.com
   mailto:flexcoders%40yahoogroups.com ]
   On
 Behalf Of donald_d_hook
 Sent: Thursday, September 25, 2008 2:15 PM
 To: flexcoders@yahoogroups.com
   mailto:flexcoders%40yahoogroups.com 
 Subject: [flexcoders] TabNavigator - have to click 
twice 
  on
tab
  to
 display page



 I have a tab navigator with 3 tabs. Each tab has a 
  canvas
with
 several components on it. when the page is 
displayed, 
  you
see
  the
   1st
 tab. When I navigate to the 2nd tab, I have to click 
the 
  2nd
tab
 twice in order to view the contents of the tab. It 
looks
like
  the
 first click on the 2nd tab goes back to the first 
tab, 
  then
the
  2nd
 click displays the contents of the 2nd tab.

 Was wondering if anyone has experienced this 
behavior 
  and
  wondering
 what I am doing wrong.

 Thanks in advance.





   
--
View this message in context:
   http://www.nabble.com/TabNavigator---have-to-click-
twice-on-
  tab-
   http://www.nabble.com/TabNavigator---have-to-click-twice-on-
tab- 
to-
  displ\
   ay-page-tp19675428p19681501.html
Sent from the FlexCoders mailing list archive at 
  

RE: [flexcoders] extend titlewindow ?

2008-09-30 Thread Gregor Kiddie
If you subclass TitleWindow, titleBar is a protected variable, so you
can do to it pretty much whatever you want.

 

Gk.

Gregor Kiddie
Senior Developer
INPS

Tel:   01382 564343

Registered address: The Bread Factory, 1a Broughton Street, London SW8
3QJ

Registered Number: 1788577

Registered in the UK

Visit our Internet Web site at www.inps.co.uk
blocked::http://www.inps.co.uk/ 

The information in this internet email is confidential and is intended
solely for the addressee. Access, copying or re-use of information in it
by anyone else is not authorised. Any views or opinions presented are
solely those of the author and do not necessarily represent those of
INPS or any of its affiliates. If you are not the intended recipient
please contact [EMAIL PROTECTED]



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of greg_knight_66
Sent: 29 September 2008 23:42
To: flexcoders@yahoogroups.com
Subject: [flexcoders] extend titlewindow ?

 


hi all,

i am looking for an example illustrating how to extend/modify the 
header of the titlewindow. im assuming this is possible? 
specifically, i am looking to add a minimize button.

thanks for your help.

greg



[flexcoders] DataVisualization RSL Issues

2008-09-30 Thread Battershall, Jeff
Trying to use the datavisualization_3.1.0.2710.swz as an RSL. I've
worked through the stream errors and I've used the most recent version
avaiable from
http://blogs.adobe.com/flex/archives/2008/09/updated_rsl_for_flex_data_v
isu.html.

However, row text is not rendering in an AdvancedDataGrid I'm using for
a report. If I merge into code, I don't get that issue.

Any ideas?

Jeff Battershall
Application Architect
Dow Jones Indexes
[EMAIL PROTECTED]
(609) 520-5637 (p)
(484) 477-9900 (c)


[flexcoders] Re: determine if image source exists

2008-09-30 Thread bhaq1972
thanks scott.

btw. I can't use Embed because the images are only available at 
runtime.


--- In flexcoders@yahoogroups.com, Scott Melby [EMAIL PROTECTED] wrote:

 You can use a Loader and attempt a load as follows:
 
   /**
   * The Loader used to load images.
   */
   private var _imageLoader:Loader = new Loader();
  
 ...
 
   var urlRequest:URLRequest = new URLRequest(someURLString);
  
   try
   {
 _imageLoader.load(urlRequest);
   }
   catch (imageLoadError:Error)
   {
 trace(Unable to load image at ' + someURLString 
+ ':  + 
 imageLoadError.message);
}
 
 You will need to listen to the loader for events.  If it loads, 
your 
 source is ok, if not you will likely get the ioError event... 
unless you 
 have a security issue in which case you will catch the 
SecurityError 
 that gets thrown.
 
 hth
 Scott
 
 
 
 
 bhaq1972 wrote:
 
  How can I check if a the jpg source defined by a string really 
exists.
  eg
 
  var image1:Image = new Image();
  var sHello:String = images/hello.jpg;
 
  if(sHello exists) // this is the bit i need help on
  {
  image1.source = sHello;
  }
 
  tia
  bod
 
 





Re: [flexcoders] Debug mode or normal mode?

2008-09-30 Thread Manu Dhanda

It's not user.
I want my application to be intelligent enough that it could get this
knowledge whether it's running in debug mode or in normal mode.

Thanks.


jitendra jain wrote:
 
 when your application is running on the server while in debug mode you
 will have the following address in your browser window
  
 http://localhost:8081/myApp/main.html?debug=true
  
 for normal mode it will be:
  
 http://localhost:8081/myApp/main.html
  
 and also right click on the flash player to see the context menu has
 option debugger. From this u can know that flash player supports
 debugging. Let me know your more questions if any..
  Thanks,
 
 with Regards,
 Jitendra Jain
 
 
 
 
 - Original Message 
 From: Manu Dhanda [EMAIL PROTECTED]
 To: flexcoders@yahoogroups.com
 Sent: Tuesday, 30 September, 2008 4:08:01 PM
 Subject: [flexcoders] Debug mode or normal mode?
 
 
 
 Hii guyz,
 
 How do u identify from inside your application whether your app is running
 in Debug Mode or Normal Mode?
 
 Thanks.
 -- 
 View this message in context: http://www.nabble. com/Debug-
 mode-or-normal- mode--tp19739663 p19739663. html
 Sent from the FlexCoders mailing list archive at Nabble.com.
 
  
 
 
   Bollywood news, movie reviews, film trailers and more! Go to
 http://in.movies.yahoo.com/
 

-- 
View this message in context: 
http://www.nabble.com/Debug-mode-or-normal-mode--tp19739663p19743307.html
Sent from the FlexCoders mailing list archive at Nabble.com.



[flexcoders] Flex poster and Lynda.com free trial

2008-09-30 Thread hworke

  Hello every one. Did you get a free 1 month
  lynda.com subscription offer flier with the
  flex 3 and AIR posters? If so, could you please
  let me know the URL where I need to go to
  redeem this new Flex 3 buyer offer. Unfortunately
  I lost my flier but I wrote down the offer
  code.

  Best regards...



[flexcoders] Re: Upload file to server from AIR app

2008-09-30 Thread maximecowez
The File() constructor does take a String as an argument, but it has
to be formatted correctly. Take a look in the docs:
http://livedocs.adobe.com/flash/9.0/ActionScriptLangRefV3/flash/filesystem/File.html#File()

Max

--- In flexcoders@yahoogroups.com, gilbert_mizrahi [EMAIL PROTECTED] wrote:

 I found the error is caused because 
 var fileToUpload:File = new File(path+captureTest.flv);
 is expecting a File object and not a String (path+captureTest.flv).
 
 The problem I have is that I have no idea what constitutes a File
 Object. Using the File.browse the file selected passed an event and
 the upload method can take thee File object as event.target, but again
 I don't know how that object is made in case I want to create one
 without using the browse method for File.
 
 I traced the event.target, but it is giving me [Object,
 FileReference].Hence I am clueless.
 
 Gilbert
 
 
 --- In flexcoders@yahoogroups.com, Tom Chiverton tom.chiverton@
 wrote:
 
  On Monday 29 Sep 2008, gilbert_mizrahi wrote:
   I am getting a I/O Error: Error #2038.
  
  What's the full text and stack trace ?
  
  -- 
  Tom Chiverton
  Helping to adaptively brand interfaces
  
  
  
  
  
  This email is sent for and on behalf of Halliwells LLP.
  
  Halliwells LLP is a limited liability partnership registered in
 England and Wales under registered number OC307980 whose registered
 office address is at Halliwells LLP, 3 Hardman Square, Spinningfields,
 Manchester, M3 3EB.  A list of members is available for inspection at
 the registered office. Any reference to a partner in relation to
 Halliwells LLP means a member of Halliwells LLP.  Regulated by The
 Solicitors Regulation Authority.
  
  CONFIDENTIALITY
  
  This email is intended only for the use of the addressee named above
 and may be confidential or legally privileged.  If you are not the
 addressee you must not read it and must not use any information
 contained in nor copy it nor inform any person other than Halliwells
 LLP or the addressee of its existence or contents.  If you have
 received this email in error please delete it and notify Halliwells
 LLP IT Department on 0870 365 2500.
  
  For more information about Halliwells LLP visit www.halliwells.com.
 





Re: [flexcoders] Flex poster and Lynda.com free trial

2008-09-30 Thread Paul Andrews
Hmm. I've heard talk of this fabled Flex 3 poster yet haven't seen any info 
about how to get one. I had thought it might happen automagically when I 
upgraded to Flex 3 from Flex 2 (some time ago), but it didn't. Go on give me 
a clue..  ;-)

Paul
- Original Message - 
From: hworke [EMAIL PROTECTED]
To: flexcoders@yahoogroups.com
Sent: Tuesday, September 30, 2008 3:31 PM
Subject: [flexcoders] Flex poster and Lynda.com free trial



  Hello every one. Did you get a free 1 month
  lynda.com subscription offer flier with the
  flex 3 and AIR posters? If so, could you please
  let me know the URL where I need to go to
  redeem this new Flex 3 buyer offer. Unfortunately
  I lost my flier but I wrote down the offer
  code.

  Best regards...


 

 --
 Flexcoders Mailing List
 FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 Alternative FAQ location: 
 https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
 Search Archives: 
 http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups 
 Links



 



[flexcoders] AIR release build: how to deal with huge assets?

2008-09-30 Thread George
Hey guys,

The AIR application I'm working with have huge assets, say, big number 
of videos more than two gigabytes. I tried to build a release version 
with everything but failed to install that .air.

Maybe I should make a small .air not includes any assets. After it 
installed by clients, ask them to install external 'contents' zip file 
with all assets?

Regular desktop application could have several packages, like one 
application CD and contents CD and installed in one installation 
process. Can AIR support this? Did I miss something?

Thanks,
George


[flexcoders] Resolved Re: Have a question about Weborb

2008-09-30 Thread timgerr
I am learning, what you want to do is download Weborb and put your
browser on the root of that directory.  There is an example tab that
you will have to crate a database (with the given SLQ file).  That is
how I learned.  I have to do a writeup on what I have learned to a
group of people I will send that out when it is finished.

timgerr

--- In flexcoders@yahoogroups.com, bhaq1972 [EMAIL PROTECTED] wrote:

 hi Tim
 
 I'd like to try out you've done. Is there a tutorial anywhere you 
 can recomend.
 
 regadrs
 Bod
 




[flexcoders] Resolved Re: Have a question about Weborb

2008-09-30 Thread timgerr
Mark I was looking for somthing like that last night at about 2am.  I
found somthing like that at
http://www.experts-exchange.com/Web_Development/Web_Languages-Standards/Flex/Q_23267099.html
in the guys script.

Mark, I cannot tell you how much thanks I want to give you.

Thank,
timgerr


--- In flexcoders@yahoogroups.com, Mark Piller [EMAIL PROTECTED] wrote:

 Hi Tim,
 
 Glad you figured it out. There's one minor change I would recommend:
 when you call any of the find methods, you're always getting an
 object (or a collection) back. We tried to simplify the programming
 model, however the async nature of Flex's client/server integration is
 always there. So even though you get back an object out of the find
 calls, initially that object does not have the data. When the client
 receives the data from the server, the same instance WebORB returns to
 you is updated with the data. As a result, it is recommended to make
 sure you actually got the data before you make any changes. Here's how
 you can do it:
 
 _master = ActiveRecords.Test.findByIdAndName('6','tessa');
 _master.addEventListener( loaded, gotTest );
 
 public function gotTest( evt:DynamicLoadEvent ):void
 {
   var testObj:Test = (evt.data as ArrayCollection)[0] as Test;
   testObj.Email = tessa@;
   testObj.Name = tessa;
 }
 
 Cheers,
 Mark
 
 




[flexcoders] Movable content

2008-09-30 Thread timgerr
I was wondering if there was a way to have flex content dynamically
place it's self in the center of the screen no matter what the screen
resolution is.

Here is what I mean, I have a login pane that I want to be always be
in center of the screen, can stuff dynamically move?

Thanks for the information 



Re: [flexcoders] Movable content

2008-09-30 Thread Brendan Meutzner
verticalCenter=0 and horizontalCenter=0

On Tue, Sep 30, 2008 at 10:02 AM, timgerr [EMAIL PROTECTED] wrote:

   I was wondering if there was a way to have flex content dynamically
 place it's self in the center of the screen no matter what the screen
 resolution is.

 Here is what I mean, I have a login pane that I want to be always be
 in center of the screen, can stuff dynamically move?

 Thanks for the information

  




-- 
Brendan Meutzner
http://www.meutzner.com/blog/


[flexcoders] Re: Movable content

2008-09-30 Thread timgerr
Thanks,
That did it.

--- In flexcoders@yahoogroups.com, Brendan Meutzner [EMAIL PROTECTED]
wrote:

 verticalCenter=0 and horizontalCenter=0
 
 On Tue, Sep 30, 2008 at 10:02 AM, timgerr [EMAIL PROTECTED] wrote:
 
I was wondering if there was a way to have flex content dynamically
  place it's self in the center of the screen no matter what the screen
  resolution is.
 
  Here is what I mean, I have a login pane that I want to be always be
  in center of the screen, can stuff dynamically move?
 
  Thanks for the information
 
   
 
 
 
 
 -- 
 Brendan Meutzner
 http://www.meutzner.com/blog/





[flexcoders] Re: Flex poster and Lynda.com free trial

2008-09-30 Thread nathanpdaniel
Lynda.com site:
  http://www.lynda.com/go/flex3

Fabled Flex 3 Posters:
  http://www.onflex.org/ted/2007/04/want-flex-api-posters.php

:D

--- In flexcoders@yahoogroups.com, Paul Andrews [EMAIL PROTECTED] wrote:

 Hmm. I've heard talk of this fabled Flex 3 poster yet haven't seen 
any info 
 about how to get one. I had thought it might happen automagically 
when I 
 upgraded to Flex 3 from Flex 2 (some time ago), but it didn't. Go 
on give me 
 a clue..  ;-)
 
 Paul
 - Original Message - 
 From: hworke [EMAIL PROTECTED]
 To: flexcoders@yahoogroups.com
 Sent: Tuesday, September 30, 2008 3:31 PM
 Subject: [flexcoders] Flex poster and Lynda.com free trial
 
 
 
   Hello every one. Did you get a free 1 month
   lynda.com subscription offer flier with the
   flex 3 and AIR posters? If so, could you please
   let me know the URL where I need to go to
   redeem this new Flex 3 buyer offer. Unfortunately
   I lost my flier but I wrote down the offer
   code.
 
   Best regards...
 
 
  
 
  --
  Flexcoders Mailing List
  FAQ: 
http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
  Alternative FAQ location: 
  https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-
446f-b4cf-1e62079f6847
  Search Archives: 
  http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! 
Groups 
  Links
 
 
 
 





Re: [flexcoders] Debug mode or normal mode?

2008-09-30 Thread Tom Chiverton
On Tuesday 30 Sep 2008, jitendra jain wrote:
 when your application is running on the server while in debug mode you will
 have the following address in your browser window 
 http://localhost:8081/myApp/main.html?debug=true

That's the default, but it could be anything. The URL parameter 
doesn't 'enable' anything.
  
The only sure way is the right click menu to see if you have a debug player, 
or see Capabilities in the reference.

-- 
Tom Chiverton
Helping to interactively compete back-end fourth-generation front-end 
revolutionary infrastructures





This email is sent for and on behalf of Halliwells LLP.

Halliwells LLP is a limited liability partnership registered in England and 
Wales under registered number OC307980 whose registered office address is at 
Halliwells LLP, 3 Hardman Square, Spinningfields, Manchester, M3 3EB.  A list 
of members is available for inspection at the registered office. Any reference 
to a partner in relation to Halliwells LLP means a member of Halliwells LLP.  
Regulated by The Solicitors Regulation Authority.

CONFIDENTIALITY

This email is intended only for the use of the addressee named above and may be 
confidential or legally privileged.  If you are not the addressee you must not 
read it and must not use any information contained in nor copy it nor inform 
any person other than Halliwells LLP or the addressee of its existence or 
contents.  If you have received this email in error please delete it and notify 
Halliwells LLP IT Department on 0870 365 2500.

For more information about Halliwells LLP visit www.halliwells.com.



--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Alternative FAQ location: 
https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! 
Groups Links

* To visit your group on the web, go to:
http://groups.yahoo.com/group/flexcoders/

* Your email settings:
Individual Email | Traditional

* To change settings online go to:
http://groups.yahoo.com/group/flexcoders/join
(Yahoo! ID required)

* To change settings via email:
mailto:[EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED]

* To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]

* Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/



Re: [flexcoders] URLRequest, ByteArray, and the 0 byte

2008-09-30 Thread Maciek Sakrejda
That is not what the documentation says:

If the object is a ByteArray object, the binary data of the ByteArray
object is used as POST data. For GET, data of ByteArray type is not
supported. Also, data of ByteArray type is not supported for
FileReference.upload() and FileReference.download().

from
http://livedocs.adobe.com/flex/3/langref/flash/net/URLRequest.html#data

I was doing a POST with a ByteArray as the data. Again, this works
correctly under Windows and OS X, so I'm pretty sure this is a Player
bug under Linux.
-- 
Maciek Sakrejda
Truviso, Inc.
http://www.truviso.com

-Original Message-
From: jitendra jain [EMAIL PROTECTED]
Reply-To: flexcoders@yahoogroups.com
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] URLRequest, ByteArray, and the 0 byte
Date: Tue, 30 Sep 2008 09:13:59 +0530 (IST)


All the request data that is send is String. 
 
Thanks,

with Regards,
Jitendra Jain



- Original Message 
From: Troy Gilbert [EMAIL PROTECTED]
To: flexcoders@yahoogroups.com
Sent: Tuesday, 30 September, 2008 9:03:14 AM
Subject: Re: [flexcoders] URLRequest, ByteArray, and the 0 byte

 We're also working around this by Base64-encoding, but this is clearly
 less than ideal. It definitely seems like a Flash Player bug. We ran
 into this when doing AlivePDF REMOTE saves (i.e., bouncing the file
off
 the server). Do you know when you ran into this, Troy? I tested our
 particular problem on Windows and on OS X last week, and neither had
the
 issue.

// this byte array probably needs to be bigger to actually end up
// with a zero-byte in the compressed data
var bytes:ByteArray = new ByteArray();
bytes.writeUTFBytes (This is just some filler text.);
bytes.compress( );

// URLVariables automatically encodes its dynamic properties
// using a www-form-url- encode format, i.e. %12%34%56%78% 90
var variables:URLVariab les = new URLVariables( );
variables.username = troy;
variables.action = save;
variables.data = bytes;

// when the request is made, 'variables' is converted to a string
// the nulls in the ByteArray are not escaped, so they truncate the data
var request:URLRequest = new URLRequest(http://mywebserver/ myscript.
php);
request.method = URLRequestMethod. POST;
request.data = variables;

// Troy.






Add more friends to your messenger and enjoy! Invite them now.


 




Re: [flexcoders] Re: Flex poster and Lynda.com free trial

2008-09-30 Thread Vivian Richard
   Hey Paul, Please take a look at Nathan's link. The posters
   do not come unless you request for it!!! You need your flex
   builder's serial number to request for it. Please go there and
   submit a request for it.

   By the way thanks Nathan.

   Regards,









On Tue, Sep 30, 2008 at 8:34 AM, nathanpdaniel [EMAIL PROTECTED] wrote:
 Lynda.com site:
 http://www.lynda.com/go/flex3

 Fabled Flex 3 Posters:
 http://www.onflex.org/ted/2007/04/want-flex-api-posters.php

 :D

 --- In flexcoders@yahoogroups.com, Paul Andrews [EMAIL PROTECTED] wrote:

 Hmm. I've heard talk of this fabled Flex 3 poster yet haven't seen
 any info
 about how to get one. I had thought it might happen automagically
 when I
 upgraded to Flex 3 from Flex 2 (some time ago), but it didn't. Go
 on give me
 a clue.. ;-)

 Paul
 - Original Message -
 From: hworke [EMAIL PROTECTED]
 To: flexcoders@yahoogroups.com
 Sent: Tuesday, September 30, 2008 3:31 PM
 Subject: [flexcoders] Flex poster and Lynda.com free trial


 
  Hello every one. Did you get a free 1 month
  lynda.com subscription offer flier with the
  flex 3 and AIR posters? If so, could you please
  let me know the URL where I need to go to
  redeem this new Flex 3 buyer offer. Unfortunately
  I lost my flier but I wrote down the offer
  code.
 
  Best regards...
 
 
  
 
  --
  Flexcoders Mailing List
  FAQ:
 http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
  Alternative FAQ location:
  https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-
 446f-b4cf-1e62079f6847
  Search Archives:
  http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo!
 Groups
  Links
 
 
 
 


 


Re: [flexcoders] URLRequest, ByteArray, and the 0 byte

2008-09-30 Thread Maciek Sakrejda
Ah, interesting. This seems related, but different. I was just setting
URLRequest.data to a ByteArray directly. In your case, if I understand
application/x-www-form-urlencoded correctly, then zero bytes should just
be replaced with %00. Have you filed a bug? I'd like to add that to my
Adobe JIRA watch list if so.
-- 
Maciek Sakrejda
Truviso, Inc.
http://www.truviso.com

-Original Message-
From: Troy Gilbert [EMAIL PROTECTED]
Reply-To: flexcoders@yahoogroups.com
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] URLRequest, ByteArray, and the 0 byte
Date: Mon, 29 Sep 2008 22:33:14 -0500

 We're also working around this by Base64-encoding, but this is clearly
 less than ideal. It definitely seems like a Flash Player bug. We ran
 into this when doing AlivePDF REMOTE saves (i.e., bouncing the file
off
 the server). Do you know when you ran into this, Troy? I tested our
 particular problem on Windows and on OS X last week, and neither had
the
 issue.

// this byte array probably needs to be bigger to actually end up
// with a zero-byte in the compressed data
var bytes:ByteArray = new ByteArray();
bytes.writeUTFBytes(This is just some filler text.);
bytes.compress();

// URLVariables automatically encodes its dynamic properties
// using a www-form-url-encode format, i.e. %12%34%56%78%90
var variables:URLVariables = new URLVariables();
variables.username = troy;
variables.action = save;
variables.data = bytes;

// when the request is made, 'variables' is converted to a string
// the nulls in the ByteArray are not escaped, so they truncate the data
var request:URLRequest = new
URLRequest(http://mywebserver/myscript.php;);
request.method = URLRequestMethod.POST;
request.data = variables;

// Troy.



 




[flexcoders] More questions on weborb, creating my own services

2008-09-30 Thread timgerr
OK, so I have created this hello world service and then had WebOrb
create the code I see in the actionscript comments This:

(If using Model-View-Controller)
- Modify the constructor of the class below to accept the controller
object
- Modify response handlers to pass return values to the controller

(if not using MVC)
- Modify the constructor of the class below to accept your View object
- Modify response handlers to display the result directly in the View

I am not useing MVC so I have to use the 2nd commented option.  the
problem is I am not sure what to do, someone help me?

Here is my PHP code:
?php
class HelloWorld {
function ShowMe()
{
return Tom Jones;
}
function ShowName($name)
{
return 'Hello ' . $name;
}
}
?
So I have 2 methods, ShowMe and ShowName.

Here is my as code:
  package comp.HelloWorld
  {
  import mx.rpc.remoting.RemoteObject;
  import mx.controls.Alert;
  import mx.rpc.events.ResultEvent;
  import mx.rpc.events.FaultEvent;
  import mx.rpc.AsyncToken;
   import mx.rpc.IResponder;
  
  import comp.HelloWorld.vo.*;

  public class HelloWorld
  {
  private var remoteObject:RemoteObject;
  private var model:HelloWorldModel;

  public function HelloWorld( model:HelloWorldModel = null )
  {
  remoteObject  = new RemoteObject(GenericDestination);
  remoteObject.source = comp.HelloWorld.HelloWorld;

  remoteObject.ShowMe.addEventListener(result,ShowMeHandler);
  
remoteObject.ShowName.addEventListener(result,ShowNameHandler);
  remoteObject.addEventListener(fault, onFault);
  
   if( model == null )
  model = new HelloWorldModel();
  
  this.model = model;
  
  }

  public function setCredentials( userid:String, password:String
):void
  {
remoteObject.setCredentials( userid, password );
  }

  public function GetModel():HelloWorldModel
  {
return this.model;
  }   

  public function ShowMe(  responder:IResponder = null):void
 {
  var asyncToken:AsyncToken = remoteObject.ShowMe();
  
if( responder != null )
asyncToken.addResponder( responder );
}

  public function ShowName( name:String, responder:IResponder =
null):void
 {
  var asyncToken:AsyncToken = remoteObject.ShowName( name);
  
if( responder != null )
asyncToken.addResponder( responder );
}
  public virtual function ShowMeHandler(event:ResultEvent):void 
  {
  var returnValue:Object = event.result as Object;
  model.ShowMe = event.result as Object;
  }

  public virtual function ShowNameHandler(event:ResultEvent):void 
  {
  var returnValue:Object = event.result as Object;
  model.ShowName = event.result as Object;
  }

 public function onFault (event:FaultEvent):void
{
Alert.show(event.fault.faultString, Error);
}
  }

  }

I get an error on: import comp.HelloWorld.vo.* (not sure what this is
or how to create it)


And here is another chunck of code that I have to modify

 public virtual function ShowMeHandler(event:ResultEvent):void 
{
 var returnValue:Object = event.result as Object;
 model.ShowMe = event.result as Object;
}

public virtual function ShowNameHandler(event:ResultEvent):void 
{
 var returnValue:Object = event.result as Object;
 model.ShowName = event.result as Object;
}

I get an error:
(Severity and Description   PathResourceLocation
Creation Time   Id
1119: Access of possibly undefined property ShowMe through a reference
with static type comp.HelloWorld:HelloWorldModel.
WeborbHelloworld/src/comp/HelloWorldHelloWorld.as   line 95
1222790567712   8938) 

On these 2 lines of code:
model.ShowMe = event.result as Object;
model.ShowName = event.result as Object;

I just want to return that stuff, what do I have to do in order to fix
the errors.

Thanks,
timgerr




[flexcoders] Re: Debug mode or normal mode?

2008-09-30 Thread valdhor
Check out flash.system.Capabilities.isDebugger.


--- In flexcoders@yahoogroups.com, Manu Dhanda [EMAIL PROTECTED]
wrote:


 Hii guyz,

 How do u identify from inside your application whether your app is
running
 in Debug Mode or Normal Mode?

 Thanks.
 --
 View this message in context:
http://www.nabble.com/Debug-mode-or-normal-mode--tp19739663p19739663.htm\
l
 Sent from the FlexCoders mailing list archive at Nabble.com.





RE: [flexcoders] Re: passing complex objects through LocalConnection

2008-09-30 Thread Jonathon Stierman
More fun - Correction:

 

If you are using a Loader to load in the receiver SWF (and the receiver
SWF contains registerClassAlias code), then your sender SWF does not
need the registerClassAlias code.

 

If your SWFs do not load eachother, then you *do* need the
registerClassAlias code in both the sender and receiving swf.

 

Jonathon

 

From: Jonathon Stierman 
Sent: Monday, September 29, 2008 11:40 AM
To: 'flexcoders@yahoogroups.com'
Subject: RE: [flexcoders] Re: passing complex objects through
LocalConnection

 

I've finally figured out what was going on with my null issues -
hopefully this will help someone else out down the road. 

 

All of the complex objects' properties must be made *public* for
de-serialization to work. Private and protected properties are *not*
re-inserted into the transferred object. 

 

That was what was causing my complex object to be filled with null
values.  Also helpful to know:

 

You do *not* need to register basic AS3 classes (uint, Array, Number,
Boolean, etc).  

 

But you *do* need to register any nested complex object classes.

 

The registerClassAlias code *must* be made in the receiving swf.  Adding
it to the sending swf is not necessary.  

 

Jonathon



RE: [flexcoders] DataVisualization RSL Issues

2008-09-30 Thread Battershall, Jeff
I've narrowed this down a bit.  First of all, the behavior is restricted
to the ADG and to the rendering of row data. Secondly, the AGD seems to
not render fonts that have been imported.  If I reference a system font
(without importing it) it renders.  If I choose to import that font, it
won't render. I'll try to come up with a replicable test case with
sample code but it would seem to be a bug with the
datavisualization_3.1.0.2710.swz.

-Original Message-
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Battershall, Jeff
Sent: Tuesday, September 30, 2008 10:09 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] DataVisualization RSL Issues


Trying to use the datavisualization_3.1.0.2710.swz as an RSL. I've
worked through the stream errors and I've used the most recent version
avaiable from
http://blogs.adobe.com/flex/archives/2008/09/updated_rsl_for_flex_data_v
isu.html.

However, row text is not rendering in an AdvancedDataGrid I'm using for
a report. If I merge into code, I don't get that issue.

Any ideas?

Jeff Battershall
Application Architect
Dow Jones Indexes
[EMAIL PROTECTED]
(609) 520-5637 (p)
(484) 477-9900 (c)



--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Alternative FAQ location:
https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-
1e62079f6847
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
Links





[flexcoders] Print Image and Text Problem

2008-09-30 Thread wwwpl
I am trying to print a text header with an image control.  I scale the 
image to fit the page, but the text gets scaled also.  Is there a way 
to scale the image without the text scaling as well.  I am printing as 
a bitmap.  Here is the code:





?xml version=1.0 encoding=utf-8?

mx:VBox xmlns:mx=http://www.adobe.com/2006/mxml;
   backgroundColor=#FF
   paddingBottom=10 paddingLeft=10 paddingRight=10 
paddingTop=10
   initialize=initRes()
   visible=false

   mx:Script
  ![CDATA[
import mx.graphics.ImageSnapshot;
import mx.formatters.DateFormatter;
 import mx.printing.FlexPrintJob;
 import mx.printing.FlexPrintJobScaleType;
 import 
org.familysearch.recordsearch.web.view.common.GraphicAssets;
 import 
org.familysearch.recordsearch.web.util.ResourceLocator2;

 private const FONTSIZE:int = 16;
 public var printSelection:Boolean = true;
 public var printRectangle:Rectangle;
 
 [Bindable] private var resources:ResourceLocator2;
 private function initRes() : void
 {
   resources = ResourceLocator2.getResource(Images, 
resourcesLoaded);
 }
 
  private function resourcesLoaded(event:* = null) : void
  {
  }

 private function printImage(event:* =null) : void
 {
var printJob:FlexPrintJob = new FlexPrintJob();
var currentDate:Date = new Date();
var formatter:DateFormatter = new DateFormatter();
formatter.formatString= D, ;
date.text = resources.strings.imagesPrinted 
+formatter.format(currentDate);
if (printJob.start())
{
   var citationScaleFactor:Number = 1.0;
   var w:Number = img.contentWidth;
   var h:Number = img.contentHeight;
   var pjw:Number = printJob.pageWidth;
   var pjh:Number = printJob.pageHeight;
   var ws:Number = w/pjw;   //width scale factor
   var hs:Number = h/pjh;   //height scale factor

   if ( (w = pjw  h = pjh) ||
(w  pjw  h  pjw) )
   {
  // both dimensions need to be scaled,
  // choose the smallest scaling factor
  citationScaleFactor = ((wshs)?ws:hs);
   }
   else
   {
  citationScaleFactor = ((wpjw)?ws:hs);
   }

   var fntSize:int = FONTSIZE*citationScaleFactor;
   var citationText:String = 
resources.strings.imagesCollection +citation.text;
   citation.text = citationText;
   citation.setStyle(fontSize,fntSize);
   date.setStyle(fontSize,(fntSize-20));
   printJob.addObject(this, 
FlexPrintJobScaleType.SHOW_ALL);
   printJob.send();
}
 }

  ]]
   /mx:Script
   
  
   
mx:Grid width=100%
mx:GridRow width=100% height=100%
mx:GridItem width=100% height=100%
   mx:Image  id=familysearch 
source={GraphicAssets.LOGO_PRINT}/ 
/mx:GridItem
/mx:GridRow
mx:GridRow width=100% height=100%
  mx:GridItem width=100% height=100%
mx:Label  id=citation  width=100% fontWeight=bold/ 
  /mx:GridItem
/mx:GridRow
mx:GridRow width=100% height=100%
  mx:GridItem width=100% height=100%
mx:Label  id=date   width=100% 
styleName=collectionSearchText / 
  /mx:GridItem
/mx:GridRow
/mx:Grid
   mx:Image id=img complete=printImage()/
   mx:Image id=selectedImg includeInLayout=false 
visible=false/

/mx:VBox






[flexcoders] [AD] SLF4Fx new project to integrate Flex logging api with Java logging api

2008-09-30 Thread dmotylev
SLF4Fx is an open source suite of Flex3 logging target that send messages to 
slf4fx server. 
The server writes all incoming messages to log using java Simple Logging Facade 
for Java 
(SLF4J). SLF4J works with all well-known java logging projects. 

SLF4Fx uses simple binary protocol to transfer log records between client and 
server. It 
provides simple authentication mechanism that could be used to log specific 
application 
instance.

More details on http://code.google.com/p/slf4fx/



[flexcoders] Template Engine for Flash?

2008-09-30 Thread Weyert de Boer
Hello!

Does anyone know some simple text-based template engine for Flash? I 
would like to generate some text files based on code snippets/templates 
in my Flash project.
Only I am curious if anyone know some simple template engine written in 
ActionScript which might support token replacement (e.g. var1 = my 
value) or even some
conditional constructs, like if-blocks.

Anyone aware of such thing?

Yours,
Weyert


Re: [flexcoders] URLRequest, ByteArray, and the 0 byte

2008-09-30 Thread Troy Gilbert
 Ah, interesting. This seems related, but different. I was just setting
 URLRequest.data to a ByteArray directly. In your case, if I understand
 application/x-www-form-urlencoded correctly, then zero bytes should just
 be replaced with %00. Have you filed a bug? I'd like to add that to my
 Adobe JIRA watch list if so.

It does work correctly if you set URLRequest.data to a ByteArray, but
in my example I was setting URLVariables.data (which could be called
anything, it's just a named property) to a ByteArray, and URLVariables
(apparently) calls toString on each property's value *before*
URL-encoding them, which is the problem. So, not necessarily a bug,
just an undocumented feature of the implementation. Since
URLVariables does the encoding, I expected/assumed (since it wasn't
explicitly documented) it would it encode the ByteArray as bytes, %00
and all.

Troy.


[flexcoders] Re: Upload file to server from AIR app

2008-09-30 Thread gilbert_mizrahi
Ok. I was able to solve the problem creating a temporary  newFile:File
object and copying the content of the file I wanted to upload. Then, I
upload the newFile.

Thanks for the help.

Gilbert

--- In flexcoders@yahoogroups.com, maximecowez [EMAIL PROTECTED] wrote:

 The File() constructor does take a String as an argument, but it has
 to be formatted correctly. Take a look in the docs:

http://livedocs.adobe.com/flash/9.0/ActionScriptLangRefV3/flash/filesystem/File.html#File()
 
 Max
 
 --- In flexcoders@yahoogroups.com, gilbert_mizrahi mizrahi@ wrote:
 
  I found the error is caused because 
  var fileToUpload:File = new File(path+captureTest.flv);
  is expecting a File object and not a String (path+captureTest.flv).
  
  The problem I have is that I have no idea what constitutes a File
  Object. Using the File.browse the file selected passed an event and
  the upload method can take thee File object as event.target, but again
  I don't know how that object is made in case I want to create one
  without using the browse method for File.
  
  I traced the event.target, but it is giving me [Object,
  FileReference].Hence I am clueless.
  
  Gilbert
  
  
  --- In flexcoders@yahoogroups.com, Tom Chiverton tom.chiverton@
  wrote:
  
   On Monday 29 Sep 2008, gilbert_mizrahi wrote:
I am getting a I/O Error: Error #2038.
   
   What's the full text and stack trace ?
   
   -- 
   Tom Chiverton
   Helping to adaptively brand interfaces
   
   
   
   
   
   This email is sent for and on behalf of Halliwells LLP.
   
   Halliwells LLP is a limited liability partnership registered in
  England and Wales under registered number OC307980 whose registered
  office address is at Halliwells LLP, 3 Hardman Square, Spinningfields,
  Manchester, M3 3EB.  A list of members is available for inspection at
  the registered office. Any reference to a partner in relation to
  Halliwells LLP means a member of Halliwells LLP.  Regulated by The
  Solicitors Regulation Authority.
   
   CONFIDENTIALITY
   
   This email is intended only for the use of the addressee named above
  and may be confidential or legally privileged.  If you are not the
  addressee you must not read it and must not use any information
  contained in nor copy it nor inform any person other than Halliwells
  LLP or the addressee of its existence or contents.  If you have
  received this email in error please delete it and notify Halliwells
  LLP IT Department on 0870 365 2500.
   
   For more information about Halliwells LLP visit www.halliwells.com.
  
 





[flexcoders] What would be the equivalent asp.net script of this PHP one (to upload a file)

2008-09-30 Thread gilbert_mizrahi
I have been playing around uploading files from Flex/AIR to php with
this script:

?php 
$tempFile = $_FILES['Filedata']['tmp_name'];
$fileName = $_FILES['Filedata']['name'];

if(move_uploaded_file($tempFile, ./videos/ . $fileName)) {
echo The file .  basename( $_FILES['uploadedfile']['name']). 
 has been uploaded successfully;
} else{
echo There was an error uploading the file, please try again!;
}
?

What would be the equivalent for asp.net?

Gilbert



Re: [flexcoders] URLRequest, ByteArray, and the 0 byte

2008-09-30 Thread Maciek Sakrejda
I'm not sure I agree--if it's a feature of the implementation that
prevents valid use of the API, that sounds like a bug ;). As far as I
can tell, a null byte should be encoded to %00 in the
application/x-form-urlencoded scheme and is a valid character. If
calling toString() on a ByteArray truncates it, then the implementation
shouldn't be doing that. String does seem to handle null bytes correctly
in other cases (try trace(String.fromCharCode(1,0,2).length) ), so there
should be no problem here.

Also:

 It does work correctly if you set URLRequest.data to a ByteArray

Not in Linux Flash Player--that was my original point.

Thanks for the feedback, though--it's always interesting to dive into
this low-level stuff.
-- 
Maciek Sakrejda
Truviso, Inc.
http://www.truviso.com

-Original Message-
From: Troy Gilbert [EMAIL PROTECTED]
Reply-To: flexcoders@yahoogroups.com
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] URLRequest, ByteArray, and the 0 byte
Date: Tue, 30 Sep 2008 11:57:09 -0500

 Ah, interesting. This seems related, but different. I was just setting
 URLRequest.data to a ByteArray directly. In your case, if I understand
 application/x-www-form-urlencoded correctly, then zero bytes should
just
 be replaced with %00. Have you filed a bug? I'd like to add that to my
 Adobe JIRA watch list if so.

It does work correctly if you set URLRequest.data to a ByteArray, but
in my example I was setting URLVariables.data (which could be called
anything, it's just a named property) to a ByteArray, and URLVariables
(apparently) calls toString on each property's value *before*
URL-encoding them, which is the problem. So, not necessarily a bug,
just an undocumented feature of the implementation. Since
URLVariables does the encoding, I expected/assumed (since it wasn't
explicitly documented) it would it encode the ByteArray as bytes, %00
and all.

Troy.



 




Re: [flexcoders] What would be the equivalent asp.net script of this PHP one (to upload a file)

2008-09-30 Thread Fidel Viegas
On Tue, Sep 30, 2008 at 6:16 PM, gilbert_mizrahi [EMAIL PROTECTED] wrote:
 I have been playing around uploading files from Flex/AIR to php with
 this script:

 ?php
 $tempFile = $_FILES['Filedata']['tmp_name'];
 $fileName = $_FILES['Filedata']['name'];

 if(move_uploaded_file($tempFile, ./videos/ . $fileName)) {
 echo The file . basename( $_FILES['uploadedfile']['name']).
  has been uploaded successfully;
 } else{
 echo There was an error uploading the file, please try again!;
 }
 ?

 What would be the equivalent for asp.net?

Hi Gilbert,

Before posting a question to this user group, I advise you to search
your answers on google. If you don't find them there, then you post
your question here. Usually, people do not answer to questions such as
the one you have just posted, because they can be easily found through
a google search.
Here are a few links I found using the words uploading with asp.net:

http://www.codeproject.com/KB/aspnet/fileupload.aspx
http://www.wrox.com/WileyCDA/Section/id-292158.html
http://www.4guysfromrolla.com/webtech/091201-1.shtml
http://www.ondotnet.com/pub/a/dotnet/2002/04/01/asp.html
http://www.aspheute.com/english/2802.asp

Hope that helps.

All the best,

Fidel.


Re: [flexcoders] DataVisualization RSL Issues

2008-09-30 Thread Matt Chotin
Jeff, were you suing Modules as well?  Is this your bug?  
http://bugs.adobe.com/jira/browse/FLEXDMV-1719

Matt


On 9/30/08 9:37 AM, Battershall, Jeff [EMAIL PROTECTED] wrote:




I've narrowed this down a bit.  First of all, the behavior is restricted
to the ADG and to the rendering of row data. Secondly, the AGD seems to
not render fonts that have been imported.  If I reference a system font
(without importing it) it renders.  If I choose to import that font, it
won't render. I'll try to come up with a replicable test case with
sample code but it would seem to be a bug with the
datavisualization_3.1.0.2710.swz.

-Original Message-
From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com  
[mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com ] On
Behalf Of Battershall, Jeff
Sent: Tuesday, September 30, 2008 10:09 AM
To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
Subject: [flexcoders] DataVisualization RSL Issues

Trying to use the datavisualization_3.1.0.2710.swz as an RSL. I've
worked through the stream errors and I've used the most recent version
avaiable from
http://blogs.adobe.com/flex/archives/2008/09/updated_rsl_for_flex_data_v
isu.html.

However, row text is not rendering in an AdvancedDataGrid I'm using for
a report. If I merge into code, I don't get that issue.

Any ideas?

Jeff Battershall
Application Architect
Dow Jones Indexes
[EMAIL PROTECTED] mailto:jeff.battershall%40dowjones.com
(609) 520-5637 (p)
(484) 477-9900 (c)



--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Alternative FAQ location:
https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-
1e62079f6847
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups
Links





Re: [flexcoders] What would be the equivalent asp.net script of this PHP one (to upload a file)

2008-09-30 Thread Derrick Anderson
do u know where u posted this?

On Tue, Sep 30, 2008 at 1:16 PM, gilbert_mizrahi [EMAIL PROTECTED] wrote:

   I have been playing around uploading files from Flex/AIR to php with
 this script:

 ?php
 $tempFile = $_FILES['Filedata']['tmp_name'];
 $fileName = $_FILES['Filedata']['name'];

 if(move_uploaded_file($tempFile, ./videos/ . $fileName)) {
 echo The file . basename( $_FILES['uploadedfile']['name']).
  has been uploaded successfully;
 } else{
 echo There was an error uploading the file, please try again!;
 }
 ?

 What would be the equivalent for asp.net?

 Gilbert

  



[flexcoders] Re: Flex poster and Lynda.com free trial

2008-09-30 Thread nathanpdaniel
No problem! :D  I've had them for a few months now but we're moving 
to a new office in the near future so they're still rolled up in the 
tube!  One day they'll be out on the wall - I've got dedicated space 
in the new office!  I'll be the cool kid with posters on the 
wall... :D

--- In flexcoders@yahoogroups.com, Vivian Richard [EMAIL PROTECTED] 
wrote:

Hey Paul, Please take a look at Nathan's link. The posters
do not come unless you request for it!!! You need your flex
builder's serial number to request for it. Please go there and
submit a request for it.
 
By the way thanks Nathan.
 
Regards,
 
 
 
 
 
 
 
 
 
 On Tue, Sep 30, 2008 at 8:34 AM, nathanpdaniel [EMAIL PROTECTED] wrote:
  Lynda.com site:
  http://www.lynda.com/go/flex3
 
  Fabled Flex 3 Posters:
  http://www.onflex.org/ted/2007/04/want-flex-api-posters.php
 
  :D
 
  --- In flexcoders@yahoogroups.com, Paul Andrews paul@ wrote:
 
  Hmm. I've heard talk of this fabled Flex 3 poster yet haven't 
seen
  any info
  about how to get one. I had thought it might happen automagically
  when I
  upgraded to Flex 3 from Flex 2 (some time ago), but it didn't. Go
  on give me
  a clue.. ;-)
 
  Paul
  - Original Message -
  From: hworke kanpsack@
  To: flexcoders@yahoogroups.com
  Sent: Tuesday, September 30, 2008 3:31 PM
  Subject: [flexcoders] Flex poster and Lynda.com free trial
 
 
  
   Hello every one. Did you get a free 1 month
   lynda.com subscription offer flier with the
   flex 3 and AIR posters? If so, could you please
   let me know the URL where I need to go to
   redeem this new Flex 3 buyer offer. Unfortunately
   I lost my flier but I wrote down the offer
   code.
  
   Best regards...
  
  
   
  
   --
   Flexcoders Mailing List
   FAQ:
  http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
   Alternative FAQ location:
   https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-
  446f-b4cf-1e62079f6847
   Search Archives:
   http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo!
  Groups
   Links
  
  
  
  
 
 
 





[flexcoders] Format LI Bullets in htmlText

2008-09-30 Thread edlueze
I am trying to format a set of bullets within a Text control using
htmlText but the bullets seem to be really far apart (think of a
really big line-height). I can't seem to figure out how to modify the
style (CSS or inline) for the LI tag so that the line-height is smaller.

This is my MXML:

mx:Text
mx:htmlText
![CDATA[My bullets:
liBullet #1/li
liBullet #2/li
liBullet #3/li
]]
/mx:htmlText
/mx:Text

Any ideas?

Thanks in advance!



[flexcoders] Possible to get more information in a Send Failed error?

2008-09-30 Thread jennie_mai_nguyen
Hi there,

When I'm throwing an exception in a web filter before the request gets
processed by the Blaze MessageBroker servlet. I get a generic Send
Failed error. Is it possible to somehow access this exception
information? 

The work-around I have right now is using the pub/sub messaging
mechanism to setup an error listener, and then send notifications to
that service from the server when an error outside of any Blaze
request happens. Is there a better way to do this? 

Thanks,
Jennie 



[flexcoders] Re: Template Engine for Flash?

2008-09-30 Thread wesley.petrowski
StringUtil.substitute might help with the token replacement.

--- In flexcoders@yahoogroups.com, Weyert de Boer [EMAIL PROTECTED] wrote:

 Hello!
 
 Does anyone know some simple text-based template engine for Flash? I 
 would like to generate some text files based on code 
snippets/templates 
 in my Flash project.
 Only I am curious if anyone know some simple template engine written 
in 
 ActionScript which might support token replacement (e.g. var1 = my 
 value) or even some
 conditional constructs, like if-blocks.
 
 Anyone aware of such thing?
 
 Yours,
 Weyert




RE: [flexcoders] Re: FileReference to ByteArray

2008-09-30 Thread Tracy Spratt
The uploadCompleteData event has a data property that contains
whatever the server returns from the upload call.

 

Tracy

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of aytuganov
Sent: Tuesday, September 30, 2008 4:05 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: FileReference to ByteArray

 

Thanks Jon.
I discovered this issue and found the way to solve my task with java
servlet. But now I have other problem. 
I can add listeners for COMPLETE, IO_ERROR,HTTP_STATUS,
DataEvent.UPLOAD_COMPLETE_DATA events. But I can not find the way to
receive a respond from servlet with the generated filename if my file
that I have just uploaded.
Thanks in advance.

--- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
, Jon Bradley [EMAIL PROTECTED] wrote:

 
 On Sep 26, 2008, at 4:48 AM, aytuganov wrote:
 
  Does somebody know is it possible to select file using
  FileReference.browse() and than set it to ByteArray instance.
  (There is an object that has an ByteArray property. I have to set
this
  property and send the object to server using RemoteObject - but it's
  not a matter)
 
 In Flash 10.
 
 You have no access to the content of a FileReference object or item 
 in any version of Flash earlier than v10. That's a resounding answer 
 of no.
 
 There may be ways to hack the HTTPHeader information to include 
 additional content information when the FileReference is uploaded. 
 Otherwise, you'll need to send that data separately to the server.
 
 good luck,
 
 jon


 



RE: [flexcoders] Format LI Bullets in htmlText

2008-09-30 Thread Tracy Spratt
Look into the LEADING property.

Tracy

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of edlueze
Sent: Tuesday, September 30, 2008 2:24 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Format LI Bullets in htmlText

 

I am trying to format a set of bullets within a Text control using
htmlText but the bullets seem to be really far apart (think of a
really big line-height). I can't seem to figure out how to modify the
style (CSS or inline) for the LI tag so that the line-height is smaller.

This is my MXML:

mx:Text
mx:htmlText
![CDATA[My bullets:
liBullet #1/li
liBullet #2/li
liBullet #3/li
]]
/mx:htmlText
/mx:Text

Any ideas?

Thanks in advance!

 



[flexcoders] Re: More questions on weborb, creating my own services

2008-09-30 Thread valdhor
This seems to be a convoluted way to do this.

I have created a simple example to show you how I use WebOrb.

On my server I have the WebORB directory at the root level. In the
Services directory I have a MyServices directory and in this directory I
have a ValueObjects directory. For this example I have two files:

=
TestNamesInVO.php:
?php
class TestNamesInVO
{
 public $FirstName;
 public $LastName;

 public function __construct($FirstName, $LastName)
 {
 $this-FirstName = $FirstName;
 $this-LastName = $LastName;
 }
}
?
=
TestNamesOutVO.php:
?php
class TestNamesOutVO
{
 public $FullName;

 public function __construct($FullName)
 {
 $this-FullName = $FullName;
 }
}
?
=

The constructors are there just to make it easier to create a new
object. They are optional.

In the MyServices directory I have a TestService.php file. This contains
all the functions available with this service.

=
TestService.php:
?php
class TestService
{
 function ShowMe()
 {
 return Tom Jones;
 }

 function ShowName($name)
 {
 return 'Hello ' . $name;
 }

 function ShowNames(TestNamesInVO $namesIn)
 {
 require_once(ValueObjects/TestNamesInVO.php);
 require_once(ValueObjects/TestNamesOutVO.php);

 $fullName = new TestNamesOutVO($namesIn-FirstName .   .
$namesIn-LastName);

 return $fullName;
 }
}
?
=

In flex I also have a ValueObjects folder underneath my src folder. This
folder contains the corresponding ActionScript files for the value
objects on the server:

=
TestNamesInVO.as:
package ValueObjects
{
 [RemoteClass(alias=MyServices.ValueObjects.TestNamesInVO)]
 [Bindable]
 public class TestNamesInVO
 {
 //instance variables
 private var _FirstName:String;
 private var _LastName:String;

 //accessor methods
 public function get FirstName():String {return _FirstName;}
 public function get LastName():String {return _LastName;}

 //mutator methods
 public function set FirstName(FirstName:String):void {_FirstName
= FirstName;}
 public function set LastName(LastName:String):void {_LastName =
LastName;}
 } // end class
}//end package
=
TestNamesOutVO.as:
package ValueObjects
{
 [RemoteClass(alias=MyServices.ValueObjects.TestNamesOutVO)]
 [Bindable]
 public class TestNamesOutVO
 {
 //instance variables
 private var _FullName:String;

 //accessor methods
 public function get FullName():String {return _FullName;}

 //mutator methods
 public function set FullName(FullName:String):void {_FullName =
FullName;}
 } // end class
}//end package
=

Note the RemoteClass metadata. This tells flex the location of the class
on the server that matches this class (In relation to the Services
directory).

Finally we have the Flex application that makes calls to functions
within this service.

=
WebORBExample.mxml:
?xml version=1.0 encoding=utf-8?
mx:Application xmlns:mx=http://www.adobe.com/2006/mxml;
layout=absolute
 creationComplete=onCreationComplete()
 mx:Script
 ![CDATA[
 import mx.messaging.channels.AMFChannel;
 import mx.messaging.ChannelSet;
 import mx.rpc.events.FaultEvent;
 import mx.rpc.events.ResultEvent;
 import mx.rpc.remoting.RemoteObject;
 import mx.managers.CursorManager;
 import mx.controls.Alert;
 import ValueObjects.TestNamesInVO;
 import ValueObjects.TestNamesOutVO;

 private var channelSet:ChannelSet;
 private var amfChannel:AMFChannel;
 private var testService:RemoteObject;

 private function onCreationComplete():void
 {
 channelSet = new ChannelSet();
 amfChannel = new AMFChannel(my-amf,
http://myserver/WebORB/weborb.php;);
 channelSet.addChannel(amfChannel);

 testService = new RemoteObject();
 testService.channelSet = channelSet;
 testService.destination = MyServices.TestService;
 testService.requestTimeout = 15;

 testService.ShowMe.addEventListener(ResultEvent.RESULT,
ShowMeHandler);


RE: [flexcoders] Format LI Bullets in htmlText

2008-09-30 Thread Ryan Graham

Also, try condenseWhite=true on the Text control...
 
HTH,
Ryan



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Tracy Spratt
Sent: Tuesday, September 30, 2008 11:53 AM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] Format LI Bullets in htmlText



Look into the LEADING property.

Tracy



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of edlueze
Sent: Tuesday, September 30, 2008 2:24 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Format LI Bullets in htmlText

I am trying to format a set of bullets within a Text control using
htmlText but the bullets seem to be really far apart (think of a
really big line-height). I can't seem to figure out how to modify the
style (CSS or inline) for the LI tag so that the line-height is smaller.

This is my MXML:

mx:Text
mx:htmlText
![CDATA[My bullets:
liBullet #1/li
liBullet #2/li
liBullet #3/li
]]
/mx:htmlText
/mx:Text

Any ideas?

Thanks in advance!

 


This message is private and confidential. If you have received it in error, 
please notify the sender and remove it from your system.

[flexcoders] Re: What would be the equivalent asp.net script of this PHP one (to upload a file)

2008-09-30 Thread gilbert_mizrahi
Hi Fidel,

Thanks for the links. I did search before, but I don't know much about
asp.net, so nothing looked like the equivalent to the php script I
posted. Hence, my asking for help.

Hi Derrick,
Yes, I know this is a flex list. Even though it seems my question was
not related to Flex, The application I am working on is in Flex
(producing an AIR application), but I needed help with a server side
script. 
Does make sense? If not, I apologize for the trouble.

Gilbert 

--- In flexcoders@yahoogroups.com, Fidel Viegas [EMAIL PROTECTED]
wrote:

 On Tue, Sep 30, 2008 at 6:16 PM, gilbert_mizrahi [EMAIL PROTECTED] wrote:
  I have been playing around uploading files from Flex/AIR to php with
  this script:
 
  ?php
  $tempFile = $_FILES['Filedata']['tmp_name'];
  $fileName = $_FILES['Filedata']['name'];
 
  if(move_uploaded_file($tempFile, ./videos/ . $fileName)) {
  echo The file . basename( $_FILES['uploadedfile']['name']).
   has been uploaded successfully;
  } else{
  echo There was an error uploading the file, please try again!;
  }
  ?
 
  What would be the equivalent for asp.net?
 
 Hi Gilbert,
 
 Before posting a question to this user group, I advise you to search
 your answers on google. If you don't find them there, then you post
 your question here. Usually, people do not answer to questions such as
 the one you have just posted, because they can be easily found through
 a google search.
 Here are a few links I found using the words uploading with asp.net:
 
 http://www.codeproject.com/KB/aspnet/fileupload.aspx
 http://www.wrox.com/WileyCDA/Section/id-292158.html
 http://www.4guysfromrolla.com/webtech/091201-1.shtml
 http://www.ondotnet.com/pub/a/dotnet/2002/04/01/asp.html
 http://www.aspheute.com/english/2802.asp
 
 Hope that helps.
 
 All the best,
 
 Fidel.





[flexcoders] Re: Format LI Bullets in htmlText

2008-09-30 Thread edlueze
Thanks guys! I was definitely barking up the wrong tree on that one.
condenseWhite seems to have done the trick. The leading property had
surprisingly little effect.

--- In flexcoders@yahoogroups.com, Ryan Graham [EMAIL PROTECTED] wrote:

 
 Also, try condenseWhite=true on the Text control...
  
 HTH,
 Ryan
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of Tracy Spratt
 Sent: Tuesday, September 30, 2008 11:53 AM
 To: flexcoders@yahoogroups.com
 Subject: RE: [flexcoders] Format LI Bullets in htmlText
 
 
 
 Look into the LEADING property.
 
 Tracy
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of edlueze
 Sent: Tuesday, September 30, 2008 2:24 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Format LI Bullets in htmlText
 
 I am trying to format a set of bullets within a Text control using
 htmlText but the bullets seem to be really far apart (think of a
 really big line-height). I can't seem to figure out how to modify the
 style (CSS or inline) for the LI tag so that the line-height is smaller.
 
 This is my MXML:
 
 mx:Text
 mx:htmlText
 ![CDATA[My bullets:
 liBullet #1/li
 liBullet #2/li
 liBullet #3/li
 ]]
 /mx:htmlText
 /mx:Text
 
 Any ideas?
 
 Thanks in advance!
 
  
 
 
 This message is private and confidential. If you have received it in
error, please notify the sender and remove it from your system.





Re: [flexcoders] Re: Flex poster and Lynda.com free trial

2008-09-30 Thread Paul Andrews
Thanks guys, job done!

Paul

- Original Message - 
From: Vivian Richard [EMAIL PROTECTED]
To: flexcoders@yahoogroups.com
Sent: Tuesday, September 30, 2008 4:51 PM
Subject: Re: [flexcoders] Re: Flex poster and Lynda.com free trial


   Hey Paul, Please take a look at Nathan's link. The posters
   do not come unless you request for it!!! You need your flex
   builder's serial number to request for it. Please go there and
   submit a request for it.

   By the way thanks Nathan.

   Regards,









 On Tue, Sep 30, 2008 at 8:34 AM, nathanpdaniel [EMAIL PROTECTED] 
 wrote:
 Lynda.com site:
 http://www.lynda.com/go/flex3

 Fabled Flex 3 Posters:
 http://www.onflex.org/ted/2007/04/want-flex-api-posters.php

 :D

 --- In flexcoders@yahoogroups.com, Paul Andrews [EMAIL PROTECTED] wrote:

 Hmm. I've heard talk of this fabled Flex 3 poster yet haven't seen
 any info
 about how to get one. I had thought it might happen automagically
 when I
 upgraded to Flex 3 from Flex 2 (some time ago), but it didn't. Go
 on give me
 a clue.. ;-)

 Paul
 - Original Message -
 From: hworke [EMAIL PROTECTED]
 To: flexcoders@yahoogroups.com
 Sent: Tuesday, September 30, 2008 3:31 PM
 Subject: [flexcoders] Flex poster and Lynda.com free trial


 
  Hello every one. Did you get a free 1 month
  lynda.com subscription offer flier with the
  flex 3 and AIR posters? If so, could you please
  let me know the URL where I need to go to
  redeem this new Flex 3 buyer offer. Unfortunately
  I lost my flier but I wrote down the offer
  code.
 
  Best regards...
 
 
  
 
  --
  Flexcoders Mailing List
  FAQ:
 http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
  Alternative FAQ location:
  https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-
 446f-b4cf-1e62079f6847
  Search Archives:
  http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo!
 Groups
  Links
 
 
 
 




 

 --
 Flexcoders Mailing List
 FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
 Alternative FAQ location: 
 https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847
 Search Archives: 
 http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups 
 Links



 



Re: [flexcoders] Adobe has no love for Mac users?

2008-09-30 Thread Arleston Lueders
Hey Fellas,

Anyone figure this out?
When the ColdFusion/Flex Application Wizard feature will be avaliable?

Thanks!


On Sun, Aug 31, 2008 at 10:08 AM, Alan [EMAIL PROTECTED] wrote:

   Thank you Howard

 That is all I needed.  I don't mind so much if a feature is not
 implemented, I would; however, like some more explanation as to why features
 are omitted.
 Imagine my disbeleif when I open up the wizard and only see this:


 http://www.alanklement.com/blog_img/doh.jpg

 How about instead, something to the effect of

 Coldfusion 8 does not yet support this feature for OSX.  You can visit 
 link to adobe labs  to learn more on setting up a Coldfusion project for
 Flex



 C'mon this is a no brainer here.  Hell, once I figure out how to do this
 myself, I write my own blog post on how to do it.  Take that  muahahah (
 evil laugher ).


 Alan


 On Aug 31, 2008, at 8:13 AM, Howard Fore wrote:

 I've been told by a source at Adobe that the wizard problem has to do with
 the Extensions for ColdFusion that are an optional install with FB, that
 the root of the problem lies within ColdFusion, and that the solution is
 targeted for the next release of ColdFusion.


  



[flexcoders] User credentials

2008-09-30 Thread markgoldin_2000
Is it possible to get user credentials or at least a user name within 
Flex application?

Thanks



[flexcoders] Re: Hide a list item without changing (filtering) the dataprovider?

2008-09-30 Thread kyleashipley
Sorry to dredge up an old thread, but I'm having a similar problem
that can't be helped by the links provided.

In our system, we have a shared list collection that is filtered in
different ways for different views, but no button to enact the filter.
 For example, we have a list of users that consists of buddies, chat
room participants, blocked users, etc.  If we apply the filter
directly to the list, it will affect the other views.  If we create a
ListViewCollection, I don't think the bindings get updated correctly.
 (I could be wrong on that point.)

Is there a way to combine the ListViewCollection solution with data
binding to create a filtered list that updates when the original data
source updates?

 
 It's always worth looking through the archives.
 
 From a previous post of mine:
 
 Check out ListCollectionView. I've been down that same road. (Feb
Thread: 
 any ArrayCollection tricks?)
 
 From the thread: I found a great example here, which is perfect: 

http://viconflex.blogspot.com/2006/11/listcollectionview-different.html 
 
 Paul
 
 snip




Re: [flexcoders] User credentials

2008-09-30 Thread Douglas Knudsen
Might want to share what context you are posing here.  Do you mean J2EE
credentials?  OD credentials?  Cookie based?

DK

On Tue, Sep 30, 2008 at 4:06 PM, markgoldin_2000
[EMAIL PROTECTED]wrote:

   Is it possible to get user credentials or at least a user name within
 Flex application?

 Thanks

  




-- 
Douglas Knudsen
http://www.cubicleman.com
this is my signature, like it?


[flexcoders] Loading images fron cache ?

2008-09-30 Thread Stephane Guyot

Hi list,

I'm currently using URLLoader and loadBytes API to avoid server side  
round-trip when fetching images , with HTTP get request.
Everything works fine, but , actually the server doesn't put any  
headers cache directive, to allow expires in distant future.
In  case of the server puts non-expire directive does the URLLoader  
avoid server side request, based only on the url ?
Does the URLLoader or URLStreamLoader be able to extract the image  
directly from cache , when images are in cache with expires date in  
the future ?
Actually I load the image at least the first time, but not the others.
If the images have expires date say for example in 2025 year, should  
I be able to avoid the first loading ?

Thanks in advance,
Stephane




[flexcoders] Re: User credentials

2008-09-30 Thread markgoldin_2000
I am looking for user's domain name. 

--- In flexcoders@yahoogroups.com, Douglas Knudsen 
[EMAIL PROTECTED] wrote:

 Might want to share what context you are posing here.  Do you mean 
J2EE
 credentials?  OD credentials?  Cookie based?
 
 DK
 
 On Tue, Sep 30, 2008 at 4:06 PM, markgoldin_2000
 [EMAIL PROTECTED]wrote:
 
Is it possible to get user credentials or at least a user name 
within
  Flex application?
 
  Thanks
 
   
 
 
 
 
 -- 
 Douglas Knudsen
 http://www.cubicleman.com
 this is my signature, like it?





RE: [flexcoders] Re: User credentials

2008-09-30 Thread Tracy Spratt
Users do not have domain names.  Try again.

Tracy

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of markgoldin_2000
Sent: Tuesday, September 30, 2008 4:40 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: User credentials

 

I am looking for user's domain name. 

--- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
, Douglas Knudsen 
[EMAIL PROTECTED] wrote:

 Might want to share what context you are posing here. Do you mean 
J2EE
 credentials? OD credentials? Cookie based?
 
 DK
 
 On Tue, Sep 30, 2008 at 4:06 PM, markgoldin_2000
 [EMAIL PROTECTED]wrote:
 
  Is it possible to get user credentials or at least a user name 
within
  Flex application?
 
  Thanks
 
  
 
 
 
 
 -- 
 Douglas Knudsen
 http://www.cubicleman.com http://www.cubicleman.com 
 this is my signature, like it?


 



Re: [flexcoders] Re: User credentials

2008-09-30 Thread Matt Chotin
Unless you mean NT domain, in which case you're definitely out of luck :-)


On 9/30/08 2:30 PM, Tracy Spratt [EMAIL PROTECTED] wrote:




Users do not have domain names. Try again.
Tracy




From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of 
markgoldin_2000
Sent: Tuesday, September 30, 2008 4:40 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: User credentials


I am looking for user's domain name.

--- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com , 
Douglas Knudsen
[EMAIL PROTECTED] wrote:

 Might want to share what context you are posing here. Do you mean
J2EE
 credentials? OD credentials? Cookie based?

 DK

 On Tue, Sep 30, 2008 at 4:06 PM, markgoldin_2000
 [EMAIL PROTECTED]wrote:

  Is it possible to get user credentials or at least a user name
within
  Flex application?
 
  Thanks
 
 
 



 --
 Douglas Knudsen
 http://www.cubicleman.com
 this is my signature, like it?






Re: [flexcoders] Re: Hide a list item without changing (filtering) the dataprovider?

2008-09-30 Thread Scott Melby
iirc what I usually do is store my master list data (the one in my 
model) in an appropriate collection (more on this later).  I then create 
a second ArrayCollection in each view that needs to filter and set the 
source of that one to the model collection (property that exposes an 
Array).  I then bind my view components to the local array collection.  
Any view specific filtering is applied to the view local array 
collection, this way the other views are not filtered.  I think the 
trick with using ArrayCollection (again iirc) is that it will not fire a 
change to the source property unless that property is explicitly set... 
so you will not get updated unless you replace the whole source array if 
you bind to that.  You may be able to bind to the ArrayCollection.list 
property (not sure I have ever tried).  I have created custom collection 
classes that expose a read only values property that will fire 
bindings when the values in the collection change... so I rarely deal 
with this any more (see end of message for tip re: how to do that).


Below is an example.  In this example I bound my view local 
ArrayCollection.source to a custom Hashtable (wrapper on Dictionary that 
makes things bindable and mimics the Java Hashtable class interface) 
class that I have written that fires bindings whenever its stored data 
changes.  This should get you close... the important things here are


1) Bind views to a local collection that can be filtered locally
2) Bind the local collection to something that will fire the binding 
when it changes


mx:ArrayCollection id=peopleAC source={this._model.people.values} 
filterFunction=filterPerson/


mx:DataGrid id=peopleGrid dataProvider={this.peopleAC} width=100% 
height=100%


hth
Scott

--
Scott Melby
Founder, Fast Lane Software LLC
http://www.fastlanesw.com



FYI: here is how my custom Hashtable collection defines its read only 
values property to make it bindable.


 /**
 * This property exposes the values stored in the underlying
 * dictionary.  Because it is Bindable on the change event
 * anything bound to this property will update whenever this
 * Hashtable dispatches a change event.
 */
 [Bindable (event=change)]
 public function get values():Array


kyleashipley wrote:


Sorry to dredge up an old thread, but I'm having a similar problem
that can't be helped by the links provided.

In our system, we have a shared list collection that is filtered in
different ways for different views, but no button to enact the filter.
For example, we have a list of users that consists of buddies, chat
room participants, blocked users, etc. If we apply the filter
directly to the list, it will affect the other views. If we create a
ListViewCollection, I don't think the bindings get updated correctly.
(I could be wrong on that point.)

Is there a way to combine the ListViewCollection solution with data
binding to create a filtered list that updates when the original data
source updates?


 It's always worth looking through the archives.

 From a previous post of mine:

 Check out ListCollectionView. I've been down that same road. (Feb
Thread:
 any ArrayCollection tricks?)

 From the thread: I found a great example here, which is perfect:

http://viconflex.blogspot.com/2006/11/listcollectionview-different.html 
http://viconflex.blogspot.com/2006/11/listcollectionview-different.html 



 Paul

 snip


 




[flexcoders] html and swf file gone

2008-09-30 Thread flexaustin
So I was working on my project and flex builder 3 started acting
funny. Hit one keystroke and it would type 10 more and I keep getting
really weird errors when nothing was wrong with the file. 

So I did project  clean. 

Now my .html and .swf in bin-debug is gone and I can't build another
one?  Getting File not Found: file:/C:/.html

Anyone know how to recreate the html and swf file?



RE: [flexcoders] html and swf file gone

2008-09-30 Thread Ryan Graham

Clean deletes all the files in the output bin and replaces them with
fresh copies on build (very useful for externally loaded assets like
images and xml files that may be updated during dev).
 
You just need to get your project back to a point where the compiler can
successfully complete a build. I suspect you may have some compiler
errors showing when you try to build?
 
HTH,
Ryan



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of flexaustin
Sent: Tuesday, September 30, 2008 3:04 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] html and swf file gone



So I was working on my project and flex builder 3 started acting
funny. Hit one keystroke and it would type 10 more and I keep getting
really weird errors when nothing was wrong with the file. 

So I did project  clean. 

Now my .html and .swf in bin-debug is gone and I can't build another
one? Getting File not Found: file:/C:/.html

Anyone know how to recreate the html and swf file?



 


This message is private and confidential. If you have received it in error, 
please notify the sender and remove it from your system.

RE: [flexcoders] Re: User credentials

2008-09-30 Thread Tracy Spratt
Jeez, yeah I didn't even think of that.

 

Come on Mark, tell us what you want in a bit more detail, please?

 

Tracy

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Matt Chotin
Sent: Tuesday, September 30, 2008 5:20 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] Re: User credentials

 

Unless you mean NT domain, in which case you're definitely out of luck
:-)

On 9/30/08 2:30 PM, Tracy Spratt [EMAIL PROTECTED]
mailto:tspratt%40lariatinc.com  wrote:

Users do not have domain names. Try again.
Tracy



From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
[mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
] On Behalf Of markgoldin_2000
Sent: Tuesday, September 30, 2008 4:40 PM
To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com 
Subject: [flexcoders] Re: User credentials

I am looking for user's domain name.

--- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
mailto:flexcoders%40yahoogroups.com , Douglas Knudsen
[EMAIL PROTECTED] wrote:

 Might want to share what context you are posing here. Do you mean
J2EE
 credentials? OD credentials? Cookie based?

 DK

 On Tue, Sep 30, 2008 at 4:06 PM, markgoldin_2000
 [EMAIL PROTECTED]wrote:

  Is it possible to get user credentials or at least a user name
within
  Flex application?
 
  Thanks
 
 
 



 --
 Douglas Knudsen
 http://www.cubicleman.com http://www.cubicleman.com 
 this is my signature, like it?


 



RE: [flexcoders] html and swf file gone

2008-09-30 Thread Tracy Spratt
Yes, look at the Problems pane.  It is at menu, Windows, Problems.

Tracy

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Ryan Graham
Sent: Tuesday, September 30, 2008 6:16 PM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] html and swf file gone

 

Clean deletes all the files in the output bin and replaces them with
fresh copies on build (very useful for externally loaded assets like
images and xml files that may be updated during dev).

 

You just need to get your project back to a point where the compiler can
successfully complete a build. I suspect you may have some compiler
errors showing when you try to build?

 

HTH,

Ryan

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of flexaustin
Sent: Tuesday, September 30, 2008 3:04 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] html and swf file gone

So I was working on my project and flex builder 3 started acting
funny. Hit one keystroke and it would type 10 more and I keep getting
really weird errors when nothing was wrong with the file. 

So I did project  clean. 

Now my .html and .swf in bin-debug is gone and I can't build another
one? Getting File not Found: file:/C:/.html

Anyone know how to recreate the html and swf file?

This message is private and confidential. If you have received it in
error, please notify the sender and remove it from your system.

 



Re: [flexcoders] Re: Hide a list item without changing (filtering) the dataprovider?

2008-09-30 Thread Josh McDonald
Also something I do (and recommend), although I use ListCollectionView
rather than ArrayCollection, as you don't need the (admittedly small)
overhead of the internal ArrayList.

-Josh

On Wed, Oct 1, 2008 at 7:51 AM, Scott Melby [EMAIL PROTECTED] wrote:

  iirc what I usually do is store my master list data (the one in my
 model) in an appropriate collection (more on this later).  I then create a
 second ArrayCollection in each view that needs to filter and set the source
 of that one to the model collection (property that exposes an Array).  I
 then bind my view components to the local array collection.  Any view
 specific filtering is applied to the view local array collection, this way
 the other views are not filtered.  I think the trick with using
 ArrayCollection (again iirc) is that it will not fire a change to the source
 property unless that property is explicitly set... so you will not get
 updated unless you replace the whole source array if you bind to that.  You
 may be able to bind to the ArrayCollection.list property (not sure I have
 ever tried).  I have created custom collection classes that expose a read
 only values property that will fire bindings when the values in the
 collection change... so I rarely deal with this any more (see end of message
 for tip re: how to do that).

 Below is an example.  In this example I bound my view local
 ArrayCollection.source to a custom Hashtable (wrapper on Dictionary that
 makes things bindable and mimics the Java Hashtable class interface) class
 that I have written that fires bindings whenever its stored data changes.
 This should get you close... the important things here are

 1) Bind views to a local collection that can be filtered locally
 2) Bind the local collection to something that will fire the binding when
 it changes

 mx:ArrayCollection id=peopleAC source={this._model.people.values}
 filterFunction=filterPerson/

 mx:DataGrid id=peopleGrid dataProvider={this.peopleAC} width=100%
 height=100%

 hth
 Scott

 --
 Scott Melby
 Founder, Fast Lane Software LLChttp://www.fastlanesw.com



 FYI: here is how my custom Hashtable collection defines its read only
 values property to make it bindable.

   /**
   * This property exposes the values stored in the underlying
   * dictionary.  Because it is Bindable on the change event
   * anything bound to this property will update whenever this
   * Hashtable dispatches a change event.
   */
   [Bindable (event=change)]
   public function get values():Array



 kyleashipley wrote:

  Sorry to dredge up an old thread, but I'm having a similar problem
 that can't be helped by the links provided.

 In our system, we have a shared list collection that is filtered in
 different ways for different views, but no button to enact the filter.
 For example, we have a list of users that consists of buddies, chat
 room participants, blocked users, etc. If we apply the filter
 directly to the list, it will affect the other views. If we create a
 ListViewCollection, I don't think the bindings get updated correctly.
 (I could be wrong on that point.)

 Is there a way to combine the ListViewCollection solution with data
 binding to create a filtered list that updates when the original data
 source updates?

 
  It's always worth looking through the archives.
 
  From a previous post of mine:
 
  Check out ListCollectionView. I've been down that same road. (Feb
 Thread:
  any ArrayCollection tricks?)
 
  From the thread: I found a great example here, which is perfect:
 
 http://viconflex.blogspot.com/2006/11/listcollectionview-different.html 
 
  Paul
 
  snip
 


 




-- 
Therefore, send not to know For whom the bell tolls. It tolls for thee.

http://flex.joshmcdonald.info/

:: Josh 'G-Funk' McDonald
:: 0437 221 380 :: [EMAIL PROTECTED]


[flexcoders] how do I send a custom event from an application to a component?

2008-09-30 Thread luvfotography
Hi, I'm able to send a custom event from a component to an
application, but how do I send a custom event from the application to
a component?

example code:
mycomp.mxml:

?xml version=1.0 encoding=utf-8?
 !--this is myapp.mxml--
mx:Application xmlns:mx=http://www.adobe.com/2006/mxml;
layout=absolute
xmlns:comp=* xmlns:events=flash.events.*  creationComplete=init()
mx:Metadata
[Event(name=appEvent, type=flash.events.Event)] 
/mx:Metadata
mx:Script
![CDATA[
import mx.controls.Alert;

private function init():void {
addEventListener(compEvent,compEventHandler);
}

private function compEventHandler(e:Event):void {
Alert.show(event received from component);
}

private function sendEvent(e:Event):void {
var myappEvent:Event = new Event(appEvent, true,true);
dispatchEvent(myappEvent);
}
]]
/mx:Script
comp:mycomp /
mx:Button  label=send event to component id=appbutton
click=sendEvent(event) /
/mx:Application


component:
?xml version=1.0 encoding=utf-8?
  !--this is mycomp.mxml--
mx:Canvas xmlns:mx=http://www.adobe.com/2006/mxml; width=400
height=300 creationComplete=compInit()

mx:Metadata
[Event(name=compEvent, type=flash.events.Event)] 
/mx:Metadata

mx:Script 
![CDATA[
import mx.controls.Alert;
private function compInit():void {
addEventListener(appEvent,appEventHandler);
}
private function appEventHandler(e:Event):void {
Alert.show(event received from application);
}
private function sendEvent(e:Event):void {
var mycompEvent:Event = new Event(compEvent, true,true);
dispatchEvent(mycompEvent);
}
]]
/mx:Script
mx:Button id=mybutton x=200 label=send event to application
click=sendEvent(event) /
/mx:Canvas


thanks!



Re: [flexcoders] how do I send a custom event from an application to a component?

2008-09-30 Thread Scott Melby
Rather than sending an event to a component, what you do is declare a 
public function in your component, then call it from the application.


so... in myComp

public function someFunction(var param1:type):void
{
   //do stuff
}

and out in your main code you need to give your myComp an id... 
id=myComp.  Then in your button click handler call 
myComp.someFunction(blah);


hth
Scott

luvfotography wrote:


Hi, I'm able to send a custom event from a component to an
application, but how do I send a custom event from the application to
a component?

example code:
mycomp.mxml:

?xml version=1.0 encoding=utf- 8?
!--this is myapp.mxml-- 
mx:Application xmlns:mx=http://www.adobe. com/2006/ mxml 
http://www.adobe.com/2006/mxml

layout=absolute
xmlns:comp= * xmlns:events= flash.events. * creationComplete= 
init()

mx:Metadata
[Event(name= appEvent , type=flash. events.Event )]
/mx:Metadata
mx:Script
![CDATA[
import mx.controls. Alert;

private function init():void {
addEventListener( compEvent ,compEventHandle r);
}

private function compEventHandler( e:Event): void {
Alert.show( event received from component);
}

private function sendEvent(e: Event):void {
var myappEvent:Event = new Event(appEvent , true,true);
dispatchEvent( myappEvent) ;
}
]]
/mx:Script
comp:mycomp /
mx:Button label=send event to component id=appbutton
click=sendEvent( event) /
/mx:Application

component:
?xml version=1.0 encoding=utf- 8?
!--this is mycomp.mxml- -
mx:Canvas xmlns:mx=http://www.adobe. com/2006/ mxml 
http://www.adobe.com/2006/mxml width=400

height=300 creationComplete= compInit( )

mx:Metadata
[Event(name= compEvent , type=flash. events.Event )]
/mx:Metadata

mx:Script 
![CDATA[
import mx.controls. Alert;
private function compInit():void {
addEventListener( appEvent ,appEventHandler );
}
private function appEventHandler( e:Event): void {
Alert.show( event received from application );
}
private function sendEvent(e: Event):void {
var mycompEvent: Event = new Event(compEvent , true,true);
dispatchEvent( mycompEvent) ;
}
]]
/mx:Script
mx:Button id=mybutton x=200 label=send event to application
click=sendEvent( event) /
/mx:Canvas

thanks!

 




Re: [flexcoders] Loading images fron cache ?

2008-09-30 Thread Troy Gilbert
 Does the URLLoader or URLStreamLoader be able to extract the image
 directly from cache , when images are in cache with expires date in
 the future ?

When the Flash Player is running in the browser it uses the browser's
network stack for all HTTP requests. So, it's up to the browser
whether or not the cache is utilized.

When you use the stand-alone Flash Player, no caching is done.

Troy.


[flexcoders] images not appearing in AIR app

2008-09-30 Thread Andrew Wetmore
Hi:

I have an AIR application going into alpha test. Images embedded in
buttons appear fine, but several images that I display using the
mx:Image component are not appearing. This started on the Mac a
colleague uses, and I thought it was maybe a lab issue; but now it is
happening in the installed version.

The images are .gif and .png. They are present in the app and work
fine running in debug on a Windows machine. Can anyone suggest what
steps I should take to fix this, so my boss does not take my head off?

a



RE: [flexcoders] how do I send a custom event from an application to a component?

2008-09-30 Thread Tracy Spratt
But you can dispatch an event from Application and listen for it in a
component.  Code in the component:

Application.application.addEventListener(EventDispatchecInMainapp,
listenerInThisComponent);

 

Tracy



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Scott Melby
Sent: Tuesday, September 30, 2008 8:03 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] how do I send a custom event from an
application to a component?

 

Rather than sending an event to a component, what you do is declare a
public function in your component, then call it from the application.

so... in myComp

public function someFunction(var param1:type):void
{
//do stuff
}

and out in your main code you need to give your myComp an id...
id=myComp.  Then in your button click handler call
myComp.someFunction(blah);

hth
Scott

luvfotography wrote: 

Hi, I'm able to send a custom event from a component to an
application, but how do I send a custom event from the
application to
a component?

example code:
mycomp.mxml:

?xml version=1.0 encoding=utf- 8?
!--this is myapp.mxml-- 
mx:Application xmlns:mx=http://www.adobe. com/2006/ mxml
http://www.adobe.com/2006/mxml 
layout=absolute
xmlns:comp= * xmlns:events= flash.events. *
creationComplete= init()
mx:Metadata
[Event(name= appEvent , type=flash. events.Event )] 
/mx:Metadata
mx:Script
![CDATA[
import mx.controls. Alert;

private function init():void {
addEventListener( compEvent ,compEventHandle r);
}

private function compEventHandler( e:Event): void {
Alert.show( event received from component);
}

private function sendEvent(e: Event):void {
var myappEvent:Event = new Event(appEvent , true,true);
dispatchEvent( myappEvent) ;
}
]]
/mx:Script
comp:mycomp /
mx:Button label=send event to component id=appbutton
click=sendEvent( event) /
/mx:Application

component:
?xml version=1.0 encoding=utf- 8?
!--this is mycomp.mxml- -
mx:Canvas xmlns:mx=http://www.adobe. com/2006/ mxml
http://www.adobe.com/2006/mxml  width=400
height=300 creationComplete= compInit( )

mx:Metadata
[Event(name= compEvent , type=flash. events.Event )] 
/mx:Metadata

mx:Script 
![CDATA[
import mx.controls. Alert;
private function compInit():void {
addEventListener( appEvent ,appEventHandler );
}
private function appEventHandler( e:Event): void {
Alert.show( event received from application );
}
private function sendEvent(e: Event):void {
var mycompEvent: Event = new Event(compEvent , true,true);
dispatchEvent( mycompEvent) ;
}
]]
/mx:Script
mx:Button id=mybutton x=200 label=send event to
application
click=sendEvent( event) /
/mx:Canvas

thanks!

 

 



[flexcoders] Re: Strange List Behavior

2008-09-30 Thread Ben
I was wrong.  Changing the firefox property I mentioned does not fix
anything.

--- In flexcoders@yahoogroups.com, Ben [EMAIL PROTECTED] wrote:

 Where should I report this behavior on the adobe website?  Should I
 report it somewhere else too?
 
 --- In flexcoders@yahoogroups.com, Ben thegoosmans@ wrote:
 
  This is getting weirder...
  
  Firefox.com says that 10 is the default value for
  browser.urlbar.maxRichResults, but my value was 12.  Changing
  maxRichResults to either -1 or 10 eliminates the delay for me.
  
  --- In flexcoders@yahoogroups.com, Ben thegoosmans@ wrote:
  
   Hmm, if I disable my Smart Location Bar from doing
auto-complete, the
   delay goes away.
   
   To test this in Firefox 3:
   1. navigate to about:config
   2. find browser.urlbar.maxRichResults
   3. set it to -1
   4. exit firefox and go back to my example.
   5. voila! The delay is gone.
   
   --- In flexcoders@yahoogroups.com, Ben thegoosmans@ wrote:
   
I just installed FF2 to test my example and as Alex said, there
 is no
delay.  It seems that FF3 changed, causing the problem I have.

--- In flexcoders@yahoogroups.com, Alex Harui aharui@ wrote:

 I'm using an older FF2.
 
 From: flexcoders@yahoogroups.com
 [mailto:[EMAIL PROTECTED]
On Behalf Of Ben
 Sent: Tuesday, September 02, 2008 12:51 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Strange List Behavior
 
 
 Alex, what version of Firefox are you running?
 
 Make sure you try right clicking a few times. The delay does not
 always happen.
 
 --- In
flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com,
Sherif Abdou flex@ wrote:
 
  Actually it seems to only be Firefox 3.0.1,it does work in
 IE and
 stand alone.
  --
  Sherif Abdou
  http://VadexFX.com
  http://Sherifabdou.com
  - Original Message -
  From: Alex Harui
  To:
  flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com
  Sent: Monday, September 01, 2008 11:40 PM
  Subject: RE: [flexcoders] Re: Strange List Behavior
 
 
 
  I didn't see a problem in FireFox
 
 
 
  From:
   flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com

   
 
[mailto:flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com]
On Behalf Of Ben
  Sent: Monday, September 01, 2008 6:51 PM
  To:
  flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com
  Subject: [flexcoders] Re: Strange List Behavior
 
 
 
  The problem seems to be with Firefox. Can anyone give an
  explanation
  for this?
 
  --- In
flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com,
Sherif Abdou flex@ wrote:
  
   I am doing the StandAlone player and it is working fine.
   --
   Sherif Abdou
   http://VadexFX.com
   http://Sherifabdou.com
   - Original Message -
   From: Ben
   To:
   flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com
   Sent: Monday, September 01, 2008 7:51 PM
   Subject: [flexcoders] Re: Strange List Behavior
  
  
   Are you running Internet Explorer? It seems that the delay
   occurs in
   Firefox 3 but not in IE.
  
   --- In
flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com,
Sherif Abdou flex@ wrote:
   
Have you tried dispatching rollOver Event when the person
  right
   clicks? Also, is this the code for it or is it different
 since I
   checked it out and tested it on my computer and It
worked fine
 with no
   delay.
--
Sherif Abdou
http://VadexFX.com
http://Sherifabdou.com
- Original Message -
From: Ben
To:
flexcoders@yahoogroups.commailto:flexcoders%40yahoogroups.com
Sent: Monday, September 01, 2008 6:55 PM
Subject: [flexcoders] Strange List Behavior
   
   
I am trying to select an item on a right click. I
 accomplished
 this,
but whenever the selectedIndex changes, there is a short
 delay
  before
the List updates its display.
   
Here's my example. To view the source, right click and
 select
 View
Source.
   

 http://www.thegoosmans.com/rightclickproblem/SelectOnRightClick.html
   
First, click the Next button. Observe that the List
 updates
   smoothly.
Next, try right clicking on a list item. Notice that the
   change is
choppy.
   
I have tried calling validateNow() on the list to no
  avail. Any
advice would be greatly appreciated as this is giving me
 headaches.
   
Thanks in advance!
   
  
 

   
  
 





Re: [flexcoders] URLRequest, ByteArray, and the 0 byte

2008-09-30 Thread jitendra jain
Please check the following and it will clear what i need to say..
 
The way in which the data is used depends on the type of object used:
* If the object is a ByteArray object, the binary data of the ByteArray 
object is used as POST data. For GET, data of ByteArray type is not supported. 
Also, data of ByteArray type is not supported for FileReference.upload() and 
FileReference.download(). 
* If the object is a URLVariables object and the method is POST, the 
variables are encoded using x-www-form-urlencoded format and the resulting 
string is used as POST data. An exception is a call to FileReference.upload(), 
in which the variables are sent as separate fields in a multipart/form-data 
post. 
* If the object is a URLVariables object and the method is GET, the 
URLVariables object defines variables to be sent with the URLRequest object. 
* Otherwise, the object is converted to a string, and the string is 
used as the POST or GET data. 
 Thanks,

with Regards,
Jitendra Jain




- Original Message 
From: Maciek Sakrejda [EMAIL PROTECTED]
To: flexcoders@yahoogroups.com
Sent: Tuesday, 30 September, 2008 9:13:51 PM
Subject: Re: [flexcoders] URLRequest, ByteArray, and the 0 byte


That is not what the documentation says:

If the object is a ByteArray object, the binary data of the ByteArray
object is used as POST data. For GET, data of ByteArray type is not
supported. Also, data of ByteArray type is not supported for
FileReference. upload() and FileReference. download( ).

from
http://livedocs. adobe.com/ flex/3/langref/ flash/net/ URLRequest. html#data

I was doing a POST with a ByteArray as the data. Again, this works
correctly under Windows and OS X, so I'm pretty sure this is a Player
bug under Linux.
-- 
Maciek Sakrejda
Truviso, Inc.
http://www.truviso. com

-Original Message-
From: jitendra jain jitendra_jain_ [EMAIL PROTECTED] com
Reply-To: [EMAIL PROTECTED] ups.com
To: [EMAIL PROTECTED] ups.com
Subject: Re: [flexcoders] URLRequest, ByteArray, and the 0 byte
Date: Tue, 30 Sep 2008 09:13:59 +0530 (IST)

All the request data that is send is String. 

Thanks,

with Regards,
Jitendra Jain

- Original Message 
From: Troy Gilbert troy.gilbert@ gmail.com
To: [EMAIL PROTECTED] ups.com
Sent: Tuesday, 30 September, 2008 9:03:14 AM
Subject: Re: [flexcoders] URLRequest, ByteArray, and the 0 byte

 We're also working around this by Base64-encoding, but this is clearly
 less than ideal. It definitely seems like a Flash Player bug. We ran
 into this when doing AlivePDF REMOTE saves (i.e., bouncing the file
off
 the server). Do you know when you ran into this, Troy? I tested our
 particular problem on Windows and on OS X last week, and neither had
the
 issue.

// this byte array probably needs to be bigger to actually end up
// with a zero-byte in the compressed data
var bytes:ByteArray = new ByteArray();
bytes.writeUTFBytes (This is just some filler text.);
bytes.compress( );

// URLVariables automatically encodes its dynamic properties
// using a www-form-url- encode format, i.e. %12%34%56%78% 90
var variables:URLVariab les = new URLVariables( );
variables.username = troy;
variables.action = save;
variables.data = bytes;

// when the request is made, 'variables' is converted to a string
// the nulls in the ByteArray are not escaped, so they truncate the data
var request:URLRequest = new URLRequest(http://mywebserver/ myscript.
php);
request.method = URLRequestMethod. POST;
request.data = variables;

// Troy.

 _ _ _ _ _ _
Add more friends to your messenger and enjoy! Invite them now.

 


  Be the first one to try the new Messenger 9 Beta! Go to 
http://in.messenger.yahoo.com/win/

[flexcoders] Re: how do I send a custom event from an application to a component?

2008-09-30 Thread EddieBerman
In this case, Application.application.addEventListener... won't work.


This will, though:
parentApplication.addEventListener(appEvent, appEventHandler);

-Eddie


--- In flexcoders@yahoogroups.com, Tracy Spratt [EMAIL PROTECTED] wrote:

 But you can dispatch an event from Application and listen for it in 
a
 component.  Code in the component:
 
 Application.application.addEventListener(EventDispatchecInMainapp,
 listenerInThisComponent);
 
  
 
 Tracy
 
 
 
 From: flexcoders@yahoogroups.com 
[mailto:[EMAIL PROTECTED] On
 Behalf Of Scott Melby
 Sent: Tuesday, September 30, 2008 8:03 PM
 To: flexcoders@yahoogroups.com
 Subject: Re: [flexcoders] how do I send a custom event from an
 application to a component?
 
  
 
 Rather than sending an event to a component, what you do is declare 
a
 public function in your component, then call it from the 
application.
 
 so... in myComp
 
 public function someFunction(var param1:type):void
 {
 //do stuff
 }
 
 and out in your main code you need to give your myComp an id...
 id=myComp.  Then in your button click handler call
 myComp.someFunction(blah);
 
 hth
 Scott
 
 luvfotography wrote: 
 
   Hi, I'm able to send a custom event from a component to an
   application, but how do I send a custom event from the
 application to
   a component?
   
   example code:
   mycomp.mxml:
   
   ?xml version=1.0 encoding=utf- 8?
   !--this is myapp.mxml-- 
   mx:Application xmlns:mx=http://www.adobe. com/2006/ mxml
 http://www.adobe.com/2006/mxml 
   layout=absolute
   xmlns:comp= * xmlns:events= flash.events. *
 creationComplete= init()
   mx:Metadata
   [Event(name= appEvent , type=flash. events.Event )] 
   /mx:Metadata
   mx:Script
   ![CDATA[
   import mx.controls. Alert;
   
   private function init():void {
   addEventListener( compEvent ,compEventHandle r);
   }
   
   private function compEventHandler( e:Event): void {
   Alert.show( event received from component);
   }
   
   private function sendEvent(e: Event):void {
   var myappEvent:Event = new Event(appEvent , true,true);
   dispatchEvent( myappEvent) ;
   }
   ]]
   /mx:Script
   comp:mycomp /
   mx:Button label=send event to component id=appbutton
   click=sendEvent( event) /
   /mx:Application
   
   component:
   ?xml version=1.0 encoding=utf- 8?
   !--this is mycomp.mxml- -
   mx:Canvas xmlns:mx=http://www.adobe. com/2006/ mxml
 http://www.adobe.com/2006/mxml  width=400
   height=300 creationComplete= compInit( )
   
   mx:Metadata
   [Event(name= compEvent , type=flash. events.Event )] 
   /mx:Metadata
   
   mx:Script 
   ![CDATA[
   import mx.controls. Alert;
   private function compInit():void {
   addEventListener( appEvent ,appEventHandler );
   }
   private function appEventHandler( e:Event): void {
   Alert.show( event received from application );
   }
   private function sendEvent(e: Event):void {
   var mycompEvent: Event = new Event(compEvent , true,true);
   dispatchEvent( mycompEvent) ;
   }
   ]]
   /mx:Script
   mx:Button id=mybutton x=200 label=send event to
 application
   click=sendEvent( event) /
   /mx:Canvas
   
   thanks!





[flexcoders] FileReference upload to multiple request

2008-09-30 Thread limhy0306
Hi,

Currently, I am trying to upload a file to multiple URLRequest.
- FileReference.upload(URLRequest) is called several times; one 
after another when the upload has finished for the previous one.
 
However I found that the 2nd time the upload occurs, the 
Event.COMPLETE is not getting triggered; even though the uploading 
of the file is successful!
In the code below:
the 1st upload always trigger the Event.COMPLETE
but the 2nd upload fails to trigger the Event.COMPLETE!


Has anyone solve this before?

Below are my codes:

?xml version=1.0 encoding=utf-8?
mx:Application xmlns:mx=http://www.adobe.com/2006/mxml; 
layout=absolute creationComplete=initApp()

mx:Script
![CDATA[
import mx.events.*;
import flash.net.*;
import mx.controls.Alert;
import mx.utils.ObjectUtil;
import mx.utils.URLUtil;

private var fileRef:FileReference;
private var request:URLRequest;
private var urlVars:URLVariables;
private var currCount:int=0;

private function initApp():void
{

}

private function handleSelect(event:Event):void
{
trace(Select: +event);
doUpload(2);
}

private function handleComplete(event:Event):void
{
trace(Complete: + currCount); 


// Upload to another id when the 1st upload 
has finished
if(currCount  2)
{
doUpload(1);
}

}


private function onUploadFile():void
{
fileRef = new FileReference();
fileRef.addEventListener(Event.SELECT, 
handleSelect);
fileRef.addEventListener(Event.COMPLETE, 
handleComplete);
fileRef.browse();
}


   // Calls the FileReference.upload
   // Only difference between multiple uploads is 
   // the id parameter.
private function doUpload(id:int):void
{
currCount++;

// Set the parameter to the perl script
urlVars = new URLVariables();
urlVars.action = testmgr;
urlVars.op = upload_test;
urlVars.id = id.toString();
urlVars.info=Test Script;
urlVars.name=fileRef.name;
request = new URLRequest
(http://192.168.15.190/perl/ecpcons.pl;);
request.data = urlVars; 
request.method = URLRequestMethod.POST;

fileRef.upload(request);
}


]]
/mx:Script

mx:Panel x=124 y=95 width=250 height=200 
layout=absolute title=Upload Files to Server
mx:Button x=67 y=110 label=Upload a file 
id=btnUploadFile click=onUploadFile() enabled=true/
mx:Text x=30 y=35 id=txtMessage/
/mx:Panel

/mx:Application



[flexcoders] Re: More questions on weborb, creating my own services

2008-09-30 Thread timgerr
Thanks for the reply, can you tell me what the RemoteClass metadata
looks like, this is an entry in your
weborb\Weborb\WEB-INF\flex\remoting-config.xml???

Thanks for the help, I just want to learn.

timgerr

Note the RemoteClass metadata. This tells flex the location of the
class on the server that matches this class (In relation to the
Services directory).

Finally we have the Flex application that makes calls to functions
within this service.


--- In flexcoders@yahoogroups.com, valdhor [EMAIL PROTECTED] wrote:

 This seems to be a convoluted way to do this.
 
 I have created a simple example to show you how I use WebOrb.
 
 On my server I have the WebORB directory at the root level. In the
 Services directory I have a MyServices directory and in this directory I
 have a ValueObjects directory. For this example I have two files:
 
 =
 TestNamesInVO.php:
 ?php
 class TestNamesInVO
 {
  public $FirstName;
  public $LastName;
 
  public function __construct($FirstName, $LastName)
  {
  $this-FirstName = $FirstName;
  $this-LastName = $LastName;
  }
 }
 ?
 =
 TestNamesOutVO.php:
 ?php
 class TestNamesOutVO
 {
  public $FullName;
 
  public function __construct($FullName)
  {
  $this-FullName = $FullName;
  }
 }
 ?
 =
 
 The constructors are there just to make it easier to create a new
 object. They are optional.
 
 In the MyServices directory I have a TestService.php file. This contains
 all the functions available with this service.
 
 =
 TestService.php:
 ?php
 class TestService
 {
  function ShowMe()
  {
  return Tom Jones;
  }
 
  function ShowName($name)
  {
  return 'Hello ' . $name;
  }
 
  function ShowNames(TestNamesInVO $namesIn)
  {
  require_once(ValueObjects/TestNamesInVO.php);
  require_once(ValueObjects/TestNamesOutVO.php);
 
  $fullName = new TestNamesOutVO($namesIn-FirstName .   .
 $namesIn-LastName);
 
  return $fullName;
  }
 }
 ?
 =
 
 In flex I also have a ValueObjects folder underneath my src folder. This
 folder contains the corresponding ActionScript files for the value
 objects on the server:
 
 =
 TestNamesInVO.as:
 package ValueObjects
 {
  [RemoteClass(alias=MyServices.ValueObjects.TestNamesInVO)]
  [Bindable]
  public class TestNamesInVO
  {
  //instance variables
  private var _FirstName:String;
  private var _LastName:String;
 
  //accessor methods
  public function get FirstName():String {return _FirstName;}
  public function get LastName():String {return _LastName;}
 
  //mutator methods
  public function set FirstName(FirstName:String):void
{_FirstName
 = FirstName;}
  public function set LastName(LastName:String):void {_LastName =
 LastName;}
  } // end class
 }//end package
 =
 TestNamesOutVO.as:
 package ValueObjects
 {
  [RemoteClass(alias=MyServices.ValueObjects.TestNamesOutVO)]
  [Bindable]
  public class TestNamesOutVO
  {
  //instance variables
  private var _FullName:String;
 
  //accessor methods
  public function get FullName():String {return _FullName;}
 
  //mutator methods
  public function set FullName(FullName:String):void {_FullName =
 FullName;}
  } // end class
 }//end package
 =
 
 Note the RemoteClass metadata. This tells flex the location of the class
 on the server that matches this class (In relation to the Services
 directory).
 
 Finally we have the Flex application that makes calls to functions
 within this service.
 
 =
 WebORBExample.mxml:
 ?xml version=1.0 encoding=utf-8?
 mx:Application xmlns:mx=http://www.adobe.com/2006/mxml;
 layout=absolute
  creationComplete=onCreationComplete()
  mx:Script
  ![CDATA[
  import mx.messaging.channels.AMFChannel;
  import mx.messaging.ChannelSet;
  import mx.rpc.events.FaultEvent;
  import mx.rpc.events.ResultEvent;
  import mx.rpc.remoting.RemoteObject;
  import mx.managers.CursorManager;
  import mx.controls.Alert;
  import ValueObjects.TestNamesInVO;
  import ValueObjects.TestNamesOutVO;
 
  private var channelSet:ChannelSet;
  private var amfChannel:AMFChannel;