[flexcoders] String Data Type Maximum Size

2008-07-22 Thread Jurgen Beck
What is the maximum size of the String data type?

Thanks,

JB


Re: [flexcoders] Re: Rich Text Editor

2008-02-15 Thread Jurgen Beck
And let's not forget that we need a way in Flex to work with simple  
HTML content that does not use Flash's antiquated set of HTML  
formatting. We already know the challenges of implementing a full  
browser in Flash/Flex (at least outside of AIR.) At least allow us to  
represent and edit simple HTML content that's compatible with the  
rest of the browser world.


Again, no full HTML implementation is needed, just something along an  
HTML editor like FCKEditor.


Jurgen

On Feb 15, 2008, at 10:27 AM, cmalartre wrote:


Hi Gordon Smith  all,

I thought that the Buzzword aquisition was directly related to Flash
Player code named Astro:

http://labs.adobe.com/wiki/index.php/Astro

Adobe is also developing a library of ActionScript-based text layout
components based on these new APIs to provide easy-to-integrate
features, such as multi-column layout of editable text that
automatically reflows, wrapping around inline images, and handling
tables. With this new architecture, text becomes an extensible part of
the platform -- new text layout features can be delivered without
requiring a new player release.

I hope this is true! I'm working mainly on text intensive application.
One is a text editor for math teachers and the second is a note taking
app.

I want multi-level bullets, tables and images!

Carl-Alexandre Malartre
Scolab

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

 I am running under similar kind of RTE problem. my scenario is more
complex.
 I am using FCKEditer which i have integrated with flex using  
Iframe and

 ExternalInterface API.
 I still have to work on browser compatibility part. but it works  
really

 well.

 ~ Suketu Vyas

 On Fri, Feb 15, 2008 at 9:34 AM, Harald Dehn [EMAIL PROTECTED]  
wrote:


  Hi Gordon,
 
 
 
  yes but we don't need the full functionality of buzzword, for
example we
  don't need tables. Our problems with the RTE component are:
 
 
 
  - htmlText - we like to generate pdf-documents with the
  .net-backend.
 
  - missing image support
 
  - missing page view and a page counter
 
 
 
  Harald Dehn
 
 
 
  *Von:* flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] *Im
  Auftrag von *Gordon Smith
  *Gesendet:* Freitag, 15. Februar 2008 06:03
  *An:* flexcoders@yahoogroups.com
  *Betreff:* RE: [flexcoders] Rich Text Editor
 
 
 
   Do you the a chance to get a component from your
buzzword-company in
  the meantime
 
 
 
  Are you asking Can we get Buzzword's editor as a Flex
component?. That's
  a different part of the company, and I'm not aware of any plans to
make it
  available in component form (either free or for money). I suspect
that there
  are business reasons to keep it as an Adobe-only application for
awhile, but
  I'm just an engineer and not involved in such decisions.
 
 
 
  BTW, what does your CRM app need in a texteditor beyond what
  RichTextEditor currently provides? RTL support or something else?
 
 
 
  Gordon Smith
 
  Adobe Flex SDK Team
 
 
  --
 
  *From:* flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] *On
  Behalf Of *Harald Dehn
  *Sent:* Thursday, February 14, 2008 12:18 AM
  *To:* flexcoders@yahoogroups.com
  *Subject:* Re: [flexcoders] Rich Text Editor
 
  Hi Gordon,
 
 
 
  this is a realy good news. Do you the a chance to get a  
component from

  your buzzword-company in the meantime. We need a texteditor for
a crm
  application we developed in flex.
 
 
 
  Regards,
 
  Harald Dehn
 
 
 
  Am 14.02.2008 um 02:48 schrieb Gordon Smith:
 
 
 
 
 
   Why Adobe does not make something decent about this issue?
 
 
 
  We're working on it! Flash Player 10 (Astro) and Flex 4 are
likely to
  have a new text engine that will support right-to-left text and
other text
  improvements.
 
 
 
  Gordon Smith
 
  ! Adobe Fl ex SDK Team
 
 
  --
 
  *From:* flexcoders@yahoogroups.com [mailto:flexcoders@  
flexcoders@

  yahoogroups.com] *On Behalf Of *Rafael Faria
  *Sent:* Wednesday, February 13, 2008 4:47 PM
  *To:* flexcoders@yahoogroups.com
  *Subject:* [flexcoders] Rich Text Editor
 
  I know this had been a big subject of discussion in the past but i
  want to bring it up again.
 
  Does anybody found a good solution to implement RTE in f! lex?
 
  I tried the iframe solution but it seems that it has some problems
  with rendering, someone work it out how to fix it?
 
  I know there is some people from adobe here, so my question is
  Why Adobe does not make something decent about this issue?
  If adobe is trying to improve the flash player as much as they  
can,

  why do not spend some time in a decent RTE component?
 
  Any suggestion for any good RTE, even a paid one?
 
  Thanks
  Raf
 
 
 
 
 
 
 








Re: [flexcoders] FlexAuthority.com

2008-01-14 Thread Jurgen Beck
Have you been able to contact Moniker Online Services to pass a  
message on to the domain owner?


A WHOIS lookup shows them as the Registration record entry.

Jurgen

On Jan 14, 2008, at 3:09 AM, Judith Dinowitz wrote:

There's a good chance that we can have a high quality Flex-only  
magazine, but we're missing one important ingredient:  
FlexAuthority.com. If anyone knows who owns this domain and how to  
contact them, and can give us that information, we'd really  
appreciate it. We've been trying for months to find out who owns it  
and how to get in touch with them, and have been getting nowhere.


Thanks,

--
Judith Dinowitz
Editor
Fusion Authority
The House of Fusion Technical Magazine
http://www.fusionauthority.com






[flexcoders] Looking for an HTMLEditor Component

2007-12-14 Thread Jurgen Beck
We are building a CMS in Flex and one of the biggest challenges at  
the moment is the fact that Flex (Flash) doesn't have good support  
for HTML tags. We are currently using the RichTextEditor component  
and convert the HTML output to valid HTML tags. However, this leaves  
us with some serious challenges.

So, here is the question:

Has anyone created a Flex HTML editor component they are willing to  
sell?

I have looked at several solutions, including working with IFrames or  
div tags and using HTML components such as FCKEditor. None of them  
really fit the model we need, as they all have some significant  
drawbacks.

Please note that this is for a component that allows WYSIWYG editing  
of HTML content, not just a component that displays HTML content.

Thanks,

Jurgen


[flexcoders] Re: Traverse List of All Children

2007-11-06 Thread Jurgen Beck

Thanks, Adam. I should have added more details to my post.

The 'complexity' is introduced by the fact that I am having to find  
all Validator components, which are not DisplayObjectContainers.  
Using Object (implemented by each validator subclass) in the  
recursive function does not work either, since it catches components  
such as flash.display.Shape, which doesn't have any children.


On Nov 5, 2007, at 11:14 PM, aduston1976 wrote:


Why does it get complex with nested sets of child components? Why
can't you just use a recursive function?

function doSomethingToAllDescendants(component :
DisplayObjectContainer) : void {
for (var i : int = 0; i  component.numChildren; i++) {
doSomethingToComponent(component.getChildAt(i));
if (component.getChildAt(i) is DisplayObjectContainer)

doSomethingToAllDescendants(DisplayObjectContainer 
(component.getChildAt(i)));

}
}

Sorry if i left out some curlies or semicolons here.

Adam

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

 I need to traverse the list of all children in a component. What's
 the best approach to doing that? It gets fairly complex with nested
 sets of child components, so I'm looking for an efficient solution.

 Thanks,

 Jurgen








[flexcoders] Traverse List of All Children

2007-11-05 Thread Jurgen Beck
I need to traverse the list of all children in a component. What's  
the best approach to doing that? It gets fairly complex with nested  
sets of child components, so I'm looking for an efficient solution.

Thanks,

Jurgen


[flexcoders] TileList ItemRenderer with different sizes possible?

2007-10-26 Thread Jurgen Beck
I'm looking for a way to show ItemRenderers of various sizes in a  
TileList. variableRowHeight will let us set the row height for cells  
in grids, but there doesn't seem to be a way to have varying sizes of  
ItemRenderers for a TileList, or is there?

Any suggestion are appreciated!

Jurgen


[flexcoders] List Component: Working with Collapsed and Expanded ItemRenderer

2007-10-18 Thread Jurgen Beck
I am experiencing something mildly strange with the List component  
when using a custom item renderer that has two states, a collapsed  
state and an expanded state.

When I have one or more item renderers in the expanded state, the  
List component eventually will display the vertical scrollbar. Here  
is the strange part:

When using the scrollbar to scroll through the list, the original  
expanded item renderers that would normally disappear with their  
expanded state from the visual range of the list get collapsed and  
new list items that have not been expanded do so in their place.

As I am not forcing this behavior my thinking is that the List  
component is either missing a property setting to prevent this  
behavior, or this may be either a bug, or simply by design.

Anyone with some more info on this?

Thanks,

Jurgen


RE: [flexcoders] List Component: Working with Collapsed and Expanded ItemRenderer

2007-10-18 Thread Jurgen Beck

Makes sense, Alex. Thanks!

I also found an entry in the Flex Bug system after I posted on the  
list. So, this is for documentation for others to see:


http://bugs.adobe.com/jira/browse/SDK-12343

In it was a great reference to an article you wrote:

http://blogs.adobe.com/aharui/2007/03/ 
thinking_about_item_renderers_1.html


On Oct 18, 2007, at 1:47 PM, Alex Harui wrote:



Renderers are recycled.  Only as many renderers that you can see  
are created regardless of how many items in your data provider.   
So, one renderer can end up having to render various items in the  
dataprovider.  As such, all aspects of its visuals must be driven  
by the .data object including which state it is in.




From: flexcoders@yahoogroups.com  
[mailto:[EMAIL PROTECTED] On Behalf Of Jurgen Beck

Sent: Thursday, October 18, 2007 11:14 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] List Component: Working with Collapsed and  
Expanded ItemRenderer




I am experiencing something mildly strange with the List component
when using a custom item renderer that has two states, a collapsed
state and an expanded state.

When I have one or more item renderers in the expanded state, the
List component eventually will display the vertical scrollbar. Here
is the strange part:

When using the scrollbar to scroll through the list, the original
expanded item renderers that would normally disappear with their
expanded state from the visual range of the list get collapsed and
new list items that have not been expanded do so in their place.

As I am not forcing this behavior my thinking is that the List
component is either missing a property setting to prevent this
behavior, or this may be either a bug, or simply by design.

Anyone with some more info on this?

Thanks,

Jurgen








[flexcoders] Re: List Component: Working with Collapsed and Expanded ItemRenderer

2007-10-18 Thread Jurgen Beck
You mean, using a VBox as the container and then adding the custom  
components as children based on the rows in the dataprovider? I like  
that idea.



On Oct 18, 2007, at 4:32 PM, scalenine wrote:


I had the same issue with the player on Shilliber.com. Exact same use
case. I think the guy who programmed it up ended up using a VBox.

Juan

scalenine.com | degarafa.com | ocflex.org

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

 Makes sense, Alex. Thanks!

 I also found an entry in the Flex Bug system after I posted on the
 list. So, this is for documentation for others to see:

 http://bugs.adobe.com/jira/browse/SDK-12343

 In it was a great reference to an article you wrote:

 http://blogs.adobe.com/aharui/2007/03/
 thinking_about_item_renderers_1.html

 On Oct 18, 2007, at 1:47 PM, Alex Harui wrote:

 
  Renderers are recycled. Only as many renderers that you can see
  are created regardless of how many items in your data provider.
  So, one renderer can end up having to render various items in the
  dataprovider. As such, all aspects of its visuals must be driven
  by the .data object including which state it is in.
 
 
 
  From: flexcoders@yahoogroups.com
  [mailto:[EMAIL PROTECTED] On Behalf Of Jurgen Beck
  Sent: Thursday, October 18, 2007 11:14 AM
  To: flexcoders@yahoogroups.com
  Subject: [flexcoders] List Component: Working with Collapsed and
  Expanded ItemRenderer
 
 
 
  I am experiencing something mildly strange with the List component
  when using a custom item renderer that has two states, a collapsed
  state and an expanded state.
 
  When I have one or more item renderers in the expanded state, the
  List component eventually will display the vertical scrollbar.  
Here

  is the strange part:
 
  When using the scrollbar to scroll through the list, the original
  expanded item renderers that would normally disappear with their
  expanded state from the visual range of the list get collapsed and
  new list items that have not been expanded do so in their place.
 
  As I am not forcing this behavior my thinking is that the List
  component is either missing a property setting to prevent this
  behavior, or this may be either a bug, or simply by design.
 
  Anyone with some more info on this?
 
  Thanks,
 
  Jurgen
 
 
 
 








RE: [flexcoders] List Component: Working with Collapsed and Expanded ItemRenderer

2007-10-18 Thread Jurgen Beck

Quick follow-up question:

Since we are storing the state of the item renderer in a property of  
the data object, which event would be best used to make sure the  
state is restored when the specific item comes back into view?


On Oct 18, 2007, at 1:47 PM, Alex Harui wrote:



Renderers are recycled.  Only as many renderers that you can see  
are created regardless of how many items in your data provider.   
So, one renderer can end up having to render various items in the  
dataprovider.  As such, all aspects of its visuals must be driven  
by the .data object including which state it is in.




From: flexcoders@yahoogroups.com  
[mailto:[EMAIL PROTECTED] On Behalf Of Jurgen Beck

Sent: Thursday, October 18, 2007 11:14 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] List Component: Working with Collapsed and  
Expanded ItemRenderer




I am experiencing something mildly strange with the List component
when using a custom item renderer that has two states, a collapsed
state and an expanded state.

When I have one or more item renderers in the expanded state, the
List component eventually will display the vertical scrollbar. Here
is the strange part:

When using the scrollbar to scroll through the list, the original
expanded item renderers that would normally disappear with their
expanded state from the visual range of the list get collapsed and
new list items that have not been expanded do so in their place.

As I am not forcing this behavior my thinking is that the List
component is either missing a property setting to prevent this
behavior, or this may be either a bug, or simply by design.

Anyone with some more info on this?

Thanks,

Jurgen








RE: [flexcoders] List Component: Working with Collapsed and Expanded ItemRenderer - Solution

2007-10-18 Thread Jurgen Beck

I'm documenting this here for others who may be struggling with this:

It has been suggested to use a VBox and simply just add children to  
it based on items in the dataprovider. That's a great approach and  
would have been my  workaround. However, Alex was giving enough  
pointers to implement the solution based on storing the expanded and  
collapsed state in the data object.


This can be easily done by overriding the data property of the item  
renderer and using a 'collapsed' property to restore the state of the  
item renderer.


So, here is an example:

override public function set data(value:Object):void {
super.data = value;
if (value.collapsed) {
currentState = Closed;
} else {
currentState = Open;
}
// Dispatch the dataChange event.
dispatchEvent(new FlexEvent(FlexEvent.DATA_CHANGE));
}

Use the following to switch the state:

private function switchOpenState():void {
if (currentState == Closed) {
currentState = Open;
data.collapsed = false;
} else {
currentState = Closed;
data.collapsed = true;
}   
}

 I'm working with states and transitions, but this can be used in  
other ways as well. The other piece would be to use a function to  
switch the collapsed state and then setting the data.collapsed  
property. Changing the state causes a sequence of events that will  
eventually evaluate the data.collapsed property of each item renderer  
and restore it to its proper state should the user scroll through the  
list or interact with it in any other way.


Hope this helps,

Jurgen



On Oct 18, 2007, at 1:47 PM, Alex Harui wrote:



Renderers are recycled.  Only as many renderers that you can see  
are created regardless of how many items in your data provider.   
So, one renderer can end up having to render various items in the  
dataprovider.  As such, all aspects of its visuals must be driven  
by the .data object including which state it is in.




From: flexcoders@yahoogroups.com  
[mailto:[EMAIL PROTECTED] On Behalf Of Jurgen Beck

Sent: Thursday, October 18, 2007 11:14 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] List Component: Working with Collapsed and  
Expanded ItemRenderer




I am experiencing something mildly strange with the List component
when using a custom item renderer that has two states, a collapsed
state and an expanded state.

When I have one or more item renderers in the expanded state, the
List component eventually will display the vertical scrollbar. Here
is the strange part:

When using the scrollbar to scroll through the list, the original
expanded item renderers that would normally disappear with their
expanded state from the visual range of the list get collapsed and
new list items that have not been expanded do so in their place.

As I am not forcing this behavior my thinking is that the List
component is either missing a property setting to prevent this
behavior, or this may be either a bug, or simply by design.

Anyone with some more info on this?

Thanks,

Jurgen











Re: [flexcoders] Dynamic Scaling of a Flex Application

2007-09-21 Thread Jurgen Beck

Thanks Alex and Yaagoub.

Both work well, with some minor issues to get around:

ScaleX and ScaleY:
We have to set some metrics and listen for the resize event to keep 
things dynamic enough. Without setting starting metrics we don't really 
know what we should scale to when we resize.


stage.scaleMode:
There seems to be some funky behavior as to the application container 
itself. It's a bit difficult to get exact results. For example, setting 
the width and height of a canvas to 100% will scale the canvas and all 
containing children to the top left quarter of the canvas, depending on 
the aspect ratio of the browser or standalone Flash Player.


Other issues seem to have to do with how Flex calculates the scaled 
ratios in relationship to the application container size.


Nothing that we can't address with a bit of RD, but as I said, it's a 
bit funky.


Again, thanks to both of you!

Jurgen

Yaagoub Al-Nujaidi wrote:
ScaleX and ScaleY properties of the application will scale the whole 
application. You can set them at the creationComplete event of the 
Application, or anytime dynamically.


*/Alex Harui [EMAIL PROTECTED]/* wrote:

stage.scaleMode

*From:* flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] *On Behalf Of *Jurgen Beck
*Sent:* Thursday, September 20, 2007 4:18 PM
*To:* flexcoders@yahoogroups.com
*Subject:* [flexcoders] Dynamic Scaling of a Flex Application
I am looking for a way to visually scale a Flex application
similar to
what is possible with a Flash SWF. For example, creating a Flash
SWF and
changing the size of the movie will scale all content, including text
and other elements.

Looking for the same with a Flex application, I haven't been able to
locate a property or method that allows me to do that.

Question: Is Flex able to dynamically size content (including text)
based on a global setting, or are we constraint to specifying the
sizes
of elements manually?

Hope this makes sense, if not, I'll explain a bit more.

Thanks,

Jurgen


 


[flexcoders] Dynamic Scaling of a Flex Application

2007-09-20 Thread Jurgen Beck
I am looking for a way to visually scale a Flex application similar to 
what is possible with a Flash SWF. For example, creating a Flash SWF and 
changing the size of the movie will scale all content, including text 
and other elements.

Looking for the same with a Flex application, I haven't been able to 
locate a property or method that allows me to do that.

Question: Is Flex able to dynamically size content (including text) 
based on a global setting, or are we constraint to specifying the sizes 
of elements manually?

Hope this makes sense, if not, I'll explain a bit more.

Thanks,

Jurgen


[flexcoders] Styling: Clearing Validation Errors on TextInput

2007-09-13 Thread Jurgen Beck
Looks like clearing a validation error with UIComponent.errorString =  
also gets rid of the inset border on TextInput components.

How can we change that behavior? I need to return the TextInput style to 
the normal inset border when the error is cleared.

Anyone run into this? If so, is there a solution?

Thanks,

Jurgen


Re: [flexcoders] Re: Flex Builder 2.0.1: Change Browser for Debugging

2007-08-30 Thread Jurgen Beck

Strange indeed.

Shell script opens up Safari without any issues. Remember that the same 
is true for FB when opening help documentation. It brings it right up in 
Safari.


The preferences in FB for Safari are set to:

Name: Safari
Location: /usr/bin/open
Parameters: -a Safari %URL%

This obviously works, as FB starts up Safari when using the help documents.

For what it's worth, I checked this out on a MacBook Pro running Mac OS 
X and I now understand why everyone agrees that the debugger should 
start up based on the selection in the preferences. Didn't have any 
problems there to switch between the browsers.


Only conclusion that I can draw for the problem Mac OS X install is that 
Flex Builder is having an issue picking up the browser preference when 
targeting a browser for debugging and must revert back to the system's 
default browser.


Shell script works, preferences seem to be working for FB help 
documentation in Safari. The problem shows up when starting a debug session.


I wonder if we are having issues with the underlying Eclipse framework.

Jurgen


Mike Morearty wrote:


Strange. For what it's worth, the exact command line used by Flex
Builder to launch Safari is:

/usr/bin/open -a %1 %2

where %1 is the full path to the browser specified by the Eclipse
browser preferences, and %2 is the URL of your app. So, it is
normally this for Safari:

/usr/bin/open -a /Applications/Safari.app/Content/MacOS/Safari
YOUR_URL_GOES_HERE

Try that from a shell script (without the URL on the end), and see if
Safari opens.

- Mike

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


 Hey Mike,

 Thanks for the response!

 This is happening on Mac OS X with Flex Builder 2.0.1. The system's
 default browser is set to Firefox. For the Flex debugging I'd like to
 use Safari though. I've been running into some caching issues with
 Firefox that I have documented in another post, thus the reason to use
 Safari. Safari is at version 3.0.3.

 Firefox and Safari are installed in their default locations
 (Applications folder).

 I've done a little bit more testing with the External Web Browser
 settings in Preferences and it seems to me that Flex Builder is having
 difficulties locating the Safari browser instance and is defaulting to
 the system default browser for debugging, which in my case is Firefox.
 This, even though the help documentation starts up in Safari when the
 selection is set to use Safari as the external browser.

 So, the question then would be what to specify for the Location and
 Parameters settings in Edit External Web Browser when setting up the
 Safari entry.

 Jurgen


 Mike Morearty wrote:
 
  Hi Jurgen,
 
  Carlos was correct -- changing the value in Window  Preferences 
  General  Web Browser is how you change what browser Flex Builder uses
  to debug. If that doesn't work for you, then something is going
  wrong, but I am not aware of any bugs in that area.
 
  There is no per-project setting that is in any way related to this.
  The only per-project setting is, what URL is used when launching; but
  this has no effect at all on our choice of which browser to use.
 
  Just curious: What operating system are you on? What is your system
  default browser, and what browser are you trying to force Flex Builder
  to use? Is there anything nonstandard about how you installed any of
  your browsers -- e.g. did you install Firefox into a nonstandard
  location, or anything like that?
 
  I can't really think of much that would be going wrong here, but with
  more info, I might be able to take a guess.
 
  - Mike Morearty
  Adobe Flex Builder team
  http://www.morearty.com/blog http://www.morearty.com/blog 
http://www.morearty.com/blog http://www.morearty.com/blog

 
  --- In flexcoders@yahoogroups.com 
mailto:flexcoders%40yahoogroups.com

  mailto:flexcoders%40yahoogroups.com, Jurgen Beck jurgen@ wrote:
  
   Thanks, but that doesn't seem to have an effect on the browser
that the
   debugger uses. This seems to only affect the browser use for the
help
   documentation.
  
   I'm sure I'm missing something.
  
   Jurgen
  
   carlos m wrote:
In FB click on the Window  Preferences  General  Web
Browser.
   
HTH,
   
Carlos
   
- Original Message 
From: Jurgen Beck jurgen@
To: flexcoders@yahoogroups.com 
mailto:flexcoders%40yahoogroups.com

mailto:flexcoders%40yahoogroups.com
Sent: Wednesday, August 29, 2007 10:06:39 AM
Subject: Re: [flexcoders] Flex Builder 2.0.1: Change Browser for
  Debugging
   
I asked this yesterday, but I'm not sure if I missed any possible
responses to it. So here is another quick summary:
   
How can we change the browser that FB uses for debugging?
   
Thanks,
   
Jurgen
   
Jurgen Beck wrote:
   
Even though there is a FB Preferences setting for using a browser
  when
Web pages are opened, this seems to mostly be targeting the
  display

Re: [flexcoders] Re: Flex Builder 2.0.1: Change Browser for Debugging

2007-08-30 Thread Jurgen Beck
Makes perfect sense. I think for the time being we'll have to set this 
one aside and consider it an anomaly with this specific system, seeing 
that it works on all others.


I did reset the preferences to the default, but that still didn't make a 
difference with the debug browser selection.


Thanks for your input though. It is valuable to learn more about the 
internals of Flex Builder.


Jurgen

Mike Morearty wrote:


Actually, even better than what I said before -- manually changing
Safari's arguments -- would be to just click the Restore Defaults
button at the bottom of that preference page.

Some of the built-in browsers have browser-specific code that controls
how they are launched. By clicking Restore Defaults, you are
restoring that browser-specific code as well as the preferences you
can see onscreen. If you just edit the arguments, that may not
interact properly with the Java code that is behind it.

- Mike Morearty
Adobe Flex Builder team

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


 Strange indeed.

 Shell script opens up Safari without any issues. Remember that the same
 is true for FB when opening help documentation. It brings it right
up in
 Safari.

 The preferences in FB for Safari are set to:

 Name: Safari
 Location: /usr/bin/open
 Parameters: -a Safari %URL%

 This obviously works, as FB starts up Safari when using the help
documents.

 For what it's worth, I checked this out on a MacBook Pro running Mac OS
 X and I now understand why everyone agrees that the debugger should
 start up based on the selection in the preferences. Didn't have any
 problems there to switch between the browsers.

 Only conclusion that I can draw for the problem Mac OS X install is
that
 Flex Builder is having an issue picking up the browser preference when
 targeting a browser for debugging and must revert back to the system's
 default browser.

 Shell script works, preferences seem to be working for FB help
 documentation in Safari. The problem shows up when starting a debug
session.

 I wonder if we are having issues with the underlying Eclipse framework.

 Jurgen


 Mike Morearty wrote:
 
  Strange. For what it's worth, the exact command line used by Flex
  Builder to launch Safari is:
 
  /usr/bin/open -a %1 %2
 
  where %1 is the full path to the browser specified by the Eclipse
  browser preferences, and %2 is the URL of your app. So, it is
  normally this for Safari:
 
  /usr/bin/open -a /Applications/Safari.app/Content/MacOS/Safari
  YOUR_URL_GOES_HERE
 
  Try that from a shell script (without the URL on the end), and see if
  Safari opens.
 
  - Mike
 
  --- In flexcoders@yahoogroups.com 
mailto:flexcoders%40yahoogroups.com

  mailto:flexcoders%40yahoogroups.com, Jurgen Beck jurgen@ wrote:
  
   Hey Mike,
  
   Thanks for the response!
  
   This is happening on Mac OS X with Flex Builder 2.0.1. The system's
   default browser is set to Firefox. For the Flex debugging I'd
like to
   use Safari though. I've been running into some caching issues with
   Firefox that I have documented in another post, thus the reason
to use
   Safari. Safari is at version 3.0.3.
  
   Firefox and Safari are installed in their default locations
   (Applications folder).
  
   I've done a little bit more testing with the External Web Browser
   settings in Preferences and it seems to me that Flex Builder is
having
   difficulties locating the Safari browser instance and is
defaulting to
   the system default browser for debugging, which in my case is
Firefox.
   This, even though the help documentation starts up in Safari
when the
   selection is set to use Safari as the external browser.
  
   So, the question then would be what to specify for the Location and
   Parameters settings in Edit External Web Browser when setting up the
   Safari entry.
  
   Jurgen
  
  
   Mike Morearty wrote:
   
Hi Jurgen,
   
Carlos was correct -- changing the value in Window  Preferences 
General  Web Browser is how you change what browser Flex
Builder uses
to debug. If that doesn't work for you, then something is going
wrong, but I am not aware of any bugs in that area.
   
There is no per-project setting that is in any way related to
this.
The only per-project setting is, what URL is used when
launching; but
this has no effect at all on our choice of which browser to use.
   
Just curious: What operating system are you on? What is your
system
default browser, and what browser are you trying to force Flex
Builder
to use? Is there anything nonstandard about how you installed
any of
your browsers -- e.g. did you install Firefox into a nonstandard
location, or anything like that?
   
I can't really think of much that would be going wrong here,
but with
more info, I might be able to take a guess.
   
- Mike Morearty
Adobe Flex Builder team
http://www.morearty.com/blog http://www.morearty.com/blog

Re: [flexcoders] Re: Stupid question - get ready to throw fruit.

2007-08-29 Thread Jurgen Beck

What about just setting it to null?

myArrayCollection = null;

That should free it up in memory. Isn't that what you need?

Jurgen

candysmate wrote:


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


 Where is the ArrayCollection declared?



 selectedItem is a property of the dataGrid that has a reference to an
 item in the dataProvider. If the DG is gone, then so is the
 selectedItem Property.



 What exactly do you want to happen?



 Tracy

Sorry guys, I didn't explain myself too well. What I want to happen is
to null the ArrayCollection after I've done with it. So it doesn't sit
around in memory hogging resources.

best, Graham

 


Re: [flexcoders] Flex Builder 2.0.1: Change Browser for Debugging

2007-08-29 Thread Jurgen Beck
I asked this yesterday, but I'm not sure if I missed any possible 
responses to it. So here is another quick summary:


How can we change the browser that FB uses for debugging?

Thanks,

Jurgen

Jurgen Beck wrote:


Even though there is a FB Preferences setting for using a browser when
Web pages are opened, this seems to mostly be targeting the display of
help documentation.

If we need to change the specific browser we want to open when FB starts
a debugging process, it seems that the only way of doing this is by
changing the system's default browser.

Now, here is the strange part:

When starting a new Flex project, it seems that the default browser at
that time gets stored into the project preferences somewhere. Even if
the system default browser is being changed, the Flex project debug
process seems to be starting the browser that was the default browser at
the time the project was created and not the current default browser.

So, the question then is, how we can change the browser that a debug
session for a specific project uses? I'd love to be able to set this as
a preference, either per project, or for Flex Builder in general.

Can anyone shed some light on this issue?

Thanks,

Jurgen

 


Re: [flexcoders] Flex Builder 2.0.1: Change Browser for Debugging

2007-08-29 Thread Jurgen Beck
Thanks, but that doesn't seem to have an effect on the browser that the 
debugger uses. This seems to only affect the browser use for the help 
documentation.


I'm sure I'm missing something.

Jurgen

carlos m wrote:

In FB click on the Window  Preferences  General  Web Browser.

HTH,

Carlos

- Original Message 
From: Jurgen Beck [EMAIL PROTECTED]
To: flexcoders@yahoogroups.com
Sent: Wednesday, August 29, 2007 10:06:39 AM
Subject: Re: [flexcoders] Flex Builder 2.0.1: Change Browser for Debugging

I asked this yesterday, but I'm not sure if I missed any possible 
responses to it. So here is another quick summary:


How can we change the browser that FB uses for debugging?

Thanks,

Jurgen

Jurgen Beck wrote:


Even though there is a FB Preferences setting for using a browser when
Web pages are opened, this seems to mostly be targeting the display of
help documentation.

If we need to change the specific browser we want to open when FB starts
a debugging process, it seems that the only way of doing this is by
changing the system's default browser.

Now, here is the strange part:

When starting a new Flex project, it seems that the default browser at
that time gets stored into the project preferences somewhere. Even if
the system default browser is being changed, the Flex project debug
process seems to be starting the browser that was the default browser at
the time the project was created and not the current default browser.

So, the question then is, how we can change the browser that a debug
session for a specific project uses? I'd love to be able to set this as
a preference, either per project, or for Flex Builder in general.

Can anyone shed some light on this issue?

Thanks,

Jurgen





Choose the right car based on your needs. Check out Yahoo! Autos new 
Car Finder tool. 
http://us.rd.yahoo.com/evt=48518/*http://autos.yahoo.com/carfinder/;_ylc=X3oDMTE3NWsyMDd2BF9TAzk3MTA3MDc2BHNlYwNtYWlsdGFncwRzbGsDY2FyLWZpbmRlcg--%20 

 


Re: [flexcoders] Flex Builder 2.0.1: Change Browser for Debugging

2007-08-29 Thread Jurgen Beck

Hey Mike,

Thanks for the response!

This is happening on Mac OS X with Flex Builder 2.0.1. The system's 
default browser is set to Firefox. For the Flex debugging I'd like to 
use Safari though. I've been running into some caching issues with 
Firefox that I have documented in another post, thus the reason to use 
Safari. Safari is at version 3.0.3.


Firefox and Safari are installed in their default locations 
(Applications folder).


I've done a little bit more testing with the External Web Browser 
settings in Preferences and it seems to me that Flex Builder is having 
difficulties locating the Safari browser instance and is defaulting to 
the system default browser for debugging, which in my case is Firefox. 
This, even though the help documentation starts up in Safari when the 
selection is set to use Safari as the external browser.


So, the question then would be what to specify for the Location and 
Parameters settings in Edit External Web Browser when setting up the 
Safari entry.


Jurgen


Mike Morearty wrote:


Hi Jurgen,

Carlos was correct -- changing the value in Window  Preferences 
General  Web Browser is how you change what browser Flex Builder uses
to debug. If that doesn't work for you, then something is going
wrong, but I am not aware of any bugs in that area.

There is no per-project setting that is in any way related to this.
The only per-project setting is, what URL is used when launching; but
this has no effect at all on our choice of which browser to use.

Just curious: What operating system are you on? What is your system
default browser, and what browser are you trying to force Flex Builder
to use? Is there anything nonstandard about how you installed any of
your browsers -- e.g. did you install Firefox into a nonstandard
location, or anything like that?

I can't really think of much that would be going wrong here, but with
more info, I might be able to take a guess.

- Mike Morearty
Adobe Flex Builder team
http://www.morearty.com/blog http://www.morearty.com/blog

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


 Thanks, but that doesn't seem to have an effect on the browser that the
 debugger uses. This seems to only affect the browser use for the help
 documentation.

 I'm sure I'm missing something.

 Jurgen

 carlos m wrote:
  In FB click on the Window  Preferences  General  Web Browser.
 
  HTH,
 
  Carlos
 
  - Original Message 
  From: Jurgen Beck [EMAIL PROTECTED]
  To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
  Sent: Wednesday, August 29, 2007 10:06:39 AM
  Subject: Re: [flexcoders] Flex Builder 2.0.1: Change Browser for
Debugging
 
  I asked this yesterday, but I'm not sure if I missed any possible
  responses to it. So here is another quick summary:
 
  How can we change the browser that FB uses for debugging?
 
  Thanks,
 
  Jurgen
 
  Jurgen Beck wrote:
 
  Even though there is a FB Preferences setting for using a browser
when
  Web pages are opened, this seems to mostly be targeting the
display of
  help documentation.
 
  If we need to change the specific browser we want to open when FB
starts
  a debugging process, it seems that the only way of doing this is by
  changing the system's default browser.
 
  Now, here is the strange part:
 
  When starting a new Flex project, it seems that the default
browser at
  that time gets stored into the project preferences somewhere. Even if
  the system default browser is being changed, the Flex project debug
  process seems to be starting the browser that was the default
browser at
  the time the project was created and not the current default browser.
 
  So, the question then is, how we can change the browser that a debug
  session for a specific project uses? I'd love to be able to set
this as
  a preference, either per project, or for Flex Builder in general.
 
  Can anyone shed some light on this issue?
 
  Thanks,
 
  Jurgen
 
 
 
 
--
  Choose the right car based on your needs. Check out Yahoo! Autos new
  Car Finder tool.
 
http://us.rd.yahoo.com/evt=48518/*http://autos.yahoo.com/carfinder/;_ylc=X3oDMTE3NWsyMDd2BF9TAzk3MTA3MDc2BHNlYwNtYWlsdGFncwRzbGsDY2FyLWZpbmRlcg--%20 
http://us.rd.yahoo.com/evt=48518/*http://autos.yahoo.com/carfinder/;_ylc=X3oDMTE3NWsyMDd2BF9TAzk3MTA3MDc2BHNlYwNtYWlsdGFncwRzbGsDY2FyLWZpbmRlcg--%20


 
 


 


[flexcoders] Flex Builder 2.0.1: Change Browser for Debugging

2007-08-28 Thread Jurgen Beck
Even though there is a FB Preferences setting for using a browser when 
Web pages are opened, this seems to mostly be targeting the display of 
help documentation.

If we need to change the specific browser we want to open when FB starts 
a debugging process, it seems that the only way of doing this is by 
changing the system's default browser.

Now, here is the strange part:

When starting a new Flex project, it seems that the default browser at 
that time gets stored into the project preferences somewhere. Even if 
the system default browser is being changed, the Flex project debug 
process seems to be starting the browser that was the default browser at 
the time the project was created and not the current default browser.

So, the question then is, how we can change the browser that a debug 
session for a specific project uses? I'd love to be able to set this as 
a preference, either per project, or for Flex Builder in general.

Can anyone shed some light on this issue?

Thanks,

Jurgen


[flexcoders] Flex Builder 2.0.1 and Firefox Cache Issues

2007-08-28 Thread Jurgen Beck
This is happening on a Mac OSX environment:

I'm discovering that from time to time the cache in Firefox causes the 
debugger in Flex Builder to behave abnormally. It seems that Firefox 
retrieves a copy of the debug output SWF from its internal cache rather 
than loading it fresh from the output folder.

This behavior causes issues when a new debug build is being debugged and 
is most visible when breakpoints in Flex Builder all of a sudden state 
that there is no code at that location.

I've run into this issue now a few times and most recently couldn't 
figure out why my code wasn't returning the correct data type for a 
service call. Turned out that the Flex debugger was working with an 
outdated (pulled from Firefox cache) version of the application and 
therefore was returning the wrong data type based on old code. Once the 
cache was cleared, everything operated normally and as expected.

Has this problem been documented and other than not allowing Firefox to 
cache the content, has anyone found a resolution to this?

Thanks,

Jurgen


Re: [flexcoders] What's the secret - close button TitleWindow

2007-08-28 Thread Jurgen Beck

Have you looked at the following property for the TitleWindow?

   showCloseButton=true


Jurgen

Ben Marchbanks wrote:


Okay I give up. How you you make the close button ALWAYS visible for a
titleWindow ? I have defined the custom icon for all states yet the
button only appears on mouseOver. The user needs to know there's a
close button there without having to mouseOver don't you think ?

 


Re: [flexcoders] What's the secret - close button TitleWindow

2007-08-28 Thread Jurgen Beck
Also, make sure that when you use your own icon for the close button 
that you include all the states of the button in your skin. If the 
button only shows up when the mouse is over it, there may be an issue 
with your 'up' state skin.


Ben Marchbanks wrote:


Okay I give up. How you you make the close button ALWAYS visible for a
titleWindow ? I have defined the custom icon for all states yet the
button only appears on mouseOver. The user needs to know there's a
close button there without having to mouseOver don't you think ?

 


[flexcoders] new Date() not producing current date

2007-08-27 Thread Jurgen Beck
I am tracking down the source of an issue with the Date() class.

It seems that the following line should be producing today's date:

var now:Date = new Date();

However, when running this today (8/27/2007), the resulting date object 
contains values for 7/1/2007.

Has anyone run into this issue? Is this a bug?

Thanks,

Jurgen


Re: [flexcoders] Re: new Date() not producing current date

2007-08-27 Thread Jurgen Beck
Yup, the system date is correct, as a trace on the 'now' Date object 
shows the correct information, but the individual properties for month 
and day of the now Date object (now.month and now.day) are showing '7' 
and '1' respectively.


I'm sure I'm not seeing something obvious...

Jurgen



candysmate wrote:


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


 I am tracking down the source of an issue with the Date() class.

 It seems that the following line should be producing today's date:

 var now:Date = new Date();

 However, when running this today (8/27/2007), the resulting date object
 contains values for 7/1/2007.

 Has anyone run into this issue? Is this a bug?

 Thanks,

 Jurgen


At the risk of asking an obvious question, I assume that you have
ensured that your current system date is set correctly?

 


Re: [flexcoders] new Date() not producing current date - Clarification

2007-08-27 Thread Jurgen Beck
Actually, it does produce today's date, but the individual properties of 
the Date object are not showing the correct values.


Example:

now.month shows a value of 7
now.day shows a value of 1

Doing a trace on 'now' though shows Mon Aug 27 12:59:18 GMT-0500 2007

Can anyone confirm this behavior? Shouldn't the properties of the 'now' 
Date object show the correct information?


Thanks,

Jurgen Beck


Jurgen Beck wrote:


I am tracking down the source of an issue with the Date() class.

It seems that the following line should be producing today's date:

var now:Date = new Date();

However, when running this today (8/27/2007), the resulting date object
contains values for 7/1/2007.

Has anyone run into this issue? Is this a bug?

Thanks,

Jurgen

 


Re: [flexcoders] Re: new Date() not producing current date

2007-08-27 Thread Jurgen Beck

Thanks, Graham.

As always, it helps reading the documentation carefully. :-)

I didn't see the zero-based mention of the properties...

Cheers,

Jurgen

candysmate wrote:


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


 Yup, the system date is correct, as a trace on the 'now' Date object
 shows the correct information, but the individual properties for month
 and day of the now Date object (now.month and now.day) are showing '7'
 and '1' respectively.

 I'm sure I'm not seeing something obvious...

 Jurgen



I think you're looking for the date of the month. The day is the
number given to the day of the week with Sunday being day 0, Monday
day 1 etc.
The month is also a zero based index with January being month 0, so
this month (August) is 7, which is correct.

best, Graham

 


Re: [flexcoders] Duplicating a component

2007-06-09 Thread Jurgen Beck

Can you post your code?

Jurgen

Robs wrote:


Hi all,
I have a component having 3 combos  2 buttons 'Add'  'Delete'. I
have a scenario wherein the moment I click on 'Add', the entire
component should be duplicated. Currently, on using 'addChild', I'm
getting an index bound error.
Can someone help me please?

Thanks,
Robi.

 


Re: [flexcoders] Re: Flex Component Kit for Flash

2007-06-08 Thread Jurgen Beck

Hi Jason,

Are your issues related to the IFlexDisplayObject too?

So far I haven't seen any response from Matt or Alex. Not that they have 
to respond, but it would be nice to see if this is a known issue. :-)


Jurgen

Jason wrote:


I too am having difficulty accessing a Flash created .swc in Flex.

Hopefully someone will reply and enlighten us both.

:)

 


[flexcoders] Flex Component Kit Issue: mx.core.IFlexDisplayObject marked as extern

2007-06-07 Thread Jurgen Beck
I am getting an error in a large Flex project when trying to use a SWC 
that was produced with the Flex Component Kit in Flash CS3:

Inconsistant linkage in DownloadProgress.swc(mx/core/IFlexDisplayObject) 
- 'mx.core:IFlexDisplayObject' is marked as extern, but 
'mx.core.IFlexDisplayObject' is not.

Unless I missed something, adding the SWC to the project should be 
pretty straight forward. I have set up a small test application where I 
am not getting the error.

Anyone run into this issue?

Thanks,

Jurgen



Re: [flexcoders] Landscape printing in Flex

2007-06-04 Thread Jurgen Beck

Look at the PrintJobOrientation class and see if that helps:

http://livedocs.adobe.com/flex/2/langref/flash/printing/PrintJobOrientation.html

Jurgen

archtechcomputers wrote:


Is there anyway to define landscape to the printer?

I am working on a project that I need to print a single page that is in
landscape. I've created a component that is 800 x 600, the print job
adds that component as an print object and sends. If under the system
printer dialog box, I don't choose landscape, it won't print out
properly. I've tried rotating the object 90 degrees during the print
process and no luck.

Any suggestions?

thanks

 


Re: {Disarmed} RE: [flexcoders] Landscape printing in Flex

2007-06-04 Thread Jurgen Beck
I'm curious, Mike. While the PrintJob.orientation property is read-only, 
you can rotate the sprite based on what the orientation setting of the 
printer is. Wouldn't that work?


Jurgen

Mike Weiland wrote:


Unfortunelty there is no way to set the orientation, it is read only. 
What I do for http://www.CertificateCreator.com/ 
http://www.CertificateCreator.com/ is when someone prints is to tell 
them to set their printer to landscape. Once the print job is 
processed I check the orientation and if it was not set to landscape I 
alert them that their printer was not in landscape mode and for full 
page printing they need to set their orientation to landscape.


This has been one of my requests since printing was added to Flash 4.

Good luck,

Mike Weiland

Original Message ---
Is there anyway to define landscape to the printer?

I am working on a project that I need to print a single page that is in
landscape. I've created a component that is 800 x 600, the print job
adds that component as an print object and sends. If under the system
printer dialog box, I don't choose landscape, it won't print out
properly. I've tried rotating the object 90 degrees during the print
process and no luck.

Any suggestions?

thanks

 


Re: [flexcoders] frustrating error thats a non error

2007-06-04 Thread Jurgen Beck
How are you setting up the ns1 namespace? Make sure it points to the 
correct location.


Jurgen

iilsley wrote:



Could not resolve ns1:comp to a component implementation. main.mxml

If I just a blank new line to main.mxml and save it the error goes away
, if I then modify comp.mxml and save changes the error comes back until
I modify and re-save main.mxml ..

 


Re: [flexcoders] summing a value in an arrayCollection?

2007-06-03 Thread Jurgen Beck

Need to correct (add) one line. Forgot to add the cursor.moveNext():

var cursor:IViewCursor = myAC.createCursor();
var sumPop:int = 0;

var myObject:Object;
while (!cursor.afterLast) {
   myObject = cursor.current;
   sumPop += myObject.population;
   cursor.moveNext();

}



Jurgen Beck wrote:


Hi Todd,

One of the ways would be to traverse your ArrayCollection with a cursor:

var cursor:IViewCursor = myAC.createCursor();
var sumPop:int = 0;
var myObject:Object;
while (!cursor.afterLast) {
myObject = cursor.current;
sumPop += myObject.population;
}

Jurgen

todd_geist wrote:


Hello,

Very new here. Trying to get some of the basics. I have datagrid
that is populated with the following arrayColleciton

mx:ArrayCollection id=myAC
mx:Array
mx:Object city=Los Angeles state=CA
population=3844829 /
mx:Object city=New York state=NY population=8143197 /
mx:Object city=Chicago state=IL population=2842518 /
mx:Object city=Philadelphia state=PA
population=1463281 /
/mx:Array
/mx:ArrayCollection

How do I go about getting the sum of the population?

Thanks in advance for any advice.

Todd

 


Re: [flexcoders] Change Object Reference

2007-06-03 Thread Jurgen Beck
Rather than just assigning the model.someObject directly to the vo 
object, you may first need to instantiate it with:


var vo:Object = new Object();

The assign the model.someObject to it:

vo = model.someObject;

When you then assign a different object to it, it should leave 
model.someObject alone and just use the newly assigned object.


Jurgen

Kevin wrote:


This may be a simple question, but it's stumping me.

I have a component that contains a property (type object) that holds
a reference to an VO on my model.

How to I unlink that reference?

For example, when I set the property:

var vo : Object = model.someObject;

I then do something like this:

vo = someNewObject;

This happens
model.someObject get's set to someNewObject...

This is not what I want. Therefore, I assume I have to unlink the
reference of vo to model.someObject, before I give it another
reference. How do I do that?

Thanks, Kevin

 


Re: [flexcoders] Change Object Reference

2007-06-03 Thread Jurgen Beck

Hey Kevin,

See if this makes sense in your configuration:

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

   mx:Script
   ![CDATA[
  
   private var obj1:Object = new Object();

   private var obj2:Object = new Object();
   [Bindable] private var objRef:Object = new Object();
  
   private function initApp():void {
  
   obj1.text = test1;

   obj2.text = test2;
  
   txtObject0.text = obj1.text;

   txtObject1.text = obj2.text;
  
   objRef = obj1;
  
   }
  
   private function switchObjects(event:Event):void {

   objRef = obj2; // testing reassigning of objects
   txtObject0.text = obj1.text;
   txtObject1.text = obj2.text;   
   }
  
   ]]

   /mx:Script
  
   mx:Panel id=myPanel width=538 height=334 layout=absolute

   mx:VBox width=100% height=100% x=10 y=10
   mx:Label text=VO Object/
   mx:TextArea width=498 id=txtObject borderStyle=solid 
text={objRef.text}/

   mx:Label text=someObject/
   mx:TextArea width=498 id=txtObject0 borderStyle=solid/
   mx:Label text=someNewObject/
   mx:TextArea width=498 id=txtObject1 borderStyle=solid/
   mx:Button click=switchObjects(event) label=Switch 
Objects/

   /mx:VBox
   /mx:Panel
  
/mx:Application


You'll see objRef taking on the new object values and leaving obj1 alone 
when you switch object assignments.


Jurgen

Kevin wrote:


i couldn't get either of these solutions to work.  When I reset the vo 
variable to nul (or new Object), it still modifies the object on the 
model.  I could be doing something wrong, but for now, i decided to 
instantiate an entirely new super class each time the vo changes.



I'll look into this a little more and see if I can do what I want...

thanks, Kevin




On Jun 3, 2007, at 9:33 AM, Jurgen Beck wrote:

Rather than just assigning the model.someObject directly to the vo 
object, you may first need to instantiate it with:


var vo:Object = new Object();

The assign the model.someObject to it:

vo = model.someObject;

When you then assign a different object to it, it should leave 
model.someObject alone and just use the newly assigned object.


Jurgen

Kevin wrote:


This may be a simple question, but it's stumping me.

I have a component that contains a property (type object) that holds
a reference to an VO on my model.

How to I unlink that reference?

For example, when I set the property:

var vo : Object = model.someObject;

I then do something like this:

vo = someNewObject;

This happens
model.someObject get's set to someNewObject...

This is not what I want. Therefore, I assume I have to unlink the
reference of vo to model.someObject, before I give it another
reference. How do I do that?

Thanks, Kevin





 


Re: {Disarmed} [flexcoders] Flex Component Kit for Flash CS3 - item not showing

2007-06-02 Thread Jurgen Beck
Does the Design view in FB give you any errors? If so, you'd need to 
look closer at the code.


Jurgen

Mark wrote:


I created a simple test in Flash CS3 that mostly works in Flex. The
problem I'm having is I don't see it in Flex Builder 2. Code view is
giving me everything it should and looks fine there, but I don't see
it in Design view. What would be the reason for this? I run it and
it looks just fine.

Thanks,
Mark

 


Re: [flexcoders] Flex Component Kit for Flash CS3 - item not showing

2007-06-02 Thread Jurgen Beck

If the MXML file isn't too big, can you post the contents?

The MXML file is a regular ASCII file that you can edit in any text 
editor. If FB has an issue parsing the code for design view it usually 
means that the file contains some illegal code.


Jurgen

Mark wrote:


No, no errors. It runs perfectly it just doesn't display within FB.
Wether I run it nromal or in debug mode, what shows in the browser
is fine.

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


 Does the Design view in FB give you any errors? If so, you'd need
to
 look closer at the code.

 Jurgen

 Mark wrote:
 
  I created a simple test in Flash CS3 that mostly works in Flex.
The
  problem I'm having is I don't see it in Flex Builder 2. Code
view is
  giving me everything it should and looks fine there, but I don't
see
  it in Design view. What would be the reason for this? I run it
and
  it looks just fine.
 
  Thanks,
  Mark
 
 


 


Re: [flexcoders] WebServices and ObjectProxy

2007-06-02 Thread Jurgen Beck
Let's back up for a minute. What exactly are you returning from your web 
service? If you are returning an object that can be mapped to a Flex 
value object, then you would do that in the result handler of the remote 
object in Flex. That is where you would be using the line specified.


Now, in a data grid you typically use an array collection or a normal 
array as the dataprovider. That array or array collection would contain 
a collection of the mapped VOs you are returning from your web service. 
The key here is to properly map the returned data to your VO. You can 
then reference the data field properly by going for the VO object element.


The question of what you are returning from the web service is 
important. The format may look different based on the back-end 
technology you are using (PHP, .NET, etc.)


We may need a bit more information on the environment you are running 
this on.


Jurgen



ehsiao_bea wrote:


Hi, Jurgen,

Not sure how you can do this within the DataGrid Control itself. Can
you please elaborate?
I would like to bind Physician.Firstname to the DataField.

JT

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


 When returning a result set, make sure you are accessing the proxy
 through the object property:

 var myObject:yourVO = event.result.object as yourVO;

 Jurgen

 ehsiao_bea wrote:
 
 
  I am calling a web service and the objects are being wrapped with
  mx.utils.objectProxy. However, I can't seem to get the property from
  the objectProxy by calling the getProperty method.
 
  mx:DataGrid x=21 y=230 id=PatientRecord width=792
  dataProvider={wsGetPatientData.getByPatientId.lastResult}
  mx:columns
 
  mx:DataGridColumn headerText=Symptoms
  dataField=Symptoms/
  mx:DataGridColumn headerText=Diagnosis
  dataField=Diagnosis/
  mx:DataGridColumn headerText=Notes dataField=Notes/
  mx:DataGridColumn headerText=Physican
  dataField=Physician.getProperty(FirstName)/
 
  /mx:columns
 
  Symptons, Diagnosis and Notes are coming back ok. Physician is a
  objectproxy and I would like to get the FirstName QName from it. I
  can see it in the debugger but the getProperty call does not seem to
  do anything for me. Any hints?
 
  Thanks,
  JT
 
 


 


Re: [flexcoders] summing a value in an arrayCollection?

2007-06-02 Thread Jurgen Beck

Hi Todd,

One of the ways would be to traverse your ArrayCollection with a cursor:

var cursor:IViewCursor = myAC.createCursor();
var sumPop:int = 0;
var myObject:Object;
while (!cursor.afterLast) {
   myObject = cursor.current;
   sumPop += myObject.population;
}

Jurgen

todd_geist wrote:


Hello,

Very new here. Trying to get some of the basics. I have datagrid
that is populated with the following arrayColleciton

mx:ArrayCollection id=myAC
mx:Array
mx:Object city=Los Angeles state=CA
population=3844829 /
mx:Object city=New York state=NY population=8143197 /
mx:Object city=Chicago state=IL population=2842518 /
mx:Object city=Philadelphia state=PA
population=1463281 /
/mx:Array
/mx:ArrayCollection

How do I go about getting the sum of the population?

Thanks in advance for any advice.

Todd

 


Re: [flexcoders] Re: Flex Component Kit for Flash CS3 - item not showing

2007-06-02 Thread Jurgen Beck

Sorry about that! That was obvious. :-)   It's been a long week...

Flex components created in Flash will not show up in Design View. Adobe 
says that this will be addressed in a future update of Flex (well, 'next 
version'.)


So, if you're compiled app is showing the component, you're good to go.

Jurgen

grantdotcox wrote:


I've only made a few components using the Flex Component Kit, but none
of them display in Flex Builder design view. As they work in the
compiled swf I assumed that was the expected behaviour... ?

Jurgen - What MXML? The component kit creates SWC files...

 


Re: {Disarmed} [flexcoders] WebServices and ObjectProxy

2007-06-01 Thread Jurgen Beck
When returning a result set, make sure you are accessing the proxy 
through the object property:


var myObject:yourVO = event.result.object as yourVO;

Jurgen

ehsiao_bea wrote:



I am calling a web service and the objects are being wrapped with
mx.utils.objectProxy. However, I can't seem to get the property from
the objectProxy by calling the getProperty method.

mx:DataGrid x=21 y=230 id=PatientRecord width=792
dataProvider={wsGetPatientData.getByPatientId.lastResult}
mx:columns

mx:DataGridColumn headerText=Symptoms
dataField=Symptoms/
mx:DataGridColumn headerText=Diagnosis
dataField=Diagnosis/
mx:DataGridColumn headerText=Notes dataField=Notes/
mx:DataGridColumn headerText=Physican
dataField=Physician.getProperty(FirstName)/

/mx:columns

Symptons, Diagnosis and Notes are coming back ok. Physician is a
objectproxy and I would like to get the FirstName QName from it. I
can see it in the debugger but the getProperty call does not seem to
do anything for me. Any hints?

Thanks,
JT

 


Re: {Disarmed} [flexcoders] URL parameters into mx:application

2007-05-31 Thread Jurgen Beck
You do this the same way you would with a Flash application. You can use 
flashvars to do that, which become available in your application.


Look for info on Flex and flashvars.

Jurgen

Rohan Pinto wrote:


how do I pass URL parameters into my application ? I need to be able
to pass URL parameters into my app in order to display the appropriate
components based on the URL... any advise ?

 


[flexcoders] creationPolicy Issues?

2007-05-30 Thread Jurgen Beck
I'm running into a strange problem with the Accordion container. Setting 
creationPolicy to 'all' on the Accordion container will not force the 
controls in all the views to be created. It behaves as if it is still 
set to the default (auto).

Anyone run into the same problem?

Jurgen


[flexcoders] Re: creationPolicy Issues? - Issue solved

2007-05-30 Thread Jurgen Beck
Well, this goes into the category of 'Where does Flex create the project 
files?' quirks:


Quick answer: The debugger was pointing to a location where Flex 
essentially wasn't building the latest compiles.


Long answer: If you ever run into really strange issues where you are 
convinced that it should be working, but ti doesn't, check that the 
build path and the output folder URL point to the same location.


Explanation:
I'm running Flex on a Mac, but am working on a .NET based server end 
solution, so I have to essentially build the Flex app against the IIS 
server location on a network Win2003 drive.


Problem with the Mac is that it doesn't play well with the Windows 
network (at least so far), so it always looses the shared drives when I 
put it to sleep. Waking it up and reconnecting the networked shares 
messes up Flex when the shared name all of a sudden changes (because the 
Mac assigns a different name to it dynamically).


So, all this to say that creationPolicy works as expected and this is 
something external to Flex, but still the source of some frustration if 
you don't pay attention to it.


Hope this helps someone else! :-)

Jurgen

Jurgen Beck wrote:


I'm running into a strange problem with the Accordion container. Setting
creationPolicy to 'all' on the Accordion container will not force the
controls in all the views to be created. It behaves as if it is still
set to the default (auto).

Anyone run into the same problem?

Jurgen

 


[flexcoders] Events in AS3 Classes

2007-05-30 Thread Jurgen Beck
I know that I can write my own custom event class, but I was wondering 
about something that seems to be undocumented and that seems to 
initially be promising:

When adding a meta tag to an AS class such as:

[Event(name=myEvent,type=flash.events.Event)]

the event shows up when using the class by creating an event listener. 
The interesting thing is that code assist picks it up, but it shows up 
with an altered signature:

myClass.addEventListener(Event.MY_EVENT,myEventHandler);

I wasn't able to find any documentation on it. So I am wondering if this 
would actually work. At the moment I'm not able to fully test it, as the 
compiler throws an error with my static class (defined as a singleton) 
stating: Error 1119: Access of possibly undefined property MY_EVENT 
through a reference with static type Class.

If this is legal code, then the question would be how to 'define the 
property' so that the compiler is satisfied.

Does anyone have more information on this?

Thanks,

Jurgen


Re: {Disarmed} [flexcoders] Re: Events in AS3 Classes

2007-05-30 Thread Jurgen Beck

Makes sense. Thanks, Justin!

Jurgen

justinbuser wrote:


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


 I know that I can write my own custom event class, but I was wondering
 about something that seems to be undocumented and that seems to
 initially be promising:

 When adding a meta tag to an AS class such as:

 [Event(name=myEvent,type=flash.events.Event)]

 the event shows up when using the class by creating an event listener.
 The interesting thing is that code assist picks it up, but it shows up
 with an altered signature:

 myClass.addEventListener(Event.MY_EVENT,myEventHandler);

 I wasn't able to find any documentation on it. So I am wondering if
this
 would actually work. At the moment I'm not able to fully test it, as
the
 compiler throws an error with my static class (defined as a singleton)
 stating: Error 1119: Access of possibly undefined property MY_EVENT
 through a reference with static type Class.

 If this is legal code, then the question would be how to 'define the
 property' so that the compiler is satisfied.

 Does anyone have more information on this?

 Thanks,

 Jurgen

Make your own event class to start, I posted an example on livedocs
here
http://livedocs.adobe.com/flex/201/langref/flash/events/Event.html 
http://livedocs.adobe.com/flex/201/langref/flash/events/Event.html The

capitalization and underscore are an assumption and not actually
defined until you create a class.

 


Re: {Disarmed} [flexcoders] Re: Events in AS3 Classes

2007-05-30 Thread Jurgen Beck

I sent the response off a bit too quick. Here is more:

I was actually positively surprised to see it show up. I am a big 
advocate of strong typing, as it make programming that much more 
straight forward and helps reduce bugs and errors.


What I wish we would have in Flex/AS3 is a way to have simple 'custom' 
events (those that don't require additional objects or arguments 
packaged with it) to self-register through a new class.


Jurgen

justinbuser wrote:


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


 I know that I can write my own custom event class, but I was wondering
 about something that seems to be undocumented and that seems to
 initially be promising:

 When adding a meta tag to an AS class such as:

 [Event(name=myEvent,type=flash.events.Event)]

 the event shows up when using the class by creating an event listener.
 The interesting thing is that code assist picks it up, but it shows up
 with an altered signature:

 myClass.addEventListener(Event.MY_EVENT,myEventHandler);

 I wasn't able to find any documentation on it. So I am wondering if
this
 would actually work. At the moment I'm not able to fully test it, as
the
 compiler throws an error with my static class (defined as a singleton)
 stating: Error 1119: Access of possibly undefined property MY_EVENT
 through a reference with static type Class.

 If this is legal code, then the question would be how to 'define the
 property' so that the compiler is satisfied.

 Does anyone have more information on this?

 Thanks,

 Jurgen

Make your own event class to start, I posted an example on livedocs
here
http://livedocs.adobe.com/flex/201/langref/flash/events/Event.html 
http://livedocs.adobe.com/flex/201/langref/flash/events/Event.html The

capitalization and underscore are an assumption and not actually
defined until you create a class.

 


Re: {Disarmed} [flexcoders] Just getting started, hitting walls...

2007-05-30 Thread Jurgen Beck

Welcome to the community, Dave, good to have you!

Essentially, the key to what you are trying to do is split up your 
application into individual modules. It's a bit difficult to give you a 
link to a single source that will step you through the process, because 
there are a number of items you'll have to look into. Someone may have a 
few bits and pieces of write-ups, but essentially you will need to look 
for the following:


- Working with modules in Flex
- May need to look at Cairngorm for a unified approach for large 
applications


Working with modules will allow you to essentially create smaller 
portions of your application that you can reuse (if needed), but will 
keep your code in your main application concise. Look at the 
documentation for information on modules in Flex.


Jurgen

Dave @ VitalPodcasts.com wrote:


Hello Flex Community,
I am a very experienced CF developer, and I want to get into Flex.
Perhaps it makes more sense to coem from Flash, however Adobe is
letting CF jobs disappear everywhere, so its time to upgrade my skill
set.

here is the issues I am running into.

Client Side Application:
Of course this is completely different than the Web where we have
sessions, Im used to the web, need to rethink to my old way of
thinking. But here is my issue, I want to make LARGE applications,
with many screens, and lots of functionality. How do I make an app
that has multiple screen, I really do not feel like having 100's of
objects on my MXML file waiting for visible = true to be set.

Where is a decent walk through on how to develop a major app, not a
resturant finder, an actual full blown application. I want to create
other screens, with their own functions, maybe some modules...

How do I make code, or set up my project so its not some huge mess of
code on one of few files?

 


Re: {Disarmed} [flexcoders] SWF Size gets bigger (and bigger... but why??)

2007-05-30 Thread Jurgen Beck
Can't tell you why it is growing, other than agreeing with you that at 
times the compiled app is growing beyond what it should be.


You can use the Project-Clean... command in Flex Builder to clean your 
project and reduce the SWF size to what it normally is.


Hope this helps,

Jurgen

patricklemiuex wrote:


I noticed i changed about 4 lines of code in my app and then compiled
- it went from 420K to 634K... So, I copied my MXML file into a new
MXML File and then my compile size is back to normal?

Does anyone know why this happens? Kinda sucks, yes?

Thanks,
Patrick

 


Re: {Disarmed} Re: {Disarmed} [flexcoders] Just getting started, hitting walls...

2007-05-30 Thread Jurgen Beck
Code is code. Not wanting to sound rude, but as with any other 
application that requires visual elements, you'll have to eventually 
create them somehow.


The huge difference Flex makes is how you go about it. Essentially you 
will need to work with display containers, such as canvases, panels and 
the likes. However, Flex lets you break all this up into smaller pieces. 
Look for information on creating your own custom components, which 
sounds way harder than it actually is.


On a higher level you can package components you have created (what you 
may call 'screens') and put them into separate modules.


The key is to divide and conquer. Flex helps you quite a bit with it by 
using MXML components and modules.


Jurgen

Dave @ VitalPodcasts.com wrote:


I feel like its back to the Old QBasic ways...
Make one super long file that does everything, thats kind of nuts.

You mean there isn't a Load NextScreen type of thing? Where a whole
new set of objects live? and I don't have to worry about hiding
everything?

So far it feels to me, so far, I need to create lots canvases for the
different screens the application uses, and then create a funciton
that hides all but the one in focus...

Can anyone describe how they setup their code?

As far as logic, Im not too worried abotu that as most the logic will
be in CF webservices, im more worried about having an insane amount of
visual code in the MXML.

 


Re: {Disarmed} Re: {Disarmed} [flexcoders] Just getting started, hitting walls...

2007-05-30 Thread Jurgen Beck

I'll address your first question:

I'm doing this all the time. I'm working on my fourth huge Flex 
application. I've been developing enterprise type distributed 
applications for over 15 years and I can tell you that Flex is one of my 
favorite tools in terms of creating large RIA type apps. With Flex you 
now have the ability to bring to the web what previously has been mostly 
the domain of applications developed for the desktop/workstation world.


Jurgen

Dave @ VitalPodcasts.com wrote:


From every example I see, its small apps, realesate finder, resturant
finders...

Is it possible, and when I mena possible, is it realistc to make
something like a CMS in Flex?

if anyone has a good tutorial on how to make modular code, and make a
nice seperated program design, I would love to see it... everything
google is turning up doesnt even come close to addressing entreprise
level application needs.

 


Re: {Disarmed} RE: {Disarmed} [flexcoders] SWF Size gets bigger (and bigger... but why??)

2007-05-30 Thread Jurgen Beck
I'm on the Mac, so some of this you may to look and see what the Windows 
equivalent is. But here are two things that you can do/use to make your 
coding life easier:


Use the Command key (I think it's ALT in Windows) to hold down over a 
definition (function call, class, property) and Flex Builder will 
underline the word, which is an indication of a hyper link to the actual 
definition of the class, function, or property. VERY handy to quickly 
jump to your declarations.


The other would be to use the Outline window in Flex Builder, which 
shows your properties and methods that you can jump to by 
double-clicking on them.


Also, the Key Assist window shows the shortcuts in Flex Builder. You can 
find it on the Help menu, or use the associated keyboard shortcut (the 
Help menu should tell you what it is).


David Zuckerman did a presentation at 360Flex where he showed a number 
of really useful tips and tricks. You can read up on it and view the 
presentation here:


http://davidzuckerman.com/adobe/2007/03/11/my-360flex-presentation-flex-builder-secrets/

Hope this helps,

Jurgen

{reduxDJ} wrote:


Jurgen:

 

I've only been using flex for about 9 months now and eclipse only for 
about 2 months before that.  I know a lot of you more experienced 
developers know a lot of hidden features that were ported over from 
eclipse, like how to skip to certain methods while editing a file, the 
clean project command -- I am sure there's a lot more.  Is there a 
known list of handy shortcuts, especially for finding stuff in a long 
application.  Control-F is tiresome.


 


Thanks for the tip,
Patrick

 




*From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
*On Behalf Of *Jurgen Beck

*Sent:* Wednesday, May 30, 2007 11:39 AM
*To:* flexcoders@yahoogroups.com
*Subject:* Re: {Disarmed} [flexcoders] SWF Size gets bigger (and 
bigger... but why??)


 

Can't tell you why it is growing, other than agreeing with you that at 
times the compiled app is growing beyond what it should be.


You can use the Project-Clean... command in Flex Builder to clean 
your project and reduce the SWF size to what it normally is.


Hope this helps,

Jurgen

patricklemiuex wrote:


I noticed i changed about 4 lines of code in my app and then compiled
- it went from 420K to 634K... So, I copied my MXML file into a new
MXML File and then my compile size is back to normal?

Does anyone know why this happens? Kinda sucks, yes?

Thanks,
Patrick

 


Re: [flexcoders] [OT] Where is Disarmed coming from? Was:Just getting started, hitting walls...

2007-05-30 Thread Jurgen Beck

Sorry, that is my spam filter kicking in and me not watching it. :-)

I'll try to do better and taking them out!

Jurgen

Colin Prince wrote:


Sorry off topic (the specific topic anyway)

Where is the {Disarmed} label coming from in the subject line? Any
chance of getting rid of it?

Cheers,
Colin.

Jurgen Beck wrote:
 Welcome to the community, Dave, good to have you!

 Essentially, the key to what you are trying to do is split up your
 application into individual modules. It's a bit difficult to give you
 a link to a single source that will step you through the process,
 because there are a number of items you'll have to look into. Someone
 may have a few bits and pieces of write-ups, but essentially you will
 need to look for the following:

 - Working with modules in Flex
 - May need to look at Cairngorm for a unified approach for large
 applications

 Working with modules will allow you to essentially create smaller
 portions of your application that you can reuse (if needed), but will
 keep your code in your main application concise. Look at the
 documentation for information on modules in Flex.

 Jurgen

 Dave @ VitalPodcasts.com wrote:

 Hello Flex Community,
 I am a very experienced CF developer, and I want to get into Flex.
 Perhaps it makes more sense to coem from Flash, however Adobe is
 letting CF jobs disappear everywhere, so its time to upgrade my skill
 set.

 here is the issues I am running into.

 Client Side Application:
 Of course this is completely different than the Web where we have
 sessions, Im used to the web, need to rethink to my old way of
 thinking. But here is my issue, I want to make LARGE applications,
 with many screens, and lots of functionality. How do I make an app
 that has multiple screen, I really do not feel like having 100's of
 objects on my MXML file waiting for visible = true to be set.

 Where is a decent walk through on how to develop a major app, not a
 resturant finder, an actual full blown application. I want to create
 other screens, with their own functions, maybe some modules...

 How do I make code, or set up my project so its not some huge mess of
 code on one of few files?


 


Re: {Disarmed} RE: {Disarmed} RE: [flexcoders] Flickr - Issue with LoaderContext

2007-05-29 Thread Jurgen Beck
All true. Seeing that there really is no alternative other than using a 
proxy server, I implemented a solution that seems to be working for this 
specific application.


I ended up using at32.com ReverseProxy (http://www.at32.com), which is 
for Windows. As long as the reverse proxy is bound to the IP address 
that the Flex application is running on not even a crossdomain.xml is 
needed.


Hope this helps someone else.

Jurgen

Alex Harui wrote:


Roughly speaking:

 


AppDom/SecDom are for ActionScript code/classes.

crossdomain.xml allows you to import code/classes into the same 
SecDom/AppDom so you can use the classes, otherwise you end up in a 
separate sandbox


All instances of things in a separate sandbox are off-limits, and 
cannot access you either.


crossdomain.xml also allows you to access the display area of 
displayobjects and image data because it effectively imports that 
thing into your sandbox


AllowDomain permits code in another sandbox to touch things in your 
sandbox


 

There is a security white paper on adobe.com that tries to explain 
all of this.  The idea is that you cannot use Flash as a screenscraper 
of other flash content or image data w/o permission of the server 
owner for both spoofing and server load reasons.  And, of course, you 
don't want to accidentally load bad code and have it steal stuff from you.


 

Flickr used to have crossdomain.xml files in the correct places, but 
pulled them for some reason.  I think if you google around you'll find 
out why.  So suddenly, they've made flash apps harder and proxy 
servers are needed.


 


HTH,

-Alex

 

 

 




*From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
*On Behalf Of *Jurgen Beck

*Sent:* Saturday, May 26, 2007 5:14 AM
*To:* flexcoders@yahoogroups.com
*Subject:* Re: {Disarmed} RE: [flexcoders] Flickr - Issue with 
LoaderContext


 

I had this working for most part, retrieving and displaying the images 
from Flickr, but BitmapData.draw was always throwing a security 
sandbox violation when I needed to hide the canvas the Flickr images 
were displayed in. Karl Johnson has written more about it here:


http://www.cynergysystems.com/blogs/page/karljohnson?entry=working_around_security_sandbox_errors 
http://www.cynergysystems.com/blogs/page/karljohnson?entry=working_around_security_sandbox_errors


The problem is that the crossdomain.xml is at 
http://api.flickr.com/crossdomain.xml 
http://api.flickr.com/crossdomain.xml, but the actual images are 
pulled from http://farm1.static.flickr.com/ 
http://farm1.static.flickr.com/... So running the app, I am seeing 
an error:


Failed to load policy file from 
http://farm1.static.flickr.com/crossdomain.xml 
http://farm1.static.flickr.com/crossdomain.xml


We're obviously not loading the crossdomain.xml from the right place, 
as there is no crossdomain.xml at that location.


Next, I looked closer at James Ward's example of using Ely's 
DisplayShelf component to retrieve images from Flickr:


http://www.jamesward.org/wordpress/2006/11/06/flex-widgets-from-widgetslive/ 
http://www.jamesward.org/wordpress/2006/11/06/flex-widgets-from-widgetslive/


The AppDom and SecDom approach is taken from Ely's DisplayShelf 
component, where he uses it with the SWFLoader. May not be needed for 
images, I simply just left it in there.


I've taken a second look at Jame's write-up and he's posted a 
follow-up in the comment section on April 20, 2007 where he's showing 
a proxy setup to get around the issues at hand. His example wouldn't 
work either until the proxy setup was in place.


This may be what I have to do as well. It's just amazing to me that 
there is no unified approach to this. I agree with you, either you 
have access permission to the images, or you don't.


Jurgen

Alex Harui wrote:

I'm not clear that AppDom and SecDom affect loading images (JPG, GIF, 
etc).  You either have permission from the crossdomain.xml at 
flickr.com or you don't.


 


You can almost always load it, you just can't always access its pixels.

 




*From:* flexcoders@yahoogroups.com 
[mailto:[EMAIL PROTECTED] *On Behalf Of *Jurgen Beck

*Sent:* Friday, May 25, 2007 3:34 PM
*To:* flexcoders@yahoogroups.com
*Subject:* [flexcoders] Flickr - Issue with LoaderContext

 


I'm running into security sandbox violation issues trying to load images
from a Flickr account.

Since the Image component derives from SWFLoader I am setting the
LoaderContext before the image source is assigned. The image component
is used inside my custom component, which in turn is used as an
itemRenderer in a TileList.

Here is the image component code fragment:

mx:Image id=imgThumbnail
source={data.url}
initialize=imageInit()
width=75 height=75/

Here is my imageInit() method:

private function imageInit():void {
loaderContext = new LoaderContext

Re: {Disarmed} RE: [flexcoders] Flickr - Issue with LoaderContext

2007-05-26 Thread Jurgen Beck
I had this working for most part, retrieving and displaying the images 
from Flickr, but BitmapData.draw was always throwing a security sandbox 
violation when I needed to hide the canvas the Flickr images were 
displayed in. Karl Johnson has written more about it here:


http://www.cynergysystems.com/blogs/page/karljohnson?entry=working_around_security_sandbox_errors

The problem is that the crossdomain.xml is at 
http://api.flickr.com/crossdomain.xml, but the actual images are pulled 
from http://farm1.static.flickr.com/... So running the app, I am seeing 
an error:


Failed to load policy file from 
http://farm1.static.flickr.com/crossdomain.xml


We're obviously not loading the crossdomain.xml from the right place, as 
there is no crossdomain.xml at that location.


Next, I looked closer at James Ward's example of using Ely's 
DisplayShelf component to retrieve images from Flickr:


http://www.jamesward.org/wordpress/2006/11/06/flex-widgets-from-widgetslive/

The AppDom and SecDom approach is taken from Ely's DisplayShelf 
component, where he uses it with the SWFLoader. May not be needed for 
images, I simply just left it in there.


I've taken a second look at Jame's write-up and he's posted a follow-up 
in the comment section on April 20, 2007 where he's showing a proxy 
setup to get around the issues at hand. His example wouldn't work either 
until the proxy setup was in place.


This may be what I have to do as well. It's just amazing to me that 
there is no unified approach to this. I agree with you, either you have 
access permission to the images, or you don't.


Jurgen

Alex Harui wrote:


I'm not clear that AppDom and SecDom affect loading images (JPG, GIF, 
etc).  You either have permission from the crossdomain.xml at 
flickr.com or you don't.


 


You can almost always load it, you just can't always access its pixels.

 




*From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
*On Behalf Of *Jurgen Beck

*Sent:* Friday, May 25, 2007 3:34 PM
*To:* flexcoders@yahoogroups.com
*Subject:* [flexcoders] Flickr - Issue with LoaderContext

 


I'm running into security sandbox violation issues trying to load images
from a Flickr account.

Since the Image component derives from SWFLoader I am setting the
LoaderContext before the image source is assigned. The image component
is used inside my custom component, which in turn is used as an
itemRenderer in a TileList.

Here is the image component code fragment:

mx:Image id=imgThumbnail
source={data.url}
initialize=imageInit()
width=75 height=75/

Here is my imageInit() method:

private function imageInit():void {
loaderContext = new LoaderContext();
loaderContext.applicationDomain =
ApplicationDomain.currentDomain;
loaderContext.securityDomain =
SecurityDomain.currentDomain;
loaderContext.checkPolicyFile = true;
imgThumbnail.loaderContext = loaderContext;
}

I've traced through the processes and the LoaderContext is definitely in
place before the image source gets assigned, so I should be good.
However, the application is still returning a security sandbox violation
error stating that the connection to 
http://farm1.static.flickr.com/... http://farm1.static.flickr.com/...

was halted - not permitted from [my server].

This obviously should be working fine. Looking through Ely's
DisplayShelf component, there are no such issues. So the question is
what else is missing.

Anyone with some thoughts?

Thanks,

Jurgen

 


[flexcoders] Flickr - Issue with LoaderContext

2007-05-25 Thread Jurgen Beck
I'm running into security sandbox violation issues trying to load images 
from a Flickr account.

Since the Image component derives from SWFLoader I am setting the 
LoaderContext before the image source is assigned. The image component 
is used inside my custom component, which in turn is used as an 
itemRenderer in a TileList.

Here is the image component code fragment:

mx:Image id=imgThumbnail
source={data.url}
initialize=imageInit()   
width=75 height=75/

Here is my imageInit() method:

private function imageInit():void {
loaderContext = new LoaderContext();
loaderContext.applicationDomain = 
ApplicationDomain.currentDomain;
loaderContext.securityDomain = 
SecurityDomain.currentDomain;  
loaderContext.checkPolicyFile = true;
imgThumbnail.loaderContext = loaderContext;
}   

I've traced through the processes and the LoaderContext is definitely in 
place before the image source gets assigned, so I should be good. 
However, the application is still returning a security sandbox violation 
error stating that the connection to http://farm1.static.flickr.com/... 
was halted - not permitted from [my server].

This obviously should be working fine. Looking through Ely's 
DisplayShelf component, there are no such issues. So the question is 
what else is missing.

Anyone with some thoughts?

Thanks,

Jurgen


Re: {Disarmed} [flexcoders] Possible to send object to POST data?

2007-05-23 Thread Jurgen Beck
You might want to check out WebORB for PHP at 
http://www.themidnightcoders.com.


http://themidnightcoders.com/weborb/php/remoteobjectandphp.htm

Jurgen

TCash21 wrote:


Hi all,
Is it possible to pass an object (i.e. Graph) to a PHP script in a
POST? and then store it in a database? Would I have to use
HTTPService, URLRequest? I've only passed xml and string data, I was
hoping I could send a whole object to be used later on in my
application, rather than having to parse out every node of the graph
into xml.

Thanks

 


Re: {Disarmed} Re: {Disarmed} [flexcoders] Possible to send object to POST data?

2007-05-23 Thread Jurgen Beck
AMFPHP allows you to do RPC with objects too. Last thing I've heard and 
seen is that AMFPHP is changing hands. You'd need to monitor traffic to 
see what the future holds for it.


WebORB is extremely solid and Mark and Harris at Midnight Coders are 
great in keeping up with adding new features to it.


Essentially it comes down to your preference. Check both of them out, 
but my pick would be WebORB. :-)


Jurgen

TCash21 wrote:


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


 You might want to check out WebORB for PHP at
 http://www.themidnightcoders.com. http://www.themidnightcoders.com.

 http://themidnightcoders.com/weborb/php/remoteobjectandphp.htm 
http://themidnightcoders.com/weborb/php/remoteobjectandphp.htm


 Jurgen

 TCash21 wrote:
 
  Hi all,
  Is it possible to pass an object (i.e. Graph) to a PHP script in a
  POST? and then store it in a database? Would I have to use
  HTTPService, URLRequest? I've only passed xml and string data, I was
  hoping I could send a whole object to be used later on in my
  application, rather than having to parse out every node of the graph
  into xml.
 
  Thanks
 
 


Thanks,
I'll try it. What about amfphp?

 


Re: {Disarmed} Re: {Disarmed} [flexcoders] Possible to send object to POST data?

2007-05-23 Thread Jurgen Beck
No, neither AMFPHP nor WebORB require FDS, well, at least not the server 
technology. You have to set up the Flex project as an FDS project type 
and you may need to make sure that the FDS SDK is installed on your 
development box. However, the rest is handled by the server components 
(AMFPHP/WebORB for PHP).


AMFPHP and WebORB each handle things a bit different. FDS goes beyond 
what either of them currently offer, with WebORB coming closer to the 
FDS feature set.


WebORB for .NET is a different story and you should check it out too. 
However, that would be a .NET implementation. Mark Piller at Midnight 
Coders would need to chime in here, but I believe there are plans to 
expand WebORB for PHP quite a bit. So definitely keep that in mind. If 
you look at the feature set of WebORB for .NET, especially for  the 
Enterprise version, there is a good chance that a number of them will 
end up in the PHP version too, at least that's what was stated by Mark 
in the past.


If you require the full feature set of FDS now, you'll need to consider 
it instead.


Jurgen



TCash21 wrote:


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


 AMFPHP allows you to do RPC with objects too. Last thing I've heard and
 seen is that AMFPHP is changing hands. You'd need to monitor traffic to
 see what the future holds for it.

 WebORB is extremely solid and Mark and Harris at Midnight Coders are
 great in keeping up with adding new features to it.

 Essentially it comes down to your preference. Check both of them out,
 but my pick would be WebORB. :-)

 Jurgen

 TCash21 wrote:
 
  --- In flexcoders@yahoogroups.com 
mailto:flexcoders%40yahoogroups.com

  mailto:flexcoders%40yahoogroups.com, Jurgen Beck jurgen@ wrote:
  
   You might want to check out WebORB for PHP at
   http://www.themidnightcoders.com. 
http://www.themidnightcoders.com.

http://www.themidnightcoders.com. http://www.themidnightcoders.com.
  
   http://themidnightcoders.com/weborb/php/remoteobjectandphp.htm 
http://themidnightcoders.com/weborb/php/remoteobjectandphp.htm
  http://themidnightcoders.com/weborb/php/remoteobjectandphp.htm 
http://themidnightcoders.com/weborb/php/remoteobjectandphp.htm

  
   Jurgen
  
   TCash21 wrote:
   
Hi all,
Is it possible to pass an object (i.e. Graph) to a PHP script in a
POST? and then store it in a database? Would I have to use
HTTPService, URLRequest? I've only passed xml and string data,
I was
hoping I could send a whole object to be used later on in my
application, rather than having to parse out every node of the
graph
into xml.
   
Thanks
   
   
  
 
  Thanks,
  I'll try it. What about amfphp?
 
 


Do both of these require Flex Data Services though?
I was hoping to get around using that.

 


Re: {Disarmed} [flexcoders] Data Paging a la Matt Chotin for Flex 2.1

2007-05-23 Thread Jurgen Beck

Hey Shaun,

You may want to check out the FlexBox components list. There are two 
components, one for a paged DataGrid, the other one for a paged 
ArrayCollection.


http://flexbox.mrinalwadhwa.com/

Jurgen

Shaun wrote:


I am getting ready to implement a report for a project that requires
the user to be able to sift through a maximum of 150,000 records from a
table (yes, we all know that in reality this is ridiculous, but we also
know that customers get what customers want).

I read through Matt Chotin's posts on large datasets and will likely go
down that path, but I'm in a time cruch and so the hope of saving some
time, I am curious as to whether anyone has already ported his samples
to 2.1 as they are from way back in 04.

Or, if anyone has a better option, I'm all ears.

Thanks,
Shaun

Matt's post:
http://weblogs.macromedia.com/mchotin/archives/2004/05/large_data_sets_2 
http://weblogs.macromedia.com/mchotin/archives/2004/05/large_data_sets_2

.cfm

 


Re: {Disarmed} Re: {Disarmed} [flexcoders] Data Paging a la Matt Chotin for Flex 2.1

2007-05-23 Thread Jurgen Beck
I hear ya! I haven't run across any other references, but that is not to 
say that someone hasn't done it.


Matt may be aware of an updated implementation. Matt?

Jurgen

Shaun wrote:


Jurgen,

Thanks for the tip.  I checked them out, but unfortunately, those 
implementations don't address my main issue: getting the data from the 
/server/ in a paged fashion.  They simply allow you to view an 
arraycollection in chunks, where Matt's goes back to the server as 
needed to get chunks of the data. 


With 150k records, I need the on demand paging.

Shaun


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

 Hey Shaun,

 You may want to check out the FlexBox components list. There are two
 components, one for a paged DataGrid, the other one for a paged
 ArrayCollection.

 http://flexbox.mrinalwadhwa.com/

 Jurgen

 Shaun wrote:
 
  I am getting ready to implement a report for a project that requires
  the user to be able to sift through a maximum of 150,000 records 
from a
  table (yes, we all know that in reality this is ridiculous, but we 
also

  know that customers get what customers want).
 
  I read through Matt Chotin's posts on large datasets and will 
likely go

  down that path, but I'm in a time cruch and so the hope of saving some
  time, I am curious as to whether anyone has already ported his samples
  to 2.1 as they are from way back in 04.
 
  Or, if anyone has a better option, I'm all ears.
 
  Thanks,
  Shaun
 
  Matt's post:
  
http://weblogs.macromedia.com/mchotin/archives/2004/05/large_data_sets_2
  
http://weblogs.macromedia.com/mchotin/archives/2004/05/large_data_sets_2

  .cfm
 
 


 


Re: {Disarmed} Re: {Disarmed} [flexcoders] Data Paging a la Matt Chotin for Flex 2.1

2007-05-23 Thread Jurgen Beck
WebORB for .NET Standard (free) was just updated to include AFM3 doing 
RPC. You may have an easier time implementing your paged solution with it.


May be worth taking a second look at it.

Jurgen

Shaun wrote:


Aww, what about us non-FDS guys, Matt? :-( Protecting the FDS
revenue stream I take it? Actually, I would love to use FDS, but
unfortunately this app requires a .NET backend and doesn't have the
budget for FDS or WebOrb anyway.

Oh well, time to start coding... :-)
Shaun

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


 FDS will do some of this work for you automatically, one reason why
we
 didn't write an updated version of the blog post :-)

 

 From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
[mailto:flexcoders@yahoogroups.com 
mailto:flexcoders%40yahoogroups.com] On

 Behalf Of Shaun
 Sent: Wednesday, May 23, 2007 2:32 PM
 To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 Subject: Re: {Disarmed} [flexcoders] Data Paging a la Matt Chotin
for
 Flex 2.1



 Jurgen,

 Thanks for the tip. I checked them out, but unfortunately, those
 implementations don't address my main issue: getting the data from
the
 server in a paged fashion. They simply allow you to view an
 arraycollection in chunks, where Matt's goes back to the server as
 needed to get chunks of the data.

 With 150k records, I need the on demand paging.

 Shaun


 --- In flexcoders@yahoogroups.com 
mailto:flexcoders%40yahoogroups.com, Jurgen Beck jurgen@ wrote:

 
  Hey Shaun,
 
  You may want to check out the FlexBox components list. There are
two
  components, one for a paged DataGrid, the other one for a paged
  ArrayCollection.
 
  http://flexbox.mrinalwadhwa.com/ http://flexbox.mrinalwadhwa.com/
 
  Jurgen
 
  Shaun wrote:
  
   I am getting ready to implement a report for a project that
requires
   the user to be able to sift through a maximum of 150,000 records
 from a
   table (yes, we all know that in reality this is ridiculous, but
we
 also
   know that customers get what customers want).
  
   I read through Matt Chotin's posts on large datasets and will
likely
 go
   down that path, but I'm in a time cruch and so the hope of
saving
 some
   time, I am curious as to whether anyone has already ported ! his
 samples
   to 2.1 as they are from way back in 04.
  
   Or, if anyone has a better option, I'm all ears.
  
   Thanks,
   Shaun
  
   Matt's post:
  

http://weblogs.macromedia.com/mchotin/archives/2004/05/large_data_sets 
http://weblogs.macromedia.com/mchotin/archives/2004/05/large_data_sets

_2

  

http://weblogs.macromedia.com/mchotin/archives/2004/05/large_data_set 
http://weblogs.macromedia.com/mchotin/archives/2004/05/large_data_set

s_
 2
   .cfm
  
  
 


 


Re: {Disarmed} RE: {Disarmed} [flexcoders] Data Paging a la Matt Chotin for Flex 2.1

2007-05-23 Thread Jurgen Beck
Additionally, if you're doing this in .NET you could let your class 
library handle the paging and simply just move the current recordset to 
Flex as a List Of objects collection. All you would need to do then is 
to tell your remote object where you are at in the list and if you are 
resorting any of the columns. You should be able to do any resorting and 
grabbing of sets of records completely on the .NET side.


Jurgen

Matt Chotin wrote:


The key to this is write an implementation of IList that throws 
ItemPendingErrors and then does the loading for you.  You then pass 
that IList to aListCollectionView and away you go.  Keep in mind that 
if you attempt to sort or filter the ListCollectionView will try to 
load all of your data, so you'll need to do your own work to have that 
passed through (which may mean subclassing LCV or writing your own 
impl of ICollectionView if this is important to you).
 
Matt



*From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
*On Behalf Of *Shaun

*Sent:* Wednesday, May 23, 2007 2:58 PM
*To:* flexcoders@yahoogroups.com
*Subject:* Re: {Disarmed} [flexcoders] Data Paging a la Matt Chotin 
for Flex 2.1


Aww, what about us non-FDS guys, Matt? :-( Protecting the FDS
revenue stream I take it? Actually, I would love to use FDS, but
unfortunately this app requires a .NET backend and doesn't have the
budget for FDS or WebOrb anyway.

Oh well, time to start coding... :-)
Shaun

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


 FDS will do some of this work for you automatically, one reason why
we
 didn't write an updated version of the blog post :-)

 

 From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
[mailto:flexcoders@yahoogroups.com 
mailto:flexcoders%40yahoogroups.com] On

 Behalf Of Shaun
 Sent: Wednesday, May 23, 2007 2:32 PM
 To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 Subject: Re: {Disarmed} [flexcoders] Data Paging a la Matt Chotin
for
 Flex 2.1



 Jurgen,

 Thanks for the tip. I checked them out, but unfortunately, those
 implementations don't address my main issue: getting the data from
the
 server in a paged fashion. They simply allow you to view an
 arraycollection in chunks, where Matt's goes back to the server as
 needed to get chunks of the data.

 With 150k records, I need the on demand paging.

 Shaun


 --- In flexcoders@yahoogroups.com 
mailto:flexcoders%40yahoogroups.com, Jurgen Beck jurgen@ wrote:

 
  Hey Shaun,
 
  You may want to check out the FlexBox components list. There are
two
  components, one for a paged DataGrid, the other one for a paged
  ArrayCollection.
 
  http://flexbox.mrinalwadhwa.com/ http://flexbox.mrinalwadhwa.com/
 
  Jurgen
 
  Shaun wrote:
  
   I am getting ready to implement a report for a project that
requires
   the user to be able to sift through a maximum of 150,000 records
 from a
   table (yes, we all know that in reality this is ridiculous, but
we
 also
   know that customers get what customers want).
  
   I read through Matt Chotin's posts on large datasets and will
likely
 go
   down that path, but I'm in a time cruch and so the hope of
saving
 some
   time, I am curious as to whether anyone has already ported ! his
 samples
   to 2.1 as they are from way back in 04.
  
   Or, if anyone has a better option, I'm all ears.
  
   Thanks,
   Shaun
  
   Matt's post:
  

http://weblogs.macromedia.com/mchotin/archives/2004/05/large_data_sets 
http://weblogs.macromedia.com/mchotin/archives/2004/05/large_data_sets

_2

  

http://weblogs.macromedia.com/mchotin/archives/2004/05/large_data_set 
http://weblogs.macromedia.com/mchotin/archives/2004/05/large_data_set

s_
 2
   .cfm
  
  
 


 


Re: {Disarmed} Re: {Disarmed} RE: {Disarmed} [flexcoders] Data Paging a la Matt Chotin for Flex

2007-05-23 Thread Jurgen Beck
Flex in this case strictly acts as a pure presentation layer. In other 
words, the data that is viewable in Flex is prepared and provided by the 
.NET end. More specifically, it is a remote object with a set number of 
records in the form of a list. Without the more powerful data mangement 
features of FDS or WebORB .NET Enterprise, you'd have to handle a number 
of things manually.


You'd have several facts to consider, for example, whether you allow the 
user to sort or not. If that's the case you'd have to make sure that you 
are keeping track of it on the server side too (which column you are 
sorting on and from what record you are starting the sort, etc.)


Other factors include the data source you are dealing with. .NET has 
some nifty ways of working with paged datasets, so the only thing that 
you really need to concentrate on is the data pages you are feeding back 
to the presentation layer.


No need to cache. For most part you are dealing with a disconnected 
recordset of a limited set of records anyhow. It wouldn't make sense to 
keep the 150k+ records in memory.


Instead what you would be doing is passing record pointers back and 
forth between Flex and the remote object (class library object) so that 
the class method knows where to start to get the next set of records.


It sounds way more complicated explaining it all. Again, concentrate on 
using Flex purely to manage the limited number of objects (records) that 
were passed on the last call and then pass the record id or whatever you 
want to identify the starting point back to the class method to get you 
the next set.


If you're doing this with WebORB it actually gets fairly easy to deal 
with. Here is what your remote object declaration looks like in Flex:


   private var service:RemoteObject = new 
RemoteObject(GenericDestination);


   public function getAlbums():void {
   service.source = Services.dao.Album.AlbumDAO;
   service.addEventListener(FaultEvent.FAULT,faultHandler);
   
service.GetAlbums.addEventListener(ResultEvent.RESULT,getAlbumsHandler);

   service.GetAlbums(startID, numberOfRecordsToReturn);
   }   


Your DTO class in Flex would have a declaration such as the following:

   [Bindable]
   [RemoteClass(alias=Services.dao.Album.Album)]
   public class AlbumInfo
   {
   static private var _instance:AlbumInfo;

   public var ID:Number;
   public var albumName:String;
   public var artFullPath:String;
   public var artThumbPath:String;
   public var yearReleased:String;
   public var itemName:String;
   public var description:String;
   public var storeDescription:String;
   ...
   }

That's not the complete class, but you get the picture. The key is the 
mapping of the remote class through the alias.


Here is the method on the server in your class library:

Namespace dao.Album

   Public Class AlbumDAO

   Private ConnectString As String
   Private SqlConnection As SqlConnection

   Public Function GetAlbums(byval startID as Integer, byval 
numberOfRecordsToReturn as Integer) As List(Of Album)

   Dim myDT As New DataTable
   Dim myObjects As New List(Of Album)

' Build the list of Album objects based on what is returned 
from the data store.

...

Again, it's not a complete class, but shows you what we are returning. 
We return a list of Album objects, which Flex will then map properly to 
the DTO class object.


Inside the GetAlbums function on the server you'd take the startID and 
use it to get the next set of records, along with how many records to 
return.


Hope this makes sense. It's not the only way to approach the issue and 
you'd still have to work around some other issues such as getting the 
total number of records in the table so you can set your paged navigation.


All Flex would be doing with this scenario is take the list of objects 
(records) that are returned and put them into an ArrayCollection, which 
you then can use as a DataProvider for a DataGrid or other component.


   public function getAlbumsHandler(event:ResultEvent):void {
   if (event.result.length  0) {
   albums = new ArrayCollection(event.result as Array);
   albums.filterFunction = albumsFilterFunc;
   albums.refresh();
   }
   }

The above even includes a filter function, if you need it.

Jurgen


barry.beattie wrote:


Jurgen

please forgive me for asking, could you clarify what's going on at the
.NET end and what the SWF would need to do to get the next page of data?

would the 150k+ records be held in a dataset (or whatever) in memory
(cache, session, etc) on the server? (flex would need to send a call
back for next N records to cursor thru them, I assume). A handle to
the cache would need to be sent too?

 


Re: {Disarmed} RE: [flexcoders] Re: Am I using the right technology?

2007-05-21 Thread Jurgen Beck

Hi Mark,

Seeing that you want to use ASP.NET, WebORB would be the way to go. It 
is pricey and Midnightcoders would make a killing if they would reduce 
the pricing for it as more firms would jump on the boat.


I've been working with WebORB and must say that the tools that come with 
it beat everything else out there in terms of rapid application 
development. You get a fully implemented code generation module with it, 
which is irreplaceable.


All that you really need to concentrate on is writing your class 
libraries in .NET and create the services and DTO objects on the Flex 
side and you're done. Can't get easier than that.


Jurgen


Mark Ingram wrote:


Hi Barrie, thanks for the response.

 

In terms of collaboration, anything will do. I tried a great example 
using Flash Media Server 2, which was a chat client. Each client was 
informed when a new client joined or typed a message. That's exactly 
what I was looking for, as we created one the other week that was 
based around polling. It worked, but it wasn't elegant.


 

The price tag on FMS seems steep too (not compared to FDS!). $4000 for 
150 concurrent users? Or more users if you throttle their bandwidth.


 

 

The ideal solution for me would allow data-push and be able to 
communicate with ASP.NET. I have looked at WebOrb, but again, $10,000 
per CPU is a little high.


 


So here are the options as I see it:

 


Flex Data Services (LiveCycle Data Services): $20,000 per CPU

Midnight Coders Data Services: $10,000 per CPU

Flash Media Server: $4,000 per 150 users (unthrottled)

Polling WebServices: Free (plenty of development required though)

 

Another down side of FMS is that you can't develop in Flex Builder? 
And from what I've seen it doesn't use ActionScript 3?


 

I feel awfully confused about all these similar products! Based on my 
requirements, what would be the best option (see above)?


 


Thanks,

 

 




*From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
*On Behalf Of *barry.beattie

*Sent:* 21 May 2007 15:22
*To:* flexcoders@yahoogroups.com
*Subject:* [flexcoders] Re: Am I using the right technology?

 




Hang on a sec...

in giving Mark an answer, he's been landed with more jargon.

Mark, I'm nowhere near the expert that Tom or others here are on this
subject ...

... and there are some good blog posts around (and the Adobe site
itself) with decent detail on all of it ...

but... I work at a university and they're forever going on about
collaboration, whether it's research partners, academics or student
teams. I'm hunting for a project to put this into practice...

(in a nutshell) both remoting and webservices follow the typical
request/response. so any sync'ing of data needs polling so the clients
can find out if server has new changes.

but FlexDataServices (or LiveCycle DS now-a-days) has a handle back to
each client from the server so it can push events/notifications
telling the clients that the server's data has changed.

this gives a pretty powerful hub-type configuration where one client
commits updates on the server which can be sent back to all the other
clients in a heartbeat.

however, this is NOT peer-to-peer collaboration. the server is
definitely in the middle of it all, receiving and broadcasting to
subscribers. Which is OK if the data/documents/whatever is to be
persisted and managed on the server. Keep in mind, that sort of
technology isn't cheap - not compared to webservices...

I'm no expert on all of this and I've got my own issues trying to work
out how flex can do true peer-to-peer collaboration (no FDS). I'm also
unsure what the upgrade path will be with our FlashMediaServers (FMS)
while I wait for ColdFusion8 (and it's reported LCDS and FMS integration).

but I do hope that's helped somewhat. Others can chime in with much
better replies. this is just something quick to help lift the fog.

what sort of collaboration do you need to do?

 


Re: {Disarmed} RE: [flexcoders] Re: Am I using the right technology?

2007-05-21 Thread Jurgen Beck
I'm doing this right now with the Standard version of WebORB. I've 
written my class library (wrapped in a DLL) that connects to the database.


If you need full data management, you need to be looking at the 
Professional version at minimum.


Check out the examples on the WebORB site. Go to:

http://www.themidnightcoders.net/flexexamples/weborbconsole.html

This is the management console you get with WebORB. Select the Services 
tab and look at the WebOrb Examples. Those are the services that have 
been wrapped into class libraries. You can test drive them and see the 
code you would need to implement them in Flex.


Jurgen

Mark Ingram wrote:


I should also state that the reason I want to use ASP.NET Web Services 
or .NET Components is because I want to access a database (the result 
of all collaborative work will be stored there).


 


Thanks,

 


Mark

 

 




*From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
*On Behalf Of *Mark Ingram

*Sent:* 21 May 2007 16:24
*To:* flexcoders@yahoogroups.com
*Subject:* RE: [flexcoders] Re: Am I using the right technology?

 


Hi Barrie, thanks for the response.

 

In terms of collaboration, anything will do. I tried a great example 
using Flash Media Server 2, which was a chat client. Each client was 
informed when a new client joined or typed a message. That's exactly 
what I was looking for, as we created one the other week that was 
based around polling. It worked, but it wasn't elegant.


 

The price tag on FMS seems steep too (not compared to FDS!). $4000 for 
150 concurrent users? Or more users if you throttle their bandwidth.


 

 

The ideal solution for me would allow data-push and be able to 
communicate with ASP.NET. I have looked at WebOrb, but again, $10,000 
per CPU is a little high.


 


So here are the options as I see it:

 


Flex Data Services (LiveCycle Data Services): $20,000 per CPU

Midnight Coders Data Services: $10,000 per CPU

Flash Media Server: $4,000 per 150 users (unthrottled)

Polling WebServices: Free (plenty of development required though)

 

Another down side of FMS is that you can't develop in Flex Builder? 
And from what I've seen it doesn't use ActionScript 3?


 

I feel awfully confused about all these similar products! Based on my 
requirements, what would be the best option (see above)?


 


Thanks,

 

 




*From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
*On Behalf Of *barry.beattie

*Sent:* 21 May 2007 15:22
*To:* flexcoders@yahoogroups.com
*Subject:* [flexcoders] Re: Am I using the right technology?

 




Hang on a sec...

in giving Mark an answer, he's been landed with more jargon.

Mark, I'm nowhere near the expert that Tom or others here are on this
subject ...

... and there are some good blog posts around (and the Adobe site
itself) with decent detail on all of it ...

but... I work at a university and they're forever going on about
collaboration, whether it's research partners, academics or student
teams. I'm hunting for a project to put this into practice...

(in a nutshell) both remoting and webservices follow the typical
request/response. so any sync'ing of data needs polling so the clients
can find out if server has new changes.

but FlexDataServices (or LiveCycle DS now-a-days) has a handle back to
each client from the server so it can push events/notifications
telling the clients that the server's data has changed.

this gives a pretty powerful hub-type configuration where one client
commits updates on the server which can be sent back to all the other
clients in a heartbeat.

however, this is NOT peer-to-peer collaboration. the server is
definitely in the middle of it all, receiving and broadcasting to
subscribers. Which is OK if the data/documents/whatever is to be
persisted and managed on the server. Keep in mind, that sort of
technology isn't cheap - not compared to webservices...

I'm no expert on all of this and I've got my own issues trying to work
out how flex can do true peer-to-peer collaboration (no FDS). I'm also
unsure what the upgrade path will be with our FlashMediaServers (FMS)
while I wait for ColdFusion8 (and it's reported LCDS and FMS integration).

but I do hope that's helped somewhat. Others can chime in with much
better replies. this is just something quick to help lift the fog.

what sort of collaboration do you need to do?

 


Re: {Disarmed} RE: [flexcoders] Re: Am I using the right technology?

2007-05-21 Thread Jurgen Beck
I'll let Mark Piller chime in on the data management aspect. They've 
implemented a FDS equivalent that is very nifty.


On the workflow:

To pull data from a data store, the flow goes like this:

Flex - WebORB - .NET Library - Data Store - .NET Library - WebORB 
- Flex


WebORB serializes the data/object and maps the remote class so that by 
the time the data arrives in Flex you have immediate access to the 
object elements. For example, if I want to return the contents of a data 
table that I pulled in my .NET class, I return it as a List Of object. 
WebORB serializes the data/objects in the list so that I can build an 
ArrayCollection with the results in Flex.


Here is what it looks like practically:

I have a service manager class in Flex that has a public method:

   public function getShippingRateTable():void {
   serviceStore.source = 
Services.dao.ShippingRate.ShippingRateDAO;

   serviceStore.addEventListener(FaultEvent.FAULT, faultHandler);
   
serviceStore.GetShippingRates.addEventListener(ResultEvent.RESULT, 
getShippingRatesHandler);   
   serviceStore.GetShippingRates();   
   }


serviceStore is defined as a remote object:

   private var serviceStore:RemoteObject = new 
RemoteObject(GenericDestination);


The result handler looks as follows:

   private function getShippingRatesHandler(event:ResultEvent):void {
   if (event.result.length  0) {
   shippingRateTable = new ArrayCollection(event.result as 
Array);

   }
   }

My service manager class is defined as a singleton so that my returned 
data is immediately available throughout the application.


The mapped Flex class for the ArrayCollection items is:

   import mx.collections.ArrayCollection;
  
   [Bindable]

   [RemoteClass(alias=Services.dao.ShippingRate.ShippingRate)]
   public class ShippingRateVO
   {
  
   static private var _instance:ShippingRateVO;

   public var ID:int;
   public var pounds:Number;
   public var rate:Number;
  
   public function ShippingRateVO() {};
  
   }


On the server side, my .NET class ShippingRateDAO has a public method:

   Public Function GetShippingRates() As List(Of ShippingRate)
   ...
   Return rates

   End Function

In it I am connecting to my data store, pull the data from a data table 
and compile my list of objects into a List(Of ShippingRate), which I 
then return.


That's all there is to it! WebORB does the rest.

About the examples:

I just checked on them and they were working fine. You may want to get 
with Mark Piller if you continue to run into issues.


Mark also has a Yahoo newsgroup for WebORB that you can post questions to.

Jurgen


Mark Ingram wrote:


What do you mean by full data management?

 

I can't seem to get any of the service examples to work, I just get a 
dialog saying access denied and a load of other text.


 


So does your setup look something similar to:

 


Flex - WebOrb - .NET Library

 


?

 


Thanks,

Mark

 

 




*From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
*On Behalf Of *Jurgen Beck

*Sent:* 21 May 2007 16:42
*To:* flexcoders@yahoogroups.com
*Subject:* Re: {Disarmed} RE: [flexcoders] Re: Am I using the right 
technology?


 

I'm doing this right now with the Standard version of WebORB. I've 
written my class library (wrapped in a DLL) that connects to the 
database.


If you need full data management, you need to be looking at the 
Professional version at minimum.


Check out the examples on the WebORB site. Go to:

http://www.themidnightcoders.net/flexexamples/weborbconsole.html 
http://www.themidnightcoders.net/flexexamples/weborbconsole.html


This is the management console you get with WebORB. Select the 
Services tab and look at the WebOrb Examples. Those are the services 
that have been wrapped into class libraries. You can test drive them 
and see the code you would need to implement them in Flex.


Jurgen

Mark Ingram wrote:

I should also state that the reason I want to use ASP.NET Web 
Services or .NET Components is because I want to access a database 
(the result of all collaborative work will be stored there).


 


Thanks,

 


Mark

 

 




*From:* flexcoders@yahoogroups.com 
[mailto:[EMAIL PROTECTED] *On Behalf Of *Mark Ingram

*Sent:* 21 May 2007 16:24
*To:* flexcoders@yahoogroups.com
*Subject:* RE: [flexcoders] Re: Am I using the right technology?

 


Hi Barrie, thanks for the response.

 

In terms of collaboration, anything will do. I tried a great example 
using Flash Media Server 2, which was a chat client. Each client was 
informed when a new client joined or typed a message. That's exactly 
what I was looking for, as we created one the other week that was 
based around polling. It worked, but it wasn't elegant

[flexcoders] ListCollectionView.addItemAt Bug?

2007-05-21 Thread Jurgen Beck
It seems that there is a problem with the ListCollectionView class when 
using it with an ArrayCollection. Using the addItemAt method produces an 
index out of bounds error when an item is added with an index that is 
beyond the length of the collection.

However, the Flex Reference states that:

If the list is shorter than the specified index, it will grow to 
accommodate the new item.

Is this a confirmed bug, or am I overlooking something?

Here is some test code to check it out:

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

mx:Script
![CDATA[
import mx.collections.ArrayCollection;
   
private var collection:ArrayCollection = new ArrayCollection();
   
private function initApp():void {
   
var newObject:Object = new Object();
newObject.test1 = test1;
newObject.test2 = test2;
   
collection.addItem(newObject);
   
newObject = new Object();
newObject.test1 = test3;
newObject.test2 = test4;
   
collection.addItemAt(newObject, 3);
   
}
   
]]
/mx:Script
   
/mx:Application

Anyone run into this too?

Jurgen



Re: {Disarmed} [flexcoders] ListCollectionView.addItemAt Bug?

2007-05-21 Thread Jurgen Beck
Well, it looks like either the documentation is wrong, or the code. The 
ListCollectionView class has the following method defined:


   public function addItemAt(item:Object, index:int):void
   {
   if (index  0 || !list || index  length)
   throw new 
RangeError(StringUtil.substitute(resourceOutOfBounds, index));


   var listIndex:int = index;
   //if we're sorted addItemAt is meaningless, just add to the end
   if (localIndex  sort)
   {
   listIndex = list.length;
   }
   list.addItemAt(item, listIndex);
   }

Makes it very clear that the list isn't grown when the index exceeds the 
length of the list. :-)


Anyone concur? If so, I'll submit a report to Adobe.

Jurgen

Jurgen Beck wrote:


It seems that there is a problem with the ListCollectionView class when
using it with an ArrayCollection. Using the addItemAt method produces an
index out of bounds error when an item is added with an index that is
beyond the length of the collection.

However, the Flex Reference states that:

If the list is shorter than the specified index, it will grow to
accommodate the new item.

Is this a confirmed bug, or am I overlooking something?

Here is some test code to check it out:

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

creationComplete=initApp()
layout=vertical

mx:Script
![CDATA[
import mx.collections.ArrayCollection;

private var collection:ArrayCollection = new ArrayCollection();

private function initApp():void {

var newObject:Object = new Object();
newObject.test1 = test1;
newObject.test2 = test2;

collection.addItem(newObject);

newObject = new Object();
newObject.test1 = test3;
newObject.test2 = test4;

collection.addItemAt(newObject, 3);

}

]]
/mx:Script

/mx:Application

Anyone run into this too?

Jurgen

 


Re: {Disarmed} RE: {Disarmed} [flexcoders] ListCollectionView.addItemAt Bug?

2007-05-21 Thread Jurgen Beck

Hey Matt,

The Flex reference will definitely need to be updated then. Should I 
create a report, or are you passing it along to the right person/team?


Jurgen


Matt Chotin wrote:


The docs are wrong if that's what it says.  Only addItemAt(length()) 
will allow it to grow.



*From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
*On Behalf Of *Jurgen Beck

*Sent:* Monday, May 21, 2007 1:38 PM
*To:* flexcoders@yahoogroups.com
*Subject:* Re: {Disarmed} [flexcoders] ListCollectionView.addItemAt Bug?

Well, it looks like either the documentation is wrong, or the code. 
The ListCollectionView class has the following method defined:


public function addItemAt(item:Object, index:int):void
{
if (index  0 || !list || index  length)
throw new 
RangeError(StringUtil.substitute(resourceOutOfBounds, index));


var listIndex:int = index;
//if we're sorted addItemAt is meaningless, just add to the end
if (localIndex  sort)
{
listIndex = list.length;
}
list.addItemAt(item, listIndex);
}

Makes it very clear that the list isn't grown when the index exceeds 
the length of the list. :-)


Anyone concur? If so, I'll submit a report to Adobe.

Jurgen

Jurgen Beck wrote:


It seems that there is a problem with the ListCollectionView class when
using it with an ArrayCollection. Using the addItemAt method produces an
index out of bounds error when an item is added with an index that is
beyond the length of the collection.

However, the Flex Reference states that:

If the list is shorter than the specified index, it will grow to
accommodate the new item.

Is this a confirmed bug, or am I overlooking something?

Here is some test code to check it out:

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

creationComplete=initApp()
layout=vertical

mx:Script
![CDATA[
import mx.collections.ArrayCollection;

private var collection:ArrayCollection = new ArrayCollection();

private function initApp():void {

var newObject:Object = new Object();
newObject.test1 = test1;
newObject.test2 = test2;

collection.addItem(newObject);

newObject = new Object();
newObject.test1 = test3;
newObject.test2 = test4;

collection.addItemAt(newObject, 3);

}

]]
/mx:Script

/mx:Application

Anyone run into this too?

Jurgen

 


Re: {Disarmed} Re: {Disarmed} Re: [flexcoders] Flex on Mac

2007-05-17 Thread Jurgen Beck

Hey Paul,

Here is what I experience (again, this is with Flex Builder, not Eclipse):

When I drag one of the Flex Builder tabs for a specific window to the 
second monitor, I see the cursor change to a square box. When I release 
the mouse button on the second window, the cursor switches back to 
normal and nothing happens. The tabbed window stays on the first monitor.


Would you care to share how you get those windows to show up on the 
second monitor?


Thanks,

Jurgen

Paul J DeCoursey wrote:


What are you talking about... I have a second monitor hooked up to my
MacBook Pro right now, and my Mac Pro has 3 monitors. I've had no issues.

Paul

fuad_kamal wrote:
 you can't (multiple monitors). It's an issue w/Eclipse on Mac.
 Solution: cinema display :P

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


 Same here. I actually switched from Windows XP Professional running
 stand-alone Flex Builder to a Mac Pro and MacBook Pro. Works great. In
 fact, I seem to have less memory issues with Flex Builder on the Mac
 than I had with running it on Windows XP.

 The only thing I wish it would do on the Mac is allowing me to use two
 monitors. On the Windows side this is no problem. Can't seem to figure
 out how to do that on the Mac.

 Jurgen


 


[flexcoders] Fade Effect on Labels

2007-05-17 Thread Jurgen Beck
It seems that fade effects (fade in or fade out) do not fully work on 
labels, at least not the way I have implemented the fading.

I have created MXML components containing labels that use embedded fonts 
configured through a style sheet. The fonts look fine, except that 
during a fade transition on the whole component, the labels maintain 
their visibility until the fade transition is fully done and then just 
simply disappear.

The same font used in a TextArea component within the custom MXML 
component works as expected, so it has to be something related to labels 
controls.

What would be the reason for that behavior and how can I get around it?

Thanks,

Jurgen


Re: {Disarmed} [flexcoders] Re: Fade Effect on Labels

2007-05-17 Thread Jurgen Beck

Hi Brian,

Well, that may be the reason indeed. That's where Flex is getting a bit 
funky. I've embedded the fonts into the application, but for some reason 
Flex is not taking them.


I've had mixed results embedding system/native fonts in Flex. Some of 
them take fine, others won't.


I'll dig a bit deeper and see what's going on with the fonts that won't 
show up properly...


Thanks for the hint!

Jurgen

Brian Morearty wrote:


Hi Jurgen,

 It seems that fade effects (fade in or fade out) do not fully work on
 labels, at least not the way I have implemented the fading.

That's because you're using device fonts instead of embedded fonts. If 
you use native fonts, certain effects like fade and rotate do not work.


This help topic gives a brief explanation:

http://livedocs.adobe.com/flex/2/docs/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Partsfile=0736.html 
http://livedocs.adobe.com/flex/2/docs/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Partsfile=0736.html


- Brian Morearty
  Intuit

 


[flexcoders] Strange Error with Embed Statement

2007-05-17 Thread Jurgen Beck
I've been working on this big project for the last 5 weeks and all of a 
sudden today started getting errors on all my Embed statements in my 
style sheet.

The following lines are an example of what Flex Builder now thinks are 
invalid statements:

.trashButton
{
up-skin:Embed(source=/assets/ApplicationResources.swf#TrashCanClosed);
over-skin:Embed(source=/assets/ApplicationResources.swf#TrashCan);

disabled-skin:Embed(source=/assets/ApplicationResources.swf#TrashCanClosed);

down-skin:Embed(source=/assets/ApplicationResources.swf#TrashCan);
   
}

The resources are compiled into the application just fine, as they show 
up in the application. However, the IDE sees these lines as errors and 
will report them with:

Invalid Embed directive in stylesheet - can't resolve source 
'Embed(source = /assets/ApplicationResources.swf#TrashCan)

I created a new test application with the same statement in it and 
everything works as it should.

Cleaning the project won't resolve the issue.

Anyone run into this?

Thanks,

Jurgen


Re: {Disarmed} Re: [flexcoders] Flex on Mac

2007-05-11 Thread Jurgen Beck
Same here. I actually switched from Windows XP Professional running 
stand-alone Flex Builder to a Mac Pro and MacBook Pro. Works great. In 
fact, I seem to have less memory issues with Flex Builder on the Mac 
than I had with running it on Windows XP.


The only thing I wish it would do on the Mac is allowing me to use two 
monitors. On the Windows side this is no problem. Can't seem to figure 
out how to do that on the Mac.


Jurgen

Mark McCray wrote:


runs just fine for me. intel mac here.

I use flex via plugin to eclipse, because i use other langs like PHP 
and Java.

Mark

On May 11, 2007, at 1:06 PM, Arleston Lueders wrote:


Hello everybody!

I'm thinking in buy a MacBook. Does anyone have a Mac here? What do 
you think about it?

And the Flex will run normal on Mac, right?

Thanks,
Arleston



 


Re: {Disarmed} [flexcoders] Flex SWF running slow

2007-05-11 Thread Jurgen Beck

Came up really snappy for me. No performance issues at all.

You may need to check and see what else is going on with your Flash 
player and the browser you are testing this with. If you are running 
this on Windows, check with the Task Manager to see what processes are 
consuming a lot of CPU cycles. Running this on the Mac you can do the 
same with the Activity Monitor.


This may start giving you a clue as to what may be happening on your system.

Jurgen

alex steel wrote:


I have a little problem with Flex
compiled file is running slow, freezing computer for about 2 sec

basiclly I use amfphp2 to get information for dynamiclly creating Lists
you can see it at
http://www.pleasures.co.yu/_gvozden/RHS/RHS.html 
http://www.pleasures.co.yu/_gvozden/RHS/RHS.html


and code which is doing that is at
http://www.pleasures.co.yu/_gvozden/RHS/RHS_code.txt 
http://www.pleasures.co.yu/_gvozden/RHS/RHS_code.txt


as far as I see it there is nothing tricky there except if creating
300 UI items freeze it, and it is obviously

being that I am new to Flex but expert for Flash I find this really
weird and bad

how can I resolve this issue (without making it static)?

AMFPHP 2 browser returns query for about 2 sec, one's that clock is
showing , then there is freeze :(

thnx
Alex

 


Re: {Disarmed} [flexcoders] Flex SWF running slow

2007-05-11 Thread Jurgen Beck

Correction! On second and subsequent loads I could see what you exeperience.

Here's what I first saw:

When the application first loaded, I saw all the UI components on the 
form. Didn't take long to load the application.


I then started playing around by clicking on checkboxes and noticed that 
you have the  wait cursor enabled, indicating that you are communicating 
with AMFPHP. From that point on subsequent application loads (i.e. page 
refresh) would cause the delay you indicated.


I haven't looked at your code, but I would start checking into what you 
are doing when the application communicates with the server. Are you 
loading any large datasets?


Using AMFPHP you should be able to use the service browser to check how 
your classes return data.


All this is of course stab in the dark, but I thought it was a bit 
strange that none of the delay issues started happening until after I 
had checked one of the checkboxes.


Jurgen

alex steel wrote:


I have a little problem with Flex
compiled file is running slow, freezing computer for about 2 sec

basiclly I use amfphp2 to get information for dynamiclly creating Lists
you can see it at
http://www.pleasures.co.yu/_gvozden/RHS/RHS.html 
http://www.pleasures.co.yu/_gvozden/RHS/RHS.html


and code which is doing that is at
http://www.pleasures.co.yu/_gvozden/RHS/RHS_code.txt 
http://www.pleasures.co.yu/_gvozden/RHS/RHS_code.txt


as far as I see it there is nothing tricky there except if creating
300 UI items freeze it, and it is obviously

being that I am new to Flex but expert for Flash I find this really
weird and bad

how can I resolve this issue (without making it static)?

AMFPHP 2 browser returns query for about 2 sec, one's that clock is
showing , then there is freeze :(

thnx
Alex

 


Re: {Disarmed} Re: {Disarmed} [flexcoders] Flex SWF running slow

2007-05-11 Thread Jurgen Beck
Frame rate is still very much part of Flex, which by default uses 24 
frames per second. You can change that during compile time.


Here is a good write-up on frame rates: 
http://ajax.sys-con.com/read/303778.htm


Question: Are the 300 plus UI elements the checkboxes, labels, etc.that 
you have in the application?


They seem to be showing up almost right away, at least for the first 
tab. If you are writing your application code logically you can employ a 
lazy loading scheme whereby data is not loaded (including data binding) 
until it is really needed. Again, I haven't looked at your code, so I'm 
not sure how much data you are pulling in.


One thing you could do is temporarily comment out any code that actually 
loads data and then see how your application behaves. If this eliminates 
the delay, you can start enabling the data loading mechanism one by one 
to see where the delay is introduced.


Jurgen

alex steel wrote:


thank for looking

It happens to me without any interaction
I know for service browser and everything is ok,
I still think it have problem with adding 300 ui elements

with my flash experience I would break it in smaller chunks, for
example 40 frames per second, break it in 8 per frame, it would slide
through it

how can I do such a thing in Flex ?

if that isn't problem I would still have good ad to my Flex experience
and future issues

I didn't looked about how Flex execute larger chunks of code
does it try to do it in one frame, or it's truly frame=free ?

 


[flexcoders] Convert Non-server Flex Project to Server Project

2007-05-07 Thread Jurgen Beck
Is there a way to convert a non-server Flex project to a server project? 
When setting up a Flex project I can of course select the type. However, 
I need to convert a Basic Flex Project to a Flex Data Services project. 
Seems like the in the Flex properties for the project the Flex Server 
items are disabled when not creating the project as a FDS project from 
the start.

I could import all the files to a newly created FDS project, but that 
seems a bit unintuitive.


Thanks,

Jurgen


Re: {Disarmed} RE: [flexcoders] Convert Non-server Flex Project to Server Project

2007-05-07 Thread Jurgen Beck
Yeah, thought about that too. However, running this in Flex Builder on 
the Mac, it seems that those features are disabled on the context menu, 
even on another FDS project I have going.


Brian Holmes wrote:


Don't know if it works for a basic flex project, but I know that with 
other types of projects I've done a right click on the project and 
select Apply Flex Nature


 




*From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] 
*On Behalf Of *Jurgen Beck

*Sent:* Monday, May 07, 2007 3:25 PM
*To:* flexcoders@yahoogroups.com
*Subject:* [flexcoders] Convert Non-server Flex Project to Server Project

 


Is there a way to convert a non-server Flex project to a server project?
When setting up a Flex project I can of course select the type. However,
I need to convert a Basic Flex Project to a Flex Data Services project.
Seems like the in the Flex properties for the project the Flex Server
items are disabled when not creating the project as a FDS project from
the start.

I could import all the files to a newly created FDS project, but that
seems a bit unintuitive.

Thanks,

Jurgen


***
The information in this e-mail is confidential and intended solely for 
the individual or entity to whom it is addressed. If you have received 
this e-mail in error please notify the sender by return e-mail delete 
this e-mail and refrain from any disclosure or action based on the 
information.

***
 


[flexcoders] Setup Issues with Release 3.1.0.1

2007-05-02 Thread Jurgen Beck
I may have missed something setting up the latest release on a test 
server, but I am getting strange errors:

Going t the Management console I get an immediate Security error dialog 
that states that 'Send failed'. A follow-up error pop-up states the 
following:

faultCode:Client.Error.MessageSend faultString:'Send failed' 
faultDetail:'Channel.Connect.Failed error NetConnection.Call.Failed: 
HTTP: Status 500: url: 'http://localhost/weborb30/console/weborb.aspx''

I get Send Failed errors all over the place, including trying to run the 
examples.

Again, this is on a Win 2003 test server I set up in a virtual machine, 
so it's perfectly reasonable that I missed something setting up IIS.

Any suggestions?

Thanks,

Jurgen


Re: {Disarmed} [flexcoders] metadata tags and events

2007-05-01 Thread Jurgen Beck
You can find some of them explained here, but that is not the complete 
list either:


http://livedocs.adobe.com/flex/201/html/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Book_Partsfile=metadata_141_01.html

Jurgen

Kenneth Sutherland wrote:


Does anyone have information on the various metadata tags that can be 
used in flex. I've been going through some of the source files to find 
out a way of getting my custom component to tell a model to update itself.


Some of the tags I've seen that I don't know what they do are

[DataBindingInfo]

[DefaultBindingProperty]

[DefaultTriggerEvent]

I've seen others but I won't to list everything here.

 

I've searched Livedocs and I can't find somewhere where all the tags 
with explanations are listed.


 

Also if someone knows about models being updated can you advise on the 
below problem


 


If my model is

mx:Model id=requiredFields

theForm

all

name { 
name.text } /name


birth  { 
DoB.selectedDate }/birth


/all

/theForm

/mx:Model

myValidator:FormValidator id=formValidator  
source={requiredFields} property=all/


 

When I call the validator the information it gets from the 
model is the text from the text input which is updated everytime the 
user changes the said text input, but the date comes from a custom 
date entry component and the model doesn't get the latest date from 
the component. It would seem like the binding isn't working or my 
custom component isn't firing of the required events for the model to 
update itself when the user changes the date.


 


I've tried getting my custom component to fire of the following events

[Event(name=change, type=flash.events.Event)]

[Event(name=valueCommit, type=mx.events.FlexEvent)]

As well as making the getter function for selectedDate [Bindable], but 
the model still doesn't pick up on any changes after the component has 
been initialised.


 


Cheers for any info.

 


*Kenneth.*

 


Re: {Disarmed} Re: {Disarmed} [flexcoders] metadata tags and events

2007-05-01 Thread Jurgen Beck

That's a great list, Dan!

Can someone from Adobe maybe chime in and help Dan with completing the list?

Jurgen

Daniel Freiman wrote:


I've got what I think are all of the metadata tags listed here:

http://nondocs.blogspot.com/2007/04/metadata.html 
http://nondocs.blogspot.com/2007/04/metadata.html


I don't know what all of them do, including the ones Kenneth asked 
about, but I'm working on it.


- Dan Freiman

On 5/1/07, *Jurgen Beck* [EMAIL PROTECTED] 
mailto:[EMAIL PROTECTED] wrote:


You can find some of them explained here, but that is not the
complete list either:


http://livedocs.adobe.com/flex/201/html/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Book_Partsfile=metadata_141_01.html

http://livedocs.adobe.com/flex/201/html/wwhelp/wwhimpl/common/html/wwhelp.htm?context=LiveDocs_Book_Partsfile=metadata_141_01.html

Jurgen

Kenneth Sutherland wrote:


Does anyone have information on the various metadata tags that
can be used in flex. I've been going through some of the source
files to find out a way of getting my custom component to tell a
model to update itself.

Some of the tags I've seen that I don't know what they do are

[DataBindingInfo]

[DefaultBindingProperty]

[DefaultTriggerEvent]

I've seen others but I won't to list everything here.

 


I've searched Livedocs and I can't find somewhere where all the
tags with explanations are listed.

 


Also if someone knows about models being updated can you advise
on the below problem

 


If my model is

mx:Model id=requiredFields

theForm

all

   
name { name.text } /name


   
birth  { DoB.selectedDate }/birth


/all

/theForm

/mx:Model

myValidator:FormValidator id=formValidator 
source={requiredFields} property=all/


 


When I call the validator the information it gets
from the model is the text from the text input which is updated
everytime the user changes the said text input, but the date
comes from a custom date entry component and the model doesn't
get the latest date from the component. It would seem like the
binding isn't working or my custom component isn't firing of the
required events for the model to update itself when the user
changes the date.

 


I've tried getting my custom component to fire of the following
events

[Event(name=change, type=flash.events.Event)]

[Event(name=valueCommit, type=mx.events.FlexEvent)]

As well as making the getter function for selectedDate
[Bindable], but the model still doesn't pick up on any changes
after the component has been initialised.

 


Cheers for any info.

 


*Kenneth.*



 


Re: {Disarmed} [flexcoders] Regd flex

2007-04-30 Thread Jurgen Beck
You need to be looking at something like MDM Zinc, which supports Flash 
and Flex:


http://www.multidmedia.com/

Jurgen

[EMAIL PROTECTED] wrote:

Hi,
 
Thanks in Advance
 
I am new to Flex, how to Convert the flex project into Exe Version as 
we do in Flash.
 
Awaiting for your reply mail.
 
Thanking you,
 
Yours faithfully,

R.Denesh Kumar
[EMAIL PROTECTED] mailto:[EMAIL PROTECTED]
 
 



Ahhh...imagining that irresistible new car smell?
Check out new cars at Yahoo! Autos. 
http://us.rd.yahoo.com/evt=48245/*http://autos.yahoo.com/new_cars.html;_ylc=X3oDMTE1YW1jcXJ2BF9TAzk3MTA3MDc2BHNlYwNtYWlsdGFncwRzbGsDbmV3LWNhcnM- 

 


Re: {Disarmed} Re: {Disarmed} [flexcoders] Regd flex

2007-04-30 Thread Jurgen Beck

Zinc is available for both Windows and Mac OS.

mychemic Carlo Gulliani wrote:

but this mdm zinc version support only macos, but not support win

- Original Message 
From: Jurgen Beck [EMAIL PROTECTED]
To: flexcoders@yahoogroups.com
Sent: Monday, April 30, 2007 4:05:18 PM
Subject: Re: {Disarmed} [flexcoders] Regd flex

You need to be looking at something like MDM Zinc, which supports 
Flash and Flex:


http://www.multidme dia.com/

Jurgen

[EMAIL PROTECTED] wrote:


Hi,
 
Thanks in Advance
 
I am new to Flex, how to Convert the flex project into Exe Version as 
we do in Flash.
 
Awaiting for your reply mail.
 
Thanking you,
 
Yours faithfully,

R.Denesh Kumar
[EMAIL PROTECTED] com mailto:[EMAIL PROTECTED]
 
 



Ahhh...imagining that irresistible new car smell?
Check out new cars at Yahoo! Autos. 
http://us.rd.yahoo.com/evt=48245/*http://autos.yahoo.com/new_cars.html;_ylc=X3oDMTE1YW1jcXJ2BF9TAzk3MTA3MDc2BHNlYwNtYWlsdGFncwRzbGsDbmV3LWNhcnM- 





Ahhh...imagining that irresistible new car smell?
Check out new cars at Yahoo! Autos. 
http://us.rd.yahoo.com/evt=48245/*http://autos.yahoo.com/new_cars.html;_ylc=X3oDMTE1YW1jcXJ2BF9TAzk3MTA3MDc2BHNlYwNtYWlsdGFncwRzbGsDbmV3LWNhcnM- 

 


[flexcoders] Flickr and Flex Implementation

2007-04-26 Thread Jurgen Beck
I am working on a photo gallery app that is supposed to access private 
images from a Flickr account. While it's pretty straight forward 
accessing publicly viewable images from a Flickr user or account, there 
seems to be a big problem with accessing private images AND keep 
everything user friendly.

Here is what I am finding:

When using the Flex Flickr API, I get stuck with displaying a separate 
window to authorize the Flex application to access the private images. 
That's not the fault of the API, but rather a way Flickr is implementing 
their authorization scheme.

 From a user's perspective, this of course is silly for two reasons: 
Number one, why having a RIA that keeps everything integrated and then 
going outside of the web application to authorize access, and secondly, 
this exposes the Flickr account in the secondary browser window, which I 
definitely don't want.

I thought I had found a workaround by simply just calling the 
authorization URL in a URLLoader like this:

var auth_url:String = flickrService.getLoginURL( 
frob, AuthPerm.READ );
   
 var loginLoader:URLLoader = new URLLoader();
var loginRequest:URLRequest = new URLRequest(auth_url);
   

loginLoader.addEventListener(Event.COMPLETE,loginRequestComplete);

loginLoader.addEventListener(SecurityErrorEvent.SECURITY_ERROR,loginSecurityError);

   

In the loginRequestComplete method I then proceed to getting the frob.

This works PERFECT on my local machine. I don't have to pop up a 
separate browser window to authorize the application with Flickr and 
everything proceeds to load the private images in the Flex application.

However, moving this to the web site, I get the dreaded security error 
that states that the application cannot access data from the Flickr URL.

I looked at the URLs. Here is what I find:

auth_url in the above code snippet will start with 
http://api.flickr.com/services/auth/?api_key=..., targeting the 
api.flickr.com, for which Flickr has set up a crossdomain.xml file. 
However, to check what's happening with the authorization process I use 
the auth_url n a browser window and find that there is a redirect that 
happens back to a URL of http://www.flickr.com/services/auth/?api_key=...

This means that my security error is triggered, because we are getting a 
response back from the flickr.com domain and not the api.flickr.com 
domain, at least that's what I assume is happening.

So, long write up and short question:

Has anyone made this work? What I am essentially after is a way to get 
to the private images through the Flex Flickr API without having to 
display the Flickr authorization window.

Thanks for any suggestions!

Jurgen


[flexcoders] Fade Effect and StartDelay Issue/Bug?

2007-04-20 Thread Jurgen Beck
Seems like I'm having an issue with the Fade effect and using startDelay.

I have the following Fade effect defined:

mx:Fade id=fadeIn duration=200 alphaFrom=0.0 alphaTo=1.0 
startDelay=1000/

This is used by a canvas component:

mx:Canvas id=myCanvas
width=400 height=400
visible={cb1.selected}
showEffect={fadeIn}
hideEffect={fadeOut}
mx:Button label=test/
/mx:Canvas

cb1 is a checkbox to play around with the fading in and out of the 
canvas. I'm starting out with the Canvas supposed to be invisible 
(checkbox unchecked).

Here is the problem:

When the visible property for the canvas is turned to true, Flex makes 
the canvas visible instantaneously and then after 1 second does the fade 
in effect. What should be happening is that the canvas is staying 
invisible and then doing the fade in.

Anyone run into this problem? Seems like a bug in Flex to me, but then 
again, I could be overlooking something.

Thanks,

Jurgen


Re: {Disarmed} [flexcoders] 360Flex vs. Adobe MAX - which would you attend?

2007-04-09 Thread Jurgen Beck
Can't speak for MAX, but if you are mainly looking at Flex, you should 
definitely do 360. I've been there in March and I can tell you that 
you'll learn LOTS and have access to the right people to ask your questions.


Jurgen

ben.clinkinbeard wrote:


Hello, I will most likely be able to attend one conference this year,
and I am trying to determine which would be more beneficial. Due to
the locations, the costs for each would be comparable (I could drive
to MAX), so its really just a matter of which is better. I am mainly
looking learn more (and more in-depth) about Flex, so I am thinking
360 might be the way to go, but thought I would put it out there to
the list.

Anyone have a strong opinion either way?

Thanks,
Ben

 


RE: {Disarmed} [flexcoders] New Adobe Products and Flex

2007-03-27 Thread Jurgen Beck
It's going to be VERY nice having a smooth workflow. I think this will
further boost Flex as a viable tool for web applications.

 

Is April 20th the published ship date?

 

Jurgen

 

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Paul Whitelock
Sent: Tuesday, March 27, 2007 7:59 AM
To: flexcoders@yahoogroups.com
Subject: {Disarmed} [flexcoders] New Adobe Products and Flex

 

In case you weren't aware, there seem to be a lot of goodies in the
new Adobe products for Flex developers. In particular, check out these
three CS3 packages (click the Feature Tour button for some of the
highlights):

Fireworks CS3:

http://www.adobe.com/products/fireworks/?xNav=WPFW

Flash Professional CS3:

http://www.adobe.com/products/flash/?xNav=WPFL

Illustrator CS3:

http://www.adobe.com/products/illustrator/?xNav=PPIL

Can't wait for April 20th!

Paul

 



[flexcoders] Scaling Fonts in Flex

2007-01-23 Thread Jurgen Beck
This may be an odd one and I know that you guys are going to respond
that you shouldn't really do this in Flex considering that Flex
applications are something different than Flash movies. :-)  So here it
goes:

 

Has anyone figured out a way to scale fonts (text, either with embedded
fonts or system fonts) in Flex? Can it be done, and if so, what's best
practice?

 

Rather than resizing the label, text, or text area containers, I need to
actually scale the font size in the objects. 

 

Thanks,

 

Jurgen



RE: [flexcoders] Data synchronisation tip and tricks?

2006-09-14 Thread Jurgen Beck





Very good topic! I'm working on a RIA using Flex that 
deals with a similar situation for an online ticketing system. Imagine two or 
more folks selecting the same seat and wanting to purchase a ticket for it. 
Essentially this is collision bound, unless it is being handled 
carefully.

I see two solutions:

a) Use Flex Data Services and it's real-time features 
of updating clients with the latest status on a specific room (in your 
scenario). This will not completely eliminate the possibility that both 
customers want to book the room at the exact same time. However, it will cut it 
down quite significantly. Of course, there is some additional stuff going on 
that we would have to take into consideration.

b) Use flags in the database records for each room as 
to its availability and return a response to a customer when the booking is 
committed. If someone else has beat them to it, then an error would be returned, 
eventually halting the rest of the transaction based on the fact that the room 
now is no longer available.

This is a very birds-eye view of what would need to 
happen, at least in my mind. There may be other approaches and solutions to this 
problem and I would be interested to hear them!

Jurgen


From: flexcoders@yahoogroups.com 
[mailto:[EMAIL PROTECTED] On Behalf Of Paul 
AndrewsSent: Thursday, September 14, 2006 9:11 AMTo: 
flexcoders@yahoogroups.comSubject: {Disarmed} [flexcoders] Data 
synchronisation tip and tricks?


Most of the traffic conversation here seems to revolve around 
applicationsthat are essentially read-only or are behaving as though they 
are singleuser.Any tips and tricks to be found regarding the 
synchronisation of data in amulti-user application involving a 
database.For example (since hotel booking is a prominent example in the 
RIA world),lets suppose I have two customers (Customer A and Cust B) trying 
to book thesame hotel room on the same day. Both see it as free in the RIA, 
Cust Abooks it and now the other must know about it too, so effectively 
thenthat's a straight refresh of Cust B display and the aborting of the 
bookingin progress.Lets suppose my application allows Cust B to mark 
several days of roombookings and (s)he has to hit 'book now' to commit to 
the booking. Whilethis is going on 'Cust A' has booked one of those days, so 
now I must mergethe updated database with the on-screen representation, so 
it's no longer astraight replacement of the application display from the 
database, we'rehaving to merge.Perhaps I'd best not even mention 
database locking and handling that in aRIA.Get the idea? I 
appreciate this isn't entirely Flex specific.If there are tips and 
tricks/best practices in this area with regard toFlex, I'd like to know 
about them before I re-invent the wheel!Paul
__._,_.___





--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com








   






  
  
SPONSORED LINKS
  
  
  

Software development tool
  
  
Software development
  
  
Software development services
  
  


Home design software
  
  
Software development company
  

   
  






  
  Your email settings: Individual Email|Traditional 
  Change settings via the Web (Yahoo! ID required) 
  Change settings via email: Switch delivery to Daily Digest | Switch to Fully Featured 
   
Visit Your Group 
   |
  
Yahoo! Groups Terms of Use
   |
  
   Unsubscribe 
   
 

  




__,_._,___



[flexcoders] Background Image Alignment using SWF as Background

2006-08-19 Thread Jurgen Beck
I am using a CSS style to set the background of a mx:Box. The embedded
image is a movie clip object from an asset SWF. Everything works fine,
the SWF resource shows up in my application. However, I cannot figure
out how to get Flex to align the embedded SWF object on the left side.
It seems that by default everything is lined up in the middle.

Any suggestion on how to fix this?

Thanks,

JB








--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

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

* 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/