RE: [flexcoders] Re: Can not add a Loader object to a container

2007-10-20 Thread Alex Harui
SWFLoader will load any SWF from any URL.  What problems did you run
into?

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of anewgene
Sent: Friday, October 19, 2007 9:43 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Can not add a Loader object to a container

 

Thanks for the reply. 
I have tried SWFLoader solution, but it seems only loading local 
swf file, not an external one referred by an URL.

For the rawChildren solution, I can add loader object indeed, but 
how should I handle sizing issue? For example, I want to add this 
loader into a titleWindow and make it resizable together with its 
container? It seems not a easy thing.

Anyway, my project requires to load external swf into the main 
canvas, as an way for user to add their own plug-ins. What is the 
best way for this?

Thanks again.

lei

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

 Or use SWFLoader
 
 
 
 
 
 From: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com

[mailto:flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
] On
 Behalf Of Arpit Mathur
 Sent: Friday, October 19, 2007 3:57 PM
 To: flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com 
 Subject: Re: [flexcoders] Can not add a Loader object to a 
container
 
 
 
 this.rawchildren.addChild(loader)
 
 
 
 Containers can only add Flex components to the displaylist. Loader 
is a
 low level actionscript object.
 
 
 
 Using rawchildren, u can add the loader but you have to be 
responsible
 for the sizing etc.
 
 
 
 
 
 
 
 On 10/19/07, anewgene [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] 
 wrote: 
 
 Hi,
 I am trying to add external swf into my app. Based on the doc at:
 
 http://livedocs.adobe.com/labs/flex3/html/help.html?
http://livedocs.adobe.com/labs/flex3/html/help.html? 
 http://livedocs.adobe.com/labs/flex3/html/help.html?
http://livedocs.adobe.com/labs/flex3/html/help.html?  
 content=Working_with_MovieClips_8.html
 
 I created this minimal test code (as below). But I can not make it 
 work (Type Coercion error). The code and the error are pasted here. 
I 
 have tested on both flex3beta2 and flex2hotfix3. 
 
 Can someone help me out? Thanks.
 
 Lei
 
 Code:
 =
 ?xml version=1.0 encoding=utf-8?
 mx:Application xmlns:mx= http://www.adobe.com/2006/mxml
http://www.adobe.com/2006/mxml 
 http://www.adobe.com/2006/mxml http://www.adobe.com/2006/mxml   
 layout=absolute creationComplete=init()  
 
 mx:Script
 ![CDATA[
 import flash.display.*;
 import flash.net.URLRequest;
 
 private function init():void
 {
 var request:URLRequest = new 
 URLRequest( http://flex.org/blogs/FlexOrgRSSApplication.swf
http://flex.org/blogs/FlexOrgRSSApplication.swf 
 http://flex.org/blogs/FlexOrgRSSApplication.swf
http://flex.org/blogs/FlexOrgRSSApplication.swf  );
 var ldr:Loader = new Loader()
 ldr.load(request);
 addChild(ldr);
 }
 ]]
 /mx:Script
 
 /mx:Application
 
 = 
 Error:
 
 [SWF] X:\cvs\test2\bin\loadertest.swf - 516,787 bytes after 
 decompression
 TypeError: Error #1034: Type Coercion failed: cannot convert 
 flash.display::[EMAIL PROTECTED] to mx.core.IUIComponent.
 at 
 
mx.core::Container/http://www.adobe.com/2006/flex/mx/internal::addingC
http://www.adobe.com/2006/flex/mx/internal::addingC 
 http://www.adobe.com/2006/flex/mx/internal::addingC
http://www.adobe.com/2006/flex/mx/internal::addingC  
 hild()[E:\dev\flex_3_beta2 
 \sdk\frameworks\projects\framework\src\mx\core\Container.as:3288]
 at mx.core::Container/addChildAt()[E:\dev\flex_3_beta2
 \sdk\frameworks\projects\framework\src\mx\core\Container.as:2248]
 at mx.core::Container/addChild ()[E:\dev\flex_3_beta2
 \sdk\frameworks\projects\framework\src\mx\core\Container.as:2188]
 at loadertest/init()[X:\cvs\test2\src\loadertest.mxml:14]
 at loadertest/___loadertest_Application1_creationComplete()
 [X:\cvs\test2\src\loadertest.mxml:2] 
 at flash.events::EventDispatcher/dispatchEventFunction()
 at flash.events::EventDispatcher/dispatchEvent()
 at mx.core::UIComponent/dispatchEvent()[E:\dev\flex_3_beta2
 \sdk\frameworks\projects\framework\src\mx\core\UIComponent.as:8915] 
 at mx.core::UIComponent/set initialized()[E:\dev\flex_3_beta2
 \sdk\frameworks\projects\framework\src\mx\core\UIComponent.as:1118]
 at mx.managers::LayoutManager/doPhasedInstantiation()
 [E:\dev\flex_3_beta2
 
\sdk\frameworks\projects\framework\src\mx\managers\LayoutManager.as:69
 6]
 at Function/http://adobe.com/AS3/2006/builtin::apply
http://adobe.com/AS3/2006/builtin::apply 
 http://adobe.com/AS3/2006/builtin::apply
http://adobe.com/AS3/2006/builtin::apply  ()
 at mx.core::UIComponent/callLaterDispatcher2()
 [E:\dev\flex_3_beta2
 \sdk\frameworks\projects\framework\src\mx\core\UIComponent.as:8338]
 at mx.core::UIComponent/callLaterDispatcher()
 [E:\dev\flex_3_beta2 
 

[flexcoders] Re: Looking for horizontal sliding list/dialog component (like iPhone UI)

2007-10-20 Thread andiboarder
Hi!

 Try using a ViewStack  that use WipeRight and WipeLeft effects when
 hiding and showing a new selectedIndex. This should be a starting point.

Thanks, but the problem is, this will not slide the new content in, it will 
just reveal it. What I 
need is something like what the accordion does. I took a look at the HAccordion 
implementation, but it seems to be rather complicated (at least the code there).

I'm wondering that there is no component out there, which does this. It is not 
too exotic.

I could have a look at how the IUI iPhone Ajax UI implementation does the 
sliding, but Flex is 
to different from JS/HTML to transfer the principles from there...






[flexcoders] softphone development

2007-10-20 Thread jibril_fuseini
I will like to know if there is someone out there how has work on 
softphone with flex and action script 3
thank you



[flexcoders] Re: Hyperlink in flex.

2007-10-20 Thread Randy Cooper
http://www.brucephillips.name/blog/index.cfm/2006/11/21/Creating-Web-Page-an
d-Email-Links-In-A-Flex-Application

 

I've found this code snippet extremely useful and I think it'll do what
you're looking for.

 

Randy Cooper

http://www.randycooper.net

 



[flexcoders] Re: Flex is becoming unviable

2007-10-20 Thread dbronk
So how do I make my browser cache the swf?  Every time I navigate to
my app, the swf loads from the server.

As far as comparing html sites with using modules, I think it is very
tough to compare such different techologies.  But, with the modules I
have to wait for another xK bytes module to load which means not a
smooth transition.  If I was simply doing an html site, we would never
go back to the server for such large chunks of data.  Using AJAX I
would be able to grab much smaller amounts of data (most ajax apps I
done would generally only return less that 2k-10k allowing for it to
be extremely fast and keeping whatever transition I want.  But of
course, then all sorts of browser issues with javascript, etc.  It
there was a way that I could load the modules in the background while
the user is doing other things would be great, then it would be there
right when I need it.  But I think comparing the file sizes of a
client side app vs a server side app is apples and oranges.

I hope you are right and Adobe is giving this the highest priority as
Flex is a very wonderful thing and I'd hate to have it not be as wide
spread as it should be because of a serious, but solvable problem.

Dale

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

 Adobe is putting very serious thought into this problem.
 
  
 
 FWIW:
 
  
 
 1)   Browsers do cache SWFs
 
 2)   The cached framework will save your app 130-500K depending on
 how much of the framework you use
 
 3)   Modules is not a workaround.  Modularity is a fundamental piece
 of any large application.  HTML sites consist of many html pages.
 Modules is essentially the same thing
 
 4)   Your app should end up being way more than 500K of small module
 swfs.  A large HTML site can easily end up serving about the same as you
 view many pages.  Hopefully you'll serve up fewer modules since the
 various view states don't need to be different html pages.
 
  
 
  
 
 
 
 From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
 Behalf Of dbronk
 Sent: Friday, October 19, 2007 12:01 PM
 To: flexcoders@yahoogroups.com
 Subject: [flexcoders] Re: Flex is becoming unviable
 
  
 
 But we shouldn't have to rely on people getting faster and faster
 connections. To me, that is the same as saying I don't have to worry
 about poor coding practices that produce inefficient apps because
 Intel is building faster chips.
 
 Adobe needs to put very serious thought into aggressively reducing the
 size of the SWF files. I'm only into our project about 5%-8% and are
 already creating 740k swf. I think 500k is too big, by the way. 
 Especially since it needs to download everytime a user comes back. 
 Now if the browser could cache the swf file like it does a graphic,
 then that would ease my mind a bit. I love flex. It has given me new
 excitement in my work. But, I agree with the original poster that if
 Adobe wants flex to become a big player in enterprise apps, they
 better get this solved quickly.
 
 Having the framework cache in the player is a great start, but no
 where near enough. What is that, about 150k-200k? That puts me still
 at over 500k and a ton left on the app. My app when done will have
 100+ different pages. Modules is another solution, but I see it more
 as a work around than a fix. For an app the size mine will be, it is
 probably asking too much to get it down to less than 500k.
 
 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com
 , Tom Chiverton tom.chiverton@
 wrote:
 
  On Friday 19 Oct 2007, danielvlopes@ wrote:
   But i think this is good price to pay.
  
  Exactly. The percentage of people with fast connections is only
 going to go 
  up.
  
  -- 
  Tom Chiverton. Are you a great Flex programmer, who knows Cairngorm,
 and has 
  done some ColdFusion work ? Would you like to work for a top 30 law
 firm in 
  Manchester, UK ? Are not an agency ? If yes, send email !
  
  
  
  This email is sent for and on behalf of Halliwells LLP.
  
  Halliwells LLP is a limited liability partnership registered in
 England and Wales under registered number OC307980 whose registered
 office address is at St James's Court Brown Street Manchester M2 2JF.
 A list of members is available for inspection at the registered
 office. Any reference to a partner in relation to Halliwells LLP
 means a member of Halliwells LLP. Regulated by The Solicitors
 Regulation Authority.
  
  CONFIDENTIALITY
  
  This email is intended only for the use of the addressee named above
 and may be confidential or legally privileged. If you are not the
 addressee you must not read it and must not use any information
 contained in nor copy it nor inform any person other than Halliwells
 LLP or the addressee of its existence or contents. If you have
 received this email in error please delete it and notify Halliwells
 LLP IT Department on 0870 365 8008.
  
  For 

[flexcoders] Error 2025 with images in TextArea?

2007-10-20 Thread arpan srivastava
Hi All,

I am pasting a mail below. I am facing the same problem while displaying 
html in textarea. I didn't find any answers to this. Can anyone help with 
problem?

--Message-

I'm working on a quick little RSS Reader and having some trouble.

I've got a DG on one side, which then populates a textArea on the other side.

Here's the feed (mine) 
http://www.red-omega.com/blog/rss.cfm?mode=full

When I hit the entry Blogito Ergo Sum when I click to entry in the DG I get 
the below.

It seems to happen when entries have images linked from other sites.


[SWF] Users:johnwilker:Documents:Flex Builder 2:360FlexRSS:bin:main-debug.swf - 
972,300 bytes after decompression
getting the feed: http://www.red-omega.com/blog/rss.cfm?mode=full

You Selected index: 7
You Selected index: 8
ArgumentError: Error #2025: The supplied DisplayObject must be a child of the 
caller.
at flash.text::TextField/set htmlText()
at mx.core::UITextField/set
htmlText()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\UITextField.as:319]
   
at
mx.controls::TextArea/mx.controls:TextArea::commitProperties()[C:\dev\flex_201_gmc\sdk\frameworks\mx\controls\TextArea.as:1841]
at 
mx.core::UIComponent/validateProperties()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\UIComponent.as:5300]
   
at
mx.managers::LayoutManager/mx.managers:LayoutManager::validateProperties()[C:\dev\flex_201_gmc\sdk\frameworks\mx\managers\LayoutManager.as:517]

at
mx.managers::LayoutManager/mx.managers:LayoutManager::doPhasedInstantiation()[C:\dev\flex_201_gmc\sdk\frameworks\mx\managers\LayoutManager.as:667]
at Function/http://adobe.com/AS3/2006/builtin::apply()

at
mx.core::UIComponent/mx.core:UIComponent::callLaterDispatcher2()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\UIComponent.as:7909]
   
at
mx.core::UIComponent/mx.core:UIComponent::callLaterDispatcher()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\UIComponent.as:7852]

at flash.utils::Timer/flash.utils:Timer::_timerDispatch()
at flash.utils::Timer/flash.utils:Timer::tick()

Any thoughts?


__
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

Re: [flexcoders] Yahoo Maps

2007-10-20 Thread Mansour Raad


If you are looking for a mapping component, check out ESRI Flex2  
mapping component at http://www.esri.com/flex


Mansour
Check out my blog http://thunderheadxpler.blogspot.com
:-)





[flexcoders] Flex sites not running under the URL

2007-10-20 Thread stephen50232
HI,

I've posted this message on the Adobe forum, but I thought I'd post it
here too, so sorry for the cross posting, anyway

I have recently been moving some Flex apps onto a new server, now the
problem I'm having is that any Flex app that uses Remoting is only
available via the IP address. When I call the site via the URL I
create in IIS i always get this error message:

mx.rpc::Fault)#0
  errorID = 0
  faultCode = Server.Processing
  faultDetail = (null)
  faultString = java.lang.NullPointerException
  message = faultCode:Server.Processing
faultString:'java.lang.NullPointerException' faultDetail:'null'
  name = Error
  rootCause = (null)

Now when I call the same site via the IP address I don't get an error
message and the site works. I've been researching this problem and
asked other people about this and it seems that the problem has to do
with the service-config.xml file, so I've checked my
service-config.xml file and the endpoint entries are fine, e.g:

endpoint
uri=http://{server.name}:{server.port}{context.root}/flex2gateway/cfamfpolling;
class=flex.messaging.endpoints.AMFEndpoint/
   
Which seems fine, I've also put a crossdomain policy file in the root
of my app and that's not fixing the problem. So I'm stuck for ideas.

Can anyone shed so light and ideas and what to check to solve this
problem?

Thanks

Stephen



Re: [flexcoders] Re: Flex is becoming unviable

2007-10-20 Thread Jeffry Houser
dbronk wrote:
 
 So how do I make my browser cache the swf? Every time I navigate to
 my app, the swf loads from the server.
 
 As far as comparing html sites with using modules, I think it is very
 tough to compare such different techologies. But, with the modules I
 have to wait for another xK bytes module to load which means not a
 smooth transition. If I was simply doing an html site, we would never
 go back to the server for such large chunks of data. Using AJAX I
 would be able to grab much smaller amounts of data 

  How is that different than a Flex app?  How does the size of a Flex 
swf compare to the initial download of an AJAX one?

  I thought this was one of the selling points of RIAs, either with Flex
or AJAX was that after the initial download, you end up using less 
bandwidth.  Download the application once, and then just pass data back 
and forth.

  I know that my Blockbuster on-line queue is unusable with 250 movies 
in  it.  But, I've built similar type functionality into Flex apps and 
it is pretty snappy.


-- 
Jeffry Houser, Technical Entrepreneur, Software Developer, Author, 
Recording Engineer
AIM: Reboog711  | Phone: 1-203-379-0773
--
My Company: http://www.dot-com-it.com
My Podcast: http://www.theflexshow.com
My Blog: http://www.jeffryhouser.com



Re: [flexcoders] DataGrid not initializing default styles

2007-10-20 Thread Daniel Freiman
addPopUp is called the line before centerPopUp.  Also, the second error is
thrown after user interaction with the PopUp (not user interaction with the
DataGrid though) so it's definitely been created already before the second
error.

- Dan Freiman

On 10/19/07, Alex Harui [EMAIL PROTECTED] wrote:

Could you be centering a popup that hasn't been addPopUp'd?


  --

 *From:* flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] *On
 Behalf Of *Daniel Freiman
 *Sent:* Friday, October 19, 2007 4:52 PM
 *To:* flexcoders@yahoogroups.com
 *Subject:* Re: [flexcoders] DataGrid not initializing default styles



 Nope, it's just a plain DataGrid.  All I touched was percentWidth/Height,
 minColumnWidth, draggable/resizableColumns and dataProvider. It's in the
 same popup as my earlier layout bug (Nested containers inside a PopUp.)
 Although I haven't been able to recreate in a contained example yet.

 - Dan Freiman

 On 10/19/07, *Alex Harui* [EMAIL PROTECTED] wrote:

 Did you subclass DG?  Alter its styles?


  --

 *From:* [EMAIL PROTECTED] ups.com [mailto:[EMAIL PROTECTED] ups.com] *On
 Behalf Of *Daniel Freiman
 *Sent:* Friday, October 19, 2007 2:37 PM
 *To:* flexcoders
 *Subject:* [flexcoders] DataGrid not initializing default styles



 I'm getting a situation where a Datagrid is not initializing it's default
 styles and is causing runtime errors when datagrid functions try to retrieve
 and operate on styles that are null.  I'm getting two errors which I'm
 hoping will look familiar to someone:

 The first one occurs when the PopUpManager is validating a new popup
 container of which the datagrid is a descendant:

 TypeError: Error #1009: Cannot access a property or method of a null
 object reference.
 at mx.controls::DataGrid/mx.controls:DataGrid::drawHeaderBackground
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\controls\DataGrid.as:2573]
 at 
 mx.controls::DataGrid/mx.controls:DataGrid::updateDisplayList()[C:\dev\flex_201_gmc\sdk\frameworks\mx\controls\DataGrid.as:1257]

 at mx.core::UIComponent/validateDisplayList
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\UIComponent.as:5760]
 at 
 mx.managers::LayoutManager/validateClient()[C:\dev\flex_201_gmc\sdk\frameworks\mx\managers\LayoutManager.as:858]

 at mx.core::UIComponent/validateNow
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\UIComponent.as:5218]
 at 
 mx.managers::PopUpManagerImpl/centerPopUp()[C:\dev\flex_201_gmc\sdk\frameworks\mx\managers\PopUpManagerImpl.as:336]

 at mx.managers::PopUpManager$/centerPopUp
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\managers\PopUpManager.as:163]
 at com.colorquick.improv.managers::PaneManager$/openPane()[C:\Documents
 and Settings\Daniel\My Documents\Flex Builder
 2\Improv2\com\colorquick\improv\managers\PaneManager.as:98]
 at
 com.colorquick.improv.toolbars.controls::DAMBrowseLists/com.colorquick.improv.toolbars.controls:DAMBrowseLists::clickHandler()[C:\Documents
 and Settings\Daniel\My Documents\Flex Builder
 2\Improv2\com\colorquick\improv\toolbars\controls\DAMBrowseLists.as:24]

 If I workaround this error, the second one gets thrown after the
 dataprovider and columns properties are updated:

 TypeError: Error #1007: Instantiation attempted on a non-constructor.
 at 
 mx.controls::DataGrid/mx.controls:DataGrid::drawSeparators()[C:\dev\flex_201_gmc\sdk\frameworks\mx\controls\DataGrid.as:2896]
 at mx.controls::DataGrid/mx.controls:DataGrid::updateDisplayList
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\controls\DataGrid.as:1269]
 at
 mx.core::ScrollControlBase/mx.core:ScrollControlBase::setScrollBarProperties()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\ScrollControlBase.as:1084]
 at mx.controls::DataGrid/mx.controls:DataGrid::configureScrollBars
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\controls\DataGrid.as:1791]
 at
 mx.controls.listClasses::ListBase/mx.controls.listClasses:ListBase::updateDisplayList
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\controls\listClasses\ListBase.as:2972]
 at 
 mx.controls::DataGrid/mx.controls:DataGrid::updateDisplayList()[C:\dev\flex_201_gmc\sdk\frameworks\mx\controls\DataGrid.as:1208]
 at mx.core::UIComponent/validateDisplayList
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\UIComponent.as:5760]
 at
 mx.managers::LayoutManager/mx.managers:LayoutManager::validateDisplayList()[C:\dev\flex_201_gmc\sdk\frameworks\mx\managers\LayoutManager.as:600]
 at
 mx.managers::LayoutManager/mx.managers:LayoutManager::doPhasedInstantiation()[C:\dev\flex_201_gmc\sdk\frameworks\mx\managers\LayoutManager.as:673]

 at Function/http://adobe.com/AS3/2006/builtin::apply()
 at mx.core::UIComponent/mx.core:UIComponent::callLaterDispatcher2
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\UICompon ent.as:7909]
 at 
 mx.core::UIComponent/mx.core:UIComponent::callLaterDispatcher()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\UICompon
 ent.as:7852]

 - Dan Freiman



  



[flexcoders] RandomWalk component

2007-10-20 Thread jovialrandor
How can I remove the background skin code from the RandomWalk 
component so I can add my own backgrounds/flex containers?

http://www.quietlyscheming.com/blog/components/randomwalk-component/.

Thanks



Re: [flexcoders] Error 2025 with images in TextArea?

2007-10-20 Thread Daniel Freiman
Are you trying to reference an image/id that's already displayed somewhere
else in the flex movie?  Can you give an example of the htmlText that you
are trying to set?

- Dan Freiman

On 10/20/07, arpan srivastava [EMAIL PROTECTED] wrote:

   Hi All,

 I am pasting a mail below. I am facing the same problem while
 displaying html in textarea. I didn't find any answers to this. Can anyone
 help with problem?

 --Message-

 I'm working on a quick little RSS Reader and having some trouble.

 I've got a DG on one side, which then populates a textArea on the other
 side.

 Here's the feed (mine) http://www.red-omega.com/blog/rss.cfm?mode=full

 When I hit the entry Blogito Ergo Sum when I click to entry in the DG I
 get the below.

 It seems to happen when entries have images linked from other sites.

 [SWF] Users:johnwilker:Documents:Flex Builder 2:360FlexRSS:bin:
 main-debug.swf - 972,300 bytes after decompression
 getting the feed: http://www.red-omega.com/blog/rss.cfm?mode=full
 You Selected index: 7
 You Selected index: 8
 ArgumentError: Error #2025: The supplied DisplayObject must be a child of
 the caller.
 at flash.text::TextField/set htmlText()
 at 
 mx.core::UITextField/sethtmlText()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\UITextFi
 eld.as:319]
 at mx.controls::TextArea/mx.controls:TextArea::commitProperties
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\controls\TextArea.as:1841]
 at mx.core::UIComponent/validateProperties
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\UIComponent.as:5300]
 at
 mx.managers::LayoutManager/mx.managers:LayoutManager::validateProperties()[C:\dev\flex_201_gmc\sdk\frameworks\mx\managers\LayoutManager.as:517]

 at
 mx.managers::LayoutManager/mx.managers:LayoutManager::doPhasedInstantiation
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\managers\LayoutManager.as:667]
 at Function/http://adobe.com/AS3/2006/builtin::apply()
 at mx.core::UIComponent/mx.core:UIComponent::callLaterDispatcher2
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\UIComponent.as:7909]
 at mx.core::UIComponent/mx.core:UIComponent::callLaterDispatcher
 ()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\UIComponent.as:7852]
 at flash.utils::Timer/flash.utils:Timer::_timerDispatch()
 at flash.utils::Timer/flash.utils:Timer::tick()

 Any thoughts?

 __
 Do You Yahoo!?
 Tired of spam? Yahoo! Mail has the best spam protection around
 http://mail.yahoo.com

  



[flexcoders] Re: Use a CSS file in Flex

2007-10-20 Thread arieljake
2 questions regarding stylesheets in Flex:

1) is it 'background-image' or 'backgroundImage'?

2) like when we name a style Button to apply to all mx:Button, can
we do this with custom components, i.e. ArielsButton for
custom:ArielsButton?

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

 Hi Venkat,
 
 Once you include the css file in your application, you can access
its class by using,
 
 styleName=classname 
 
 
 Thanks 
 Ameet
 
 -Original Message-
 From: Venkat Perpati [EMAIL PROTECTED]
 To: flexcoders@yahoogroups.com
 Date: Fri, 19 Oct 2007 04:05:27 +0100 (BST)
 Subject: Re: [flexcoders] Use a CSS file in Flex
 
  
  
  Hi,
 
got it. mx:Style source=http://www.somesite.com/mystyles.css;
 is used to include css file in the application . But how to use the
style defined in it , is it same as we use in html file 
 
like tr class=style1 
 
can you pls give me an example of how we use the styles after
including the CSS file in the application.
 
regards,
Venkat Perpati

  Peter Connolly [EMAIL PROTECTED] wrote:
Here's how you reference a CSS file:
  
  mx:Style source=http://www.somesite.com/mystyles.css;
  
  After that, there's a chapter on CSS in the Flex Developer's Guide.
  
  On 10/18/07, Venkat Perpati [EMAIL PROTECTED] wrote:
  
  
  
  
  
  
  
   Hi,
  
   Can anyone please tell me how to add a CSS file and use the
styles defined in CSS file in the flex application.
  
   Thanks in Advance
  
   regards,
   Venkat Perpati.
  
  
   
  Meet people who discuss and share your passions. Join them now.
  
  
  
   
  
  
   
  
 
  -
   5, 50, 500, 5000 - Store N number of mails in your inbox. Click here.
 





[flexcoders] Re: Weird WebService Problem

2007-10-20 Thread Ben
--- In flexcoders@yahoogroups.com, Ben [EMAIL PROTECTED] wrote:

 In my Flex Application MXML file I call a function called init() on
 the creationComplete event.  creationComplete=init();  In the init()
 function a WebService's wsdl property is set to the URL for my CFC. 
 After the property is set I call a function on my service
 (service.getBlah();) but the request is never sent.  However, if I set
 the WebService wsdl on the WebService MXML tag before I compile my
 program, the request is sent.
 
 I'm not sure what could be the problem here.  It seems that there
 might be some time after the wsdl is set in which requests cannot be
sent.
 
 Does anyone know?  Thanks in advance!


I figured it out.  I wasn't calling the loadWSDL() function after
setting the wsdl.



[flexcoders] Custom Component not visible on stage

2007-10-20 Thread droponrcll
I have created a custom AS component DragObject based on Canvas.  
The idea is that ultimately users will be able to put whatever they 
want inside this ontainer and it will handle most of the code of drag 
and drop for them.


However, when I put another (100 x 100) Canvas inside this component 
just to test it out, the width and height of my component are 0, so 
it doesn't show up on stage.  I used the super() method in my 
constructor, so I expected my component to behave like a Canvas in 
that it should automatically be sized around its children.

Here is the AS for my class:

package elearning
{
import mx.containers.Canvas;

public class DragObject extends Canvas
{
public function DragObject()
{
super();
}
private var _desc:String = Untitled Draggable 
Object;
public function get desc():String{
return _desc;
}
public function set desc(descTxt:String):void{
_desc=descTxt;
}
override public function toString():String{
return(DragObject  + _desc);
}
}
}

Thanks!



Re: SPAM-LOW: [flexcoders] Custom Component not visible on stage

2007-10-20 Thread Jeffry Houser

  I've had similar problems when creating AS3 components.  Look into 
updateDisplayList.  I believe you also have to make sure that your 
custom component has a width and height specified.

  You can always dig through the canvas code to figure out why that 
works, and use that info to figure out why yours doesn't.

droponrcll wrote:
 
 
 I have created a custom AS component DragObject based on Canvas.
 The idea is that ultimately users will be able to put whatever they
 want inside this ontainer and it will handle most of the code of drag
 and drop for them.
 
 However, when I put another (100 x 100) Canvas inside this component
 just to test it out, the width and height of my component are 0, so
 it doesn't show up on stage. I used the super() method in my
 constructor, so I expected my component to behave like a Canvas in
 that it should automatically be sized around its children.
 
 Here is the AS for my class:
 
 package elearning
 {
 import mx.containers.Canvas;
 
 public class DragObject extends Canvas
 {
 public function DragObject()
 {
 super();
 }
 private var _desc:String = Untitled Draggable
 Object;
 public function get desc():String{
 return _desc;
 }
 public function set desc(descTxt:String):void{
 _desc=descTxt;
 }
 override public function toString():String{
 return(DragObject  + _desc);
 }
 }
 }
 
 Thanks!
 

-- 
Jeffry Houser, Technical Entrepreneur, Software Developer, Author, 
Recording Engineer
AIM: Reboog711  | Phone: 1-203-379-0773
--
My Company: http://www.dot-com-it.com
My Podcast: http://www.theflexshow.com
My Blog: http://www.jeffryhouser.com



Re: SPAM-LOW: [flexcoders] Custom Component not visible on stage

2007-10-20 Thread droponrcll
--- In flexcoders@yahoogroups.com, Jeffry Houser [EMAIL PROTECTED] wrote:

 
   I've had similar problems when creating AS3 components.  Look into 
 updateDisplayList.  I believe you also have to make sure that your 
 custom component has a width and height specified.
 
   You can always dig through the canvas code to figure out why that 
 works, and use that info to figure out why yours doesn't.

The component really needs to size itself around its children, so I 
need to find a way to do it without specifying a width and height.  My 
class is extending Canvas, so it should be using all Canvas's methods 
already, right?



Re: SPAM-LOW: [flexcoders] Custom Component not visible on stage

2007-10-20 Thread Jeffry Houser

  I'm really talking from a stance of someone who doesn't fully grok how 
this works yet.  With that disclaimer...

  In my experience, making a component display is not as simple as 
extending it and calling super() in the constructor.

  Size it around your children makes sense.  Figure out how Canvas does 
it, and you should be able to figure out why yours isn't working.  Or 
access the children to figure out the size of your custom component.

droponrcll wrote:
 
 
 --- In flexcoders@yahoogroups.com mailto:flexcoders%40yahoogroups.com, 
 Jeffry Houser [EMAIL PROTECTED] wrote:
  
  
   I've had similar problems when creating AS3 components. Look into
   updateDisplayList. I believe you also have to make sure that your
   custom component has a width and height specified.
  
   You can always dig through the canvas code to figure out why that
   works, and use that info to figure out why yours doesn't.
 
 The component really needs to size itself around its children, so I
 need to find a way to do it without specifying a width and height. My
 class is extending Canvas, so it should be using all Canvas's methods
 already, right?

-- 
Jeffry Houser, Technical Entrepreneur, Software Developer, Author, 
Recording Engineer
AIM: Reboog711  | Phone: 1-203-379-0773
--
My Company: http://www.dot-com-it.com
My Podcast: http://www.theflexshow.com
My Blog: http://www.jeffryhouser.com



RE: [flexcoders] DataGrid not initializing default styles

2007-10-20 Thread Alex Harui
The style chain is broken or damaged.  I would debug into it.  If you
can make a simple test case I'll take a look

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Daniel Freiman
Sent: Saturday, October 20, 2007 9:34 AM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] DataGrid not initializing default styles

 

addPopUp is called the line before centerPopUp.  Also, the second error
is thrown after user interaction with the PopUp (not user interaction
with the DataGrid though) so it's definitely been created already before
the second error. 

- Dan Freiman

On 10/19/07, Alex Harui [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] 
wrote:

Could you be centering a popup that hasn't been addPopUp'd?

 



From: [EMAIL PROTECTED] ups.com [mailto:[EMAIL PROTECTED] ups.com
http://ups.com ] On Behalf Of Daniel Freiman
Sent: Friday, October 19, 2007 4:52 PM
To: flexcoders@yahoogroups.com
Subject: Re: [flexcoders] DataGrid not initializing default styles

 

Nope, it's just a plain DataGrid.  All I touched was
percentWidth/Height, minColumnWidth, draggable/resizableColumns and
dataProvider. It's in the same popup as my earlier layout bug (Nested
containers inside a PopUp.)  Although I haven't been able to recreate in
a contained example yet. 

- Dan Freiman

On 10/19/07, Alex Harui [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] 
wrote:

Did you subclass DG?  Alter its styles?

 



From: [EMAIL PROTECTED] ups.com [mailto:[EMAIL PROTECTED] ups.com
http://ups.com ] On Behalf Of Daniel Freiman
Sent: Friday, October 19, 2007 2:37 PM
To: flexcoders
Subject: [flexcoders] DataGrid not initializing default styles

 

I'm getting a situation where a Datagrid is not initializing it's
default styles and is causing runtime errors when datagrid functions try
to retrieve and operate on styles that are null.  I'm getting two errors
which I'm hoping will look familiar to someone: 

The first one occurs when the PopUpManager is validating a new popup
container of which the datagrid is a descendant:

TypeError: Error #1009: Cannot access a property or method of a null
object reference.
at
mx.controls::DataGrid/mx.controls:DataGrid::drawHeaderBackground()[C:\de
v\flex_201_gmc\sdk\frameworks\mx\controls\DataGrid.as:2573]
at
mx.controls::DataGrid/mx.controls:DataGrid::updateDisplayList()[C:\dev\f
lex_201_gmc\sdk\frameworks\mx\controls\DataGrid.as:1257] 
at
mx.core::UIComponent/validateDisplayList()[C:\dev\flex_201_gmc\sdk\frame
works\mx\core\UIComponent.as:5760]
at
mx.managers::LayoutManager/validateClient()[C:\dev\flex_201_gmc\sdk\fram
eworks\mx\managers\LayoutManager.as:858] 
at
mx.core::UIComponent/validateNow()[C:\dev\flex_201_gmc\sdk\frameworks\mx
\core\UIComponent.as:5218]
at
mx.managers::PopUpManagerImpl/centerPopUp()[C:\dev\flex_201_gmc\sdk\fram
eworks\mx\managers\PopUpManagerImpl.as:336] 
at
mx.managers::PopUpManager$/centerPopUp()[C:\dev\flex_201_gmc\sdk\framewo
rks\mx\managers\PopUpManager.as:163]
at
com.colorquick.improv.managers::PaneManager$/openPane()[C:\Documents and
Settings\Daniel\My Documents\Flex Builder
2\Improv2\com\colorquick\improv\managers\PaneManager.as:98] 
at
com.colorquick.improv.toolbars.controls::DAMBrowseLists/com.colorquick.i
mprov.toolbars.controls:DAMBrowseLists::clickHandler()[C:\Documents and
Settings\Daniel\My Documents\Flex Builder
2\Improv2\com\colorquick\improv\toolbars\controls\DAMBrowseLists.as:24] 

If I workaround this error, the second one gets thrown after the
dataprovider and columns properties are updated:

TypeError: Error #1007: Instantiation attempted on a non-constructor.
at mx.controls::DataGrid/mx.controls:DataGrid::drawSeparators
()[C:\dev\flex_201_gmc\sdk\frameworks\mx\controls\DataGrid.as:2896]
at
mx.controls::DataGrid/mx.controls:DataGrid::updateDisplayList()[C:\dev\f
lex_201_gmc\sdk\frameworks\mx\controls\DataGrid.as:1269]
at
mx.core::ScrollControlBase/mx.core:ScrollControlBase::setScrollBarProper
ties
()[C:\dev\flex_201_gmc\sdk\frameworks\mx\core\ScrollControlBase.as:1084]
at
mx.controls::DataGrid/mx.controls:DataGrid::configureScrollBars()[C:\dev
\flex_201_gmc\sdk\frameworks\mx\controls\DataGrid.as:1791]
at
mx.controls.listClasses::ListBase/mx.controls.listClasses:ListBase::upda
teDisplayList()[C:\dev\flex_201_gmc\sdk\frameworks\mx\controls\listClass
es\ListBase.as:2972]
at mx.controls::DataGrid/mx.controls:DataGrid::updateDisplayList
()[C:\dev\flex_201_gmc\sdk\frameworks\mx\controls\DataGrid.as:1208]
at
mx.core::UIComponent/validateDisplayList()[C:\dev\flex_201_gmc\sdk\frame
works\mx\core\UIComponent.as:5760]
at
mx.managers::LayoutManager/mx.managers:LayoutManager::validateDisplayLis
t
()[C:\dev\flex_201_gmc\sdk\frameworks\mx\managers\LayoutManager.as:600]
at
mx.managers::LayoutManager/mx.managers:LayoutManager::doPhasedInstantiat

RE: [flexcoders] rpc: Flex sites not running under the URL

2007-10-20 Thread Alex Harui
Adding a keyword so the experts may notice

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of stephen50232
Sent: Saturday, October 20, 2007 8:32 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Flex sites not running under the URL

 

HI,

I've posted this message on the Adobe forum, but I thought I'd post it
here too, so sorry for the cross posting, anyway

I have recently been moving some Flex apps onto a new server, now the
problem I'm having is that any Flex app that uses Remoting is only
available via the IP address. When I call the site via the URL I
create in IIS i always get this error message:

mx.rpc::Fault)#0
errorID = 0
faultCode = Server.Processing
faultDetail = (null)
faultString = java.lang.NullPointerException
message = faultCode:Server.Processing
faultString:'java.lang.NullPointerException' faultDetail:'null'
name = Error
rootCause = (null)

Now when I call the same site via the IP address I don't get an error
message and the site works. I've been researching this problem and
asked other people about this and it seems that the problem has to do
with the service-config.xml file, so I've checked my
service-config.xml file and the endpoint entries are fine, e.g:

endpoint
uri=http://{server.name}:{server.port}{context.root}/flex2gateway/cfamf
polling
class=flex.messaging.endpoints.AMFEndpoint/

Which seems fine, I've also put a crossdomain policy file in the root
of my app and that's not fixing the problem. So I'm stuck for ideas.

Can anyone shed so light and ideas and what to check to solve this
problem?

Thanks

Stephen

 



[flexcoders] Re: Flex is becoming unviable

2007-10-20 Thread dbronk
Well, in the AJAX apps I've written, even the first downloads were
rarely more than 200k, normal  150k.  After that, every request was
around 2k-10k.

But again, I think this is comparing apples and oranges, there are
pluses and minuses for both.  I personally think that Flex is the way
to go.  I just wanted to put my 2 cents in with my opinion that I
believe this is one of the top 3 issues that they need to fix.  Search
engine optimization is another big one as well as well as putting
development features into FlexBuilder that developers have come to
expect as basic features.

But, I didn't want to make this an AJAX vs Flex so sorry I brought it up.

In one of the reply posts it was stated that the browser can cache the
SWF.  How is this done?  I take a server hit every time I come back to
my app.  I can be in my app, jump over to google, come back to my app
all in the same browser session and it will reload from server every
time.  It would help tremendously if you could advise me on how to
make the SWF cache in the browser.

Thanks,
Dale

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

 dbronk wrote:
  
  So how do I make my browser cache the swf? Every time I navigate to
  my app, the swf loads from the server.
  
  As far as comparing html sites with using modules, I think it is very
  tough to compare such different techologies. But, with the modules I
  have to wait for another xK bytes module to load which means not a
  smooth transition. If I was simply doing an html site, we would never
  go back to the server for such large chunks of data. Using AJAX I
  would be able to grab much smaller amounts of data 
 
   How is that different than a Flex app?  How does the size of a Flex 
 swf compare to the initial download of an AJAX one?
 
   I thought this was one of the selling points of RIAs, either with Flex
 or AJAX was that after the initial download, you end up using less 
 bandwidth.  Download the application once, and then just pass data back 
 and forth.
 
   I know that my Blockbuster on-line queue is unusable with 250 movies 
 in  it.  But, I've built similar type functionality into Flex apps and 
 it is pretty snappy.
 
 
 -- 
 Jeffry Houser, Technical Entrepreneur, Software Developer, Author, 
 Recording Engineer
 AIM: Reboog711  | Phone: 1-203-379-0773
 --
 My Company: http://www.dot-com-it.com
 My Podcast: http://www.theflexshow.com
 My Blog: http://www.jeffryhouser.com





Re: [flexcoders] AdvancedDataGrid and setItemAt()

2007-10-20 Thread Paul Dale
The selectedIndex is the index of the row in the visual object, which might
not be the same as the index of the item in the data provider. You can use
data.setItemAt(adg.selectedItem,data.indexOf(adg.selectedItem)).


On 10/19/07, monkeeeh [EMAIL PROTECTED] wrote:

   Hi everybody!

 I have big problems with ADG. I'm trying to edit ADG data. I have
 titlewindow and when i close it i want to update data to ADG.

 simple example:
 data.setItemAt(adg.selectedItem, adg.selectedIndex);

 this should just update selected row with same data. if i select first
 row (from first group) it update that row move it to end of group and
 update second row (what is actually first one because that first moves
 to the end).

 Could someone show me how to change data in ADG? Please!

 Thanks!

  



[flexcoders] how to intelligently change datagrid.height dynamically to adjust its rowCount

2007-10-20 Thread abhi.sanoujam
Hi Guys,

How can we can adjust the height of a datagrid dynamically so that it
displays a user-specified number of rows??

e.g. If the dataProvider contains 100 elements and I want to adjust
the height so that it displays me only 20 rows at a time (with
scrollbars), how can i do it ?? Also if the number of rows
(dataprovider.source.length) is less than 20 (the user specified
number), the height of the datagrid is adjusted so that it takes up
space for only those many rows (which is less than 20).

Thanks for your help in advance!!!



RE: [flexcoders] Re: Flex is becoming unviable

2007-10-20 Thread Alex Harui
It will only get cached when served over http:  FBB serves it via the
file system

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of dbronk
Sent: Saturday, October 20, 2007 2:42 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] Re: Flex is becoming unviable

 

Well, in the AJAX apps I've written, even the first downloads were
rarely more than 200k, normal  150k. After that, every request was
around 2k-10k.

But again, I think this is comparing apples and oranges, there are
pluses and minuses for both. I personally think that Flex is the way
to go. I just wanted to put my 2 cents in with my opinion that I
believe this is one of the top 3 issues that they need to fix. Search
engine optimization is another big one as well as well as putting
development features into FlexBuilder that developers have come to
expect as basic features.

But, I didn't want to make this an AJAX vs Flex so sorry I brought it
up.

In one of the reply posts it was stated that the browser can cache the
SWF. How is this done? I take a server hit every time I come back to
my app. I can be in my app, jump over to google, come back to my app
all in the same browser session and it will reload from server every
time. It would help tremendously if you could advise me on how to
make the SWF cache in the browser.

Thanks,
Dale

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

 dbronk wrote:
  
  So how do I make my browser cache the swf? Every time I navigate to
  my app, the swf loads from the server.
  
  As far as comparing html sites with using modules, I think it is
very
  tough to compare such different techologies. But, with the modules I
  have to wait for another xK bytes module to load which means not a
  smooth transition. If I was simply doing an html site, we would
never
  go back to the server for such large chunks of data. Using AJAX I
  would be able to grab much smaller amounts of data 
 
 How is that different than a Flex app? How does the size of a Flex 
 swf compare to the initial download of an AJAX one?
 
 I thought this was one of the selling points of RIAs, either with Flex
 or AJAX was that after the initial download, you end up using less 
 bandwidth. Download the application once, and then just pass data back

 and forth.
 
 I know that my Blockbuster on-line queue is unusable with 250 movies 
 in it. But, I've built similar type functionality into Flex apps and 
 it is pretty snappy.
 
 
 -- 
 Jeffry Houser, Technical Entrepreneur, Software Developer, Author, 
 Recording Engineer
 AIM: Reboog711 | Phone: 1-203-379-0773
 --
 My Company: http://www.dot-com-it.com http://www.dot-com-it.com 
 My Podcast: http://www.theflexshow.com http://www.theflexshow.com 
 My Blog: http://www.jeffryhouser.com http://www.jeffryhouser.com 


 



RE: [flexcoders] how to intelligently change datagrid.height dynamically to adjust its rowCount

2007-10-20 Thread Alex Harui
Assuming variableRowHeight=false:

 

ar numRows:int = Math.min(dg.dataProvider.length, desiredNumberOfRows);

dg.height = numRows * dg.rowHeight + dg.viewMetrics.top +
dg.viewMetrics.bottom;

 



From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of abhi.sanoujam
Sent: Saturday, October 20, 2007 4:30 PM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] how to intelligently change datagrid.height
dynamically to adjust its rowCount

 

Hi Guys,

How can we can adjust the height of a datagrid dynamically so that it
displays a user-specified number of rows??

e.g. If the dataProvider contains 100 elements and I want to adjust
the height so that it displays me only 20 rows at a time (with
scrollbars), how can i do it ?? Also if the number of rows
(dataprovider.source.length) is less than 20 (the user specified
number), the height of the datagrid is adjusted so that it takes up
space for only those many rows (which is less than 20).

Thanks for your help in advance!!!