[flexcoders] XML File size limit?
Is there a limit to the size that an XML file can be? I am working with some huge XML files, and one that I am working with 98938 Lines and is about 2 megs...for some reason, it seems like my app is not reading the file all the way through...any ideas?
[flexcoders] Re: save word file to database.
I'm not sure what the use case is, but I was faced with a similar issues recently...but with Flex, and ended up using Sribd. The service allows you to upload most doc types, not just word docs, and takes care of the your storage needs. Docs can be set to private if desired, so the public cant view it. Once in scribd, you can download the original doc again, retrieve a 'firt page' icon, and read the doc using their iPaper 'viewer', this would be easy in AIR using the HTML component. There's an actionscript API available(not great but the source is available, so you can extend), check out the developers page at scribd.com. Good luck --- In flexcoders@yahoogroups.com, Jeffry Houser j...@... wrote: Although possible to save binary docs in a database, I recommend against it. Save them on disk and put a pointer in the database. If you're adamant about storing the files in the database looking into the BLOB data type (Binary Large OBjects ). I imagine if you send it to the database That said, were you having any specific problems transferring a word doc back and forth? It's just bytes, so I doubt you'd need any encoder / decoder. Displaying a word doc in an AIR file would be an impressive treat if you can pull it off, though. markflex2007 wrote: Hi, I am doing a Air application and I need save a microsoft word file to database and I also need download the file back with AIR. I maybe need some encoder/decoder technology to do this.but I do not have idea about this. Would you please give me a idea about this. Thanks for your help Mark -- Jeffry Houser, Technical Entrepreneur Adobe Community Expert: http://tinyurl.com/684b5h http://www.twitter.com/reboog711 | Phone: 203-379-0773 -- Easy to use Interface Components for Flex Developers http://www.flextras.com?c=104 -- http://www.theflexshow.com http://www.jeffryhouser.com -- Part of the DotComIt Brain Trust
[flexcoders] how to call dynamic servlet
Hi All, i have made a servelt which returns details in xml format , this is servlet is working fine if am calling it from flex in static way like this mx:HTTPService id=topSenders useProxy=false resultFormat=xml method=POST url=http://localhost:8080/Application/topSenderServlet?TYPE=4amp;USER_ID=12; result=serv_result(event);/ but if i tried to call the servlet like this mx:HTTPService id=topSenders useProxy=false resultFormat=xml method=POST url={servletURL} result=serv_result(event);/ then it is not working , am not getting any error here is the full code for my mxml file ?xml version=1.0 encoding=utf-8? mx:Application xmlns:mx=http://www.adobe.com/2006/mxml; layout=absolute creationComplete=init() mx:Script ![CDATA[ import flash.net.sendToURL; import mx.controls.Alert; import mx.rpc.events.FaultEvent; import mx.rpc.events.ResultEvent; import mx.rpc.xml.SimpleXMLDecoder; import mx.controls.Button; import mx.controls.Label; import mx.collections.ArrayCollection; [Bindable] public var expenses:ArrayCollection; [Bindable] public var userId:int; [Bindable] public var servletURL:String; private function init():void{ userId = 12; servletURL=http://localhost:8080/Application/topSenderServlet?TYPE=4amp;USER_ID=+userId; Alert.show(servletURL); topSenders.send(); } private function serv_result(evt:ResultEvent):void { /* Convert XMLNode to XMLDocument. */ var xmlStr:String = evt.result.toString(); var xmlDoc:XMLDocument = new XMLDocument(xmlStr); var decoder:SimpleXMLDecoder = new SimpleXMLDecoder(true); var resultObj:Object = decoder.decodeXML(xmlDoc); /* Assign the values... */ expenses = new ArrayCollection(); for(var i:int=0;iresultObj.top.sender.length;i++){ Alert.show(resultObj.top.sender[i].phone); } } ]] /mx:Script !--mx:HTTPService id=topSenders useProxy=false resultFormat=xml method=POST url=http://localhost:8080/Application/topSenderServlet?TYPE=4amp;USER_ID=12; result=serv_result(event);/-- mx:HTTPService id=topSenders useProxy=false resultFormat=xml method=POST url={servletURL} result=serv_result(event);/ /mx:Application thanking you in advance
[flexcoders] Re: Flex Builder 3 on Windows XP
I tried that, but when I run the utility Flex does not show up, since I believe it was uninstalled successfully. Thanks! --- In flexcoders@yahoogroups.com, oneworld95 oneworl...@... wrote: Try using the Microsoft Windows Installer CleanUp Utility (http://support.microsoft.com/kb/290301). I've had great luck with that tool. You might also need a registry cleanup tool. I don't know of any good free ones. Maybe someone else can post a reply on that. - Alex C --- In flexcoders@yahoogroups.com, hsam949 hsalama00@ wrote: I have a weird problem. My PC crashed yesterday and after re-booting Flex builder would not start. When clicking on the icon, you get the initial Flex screen but then it disappeared and nothing happens. After struggling for a couple of hours, I decided to uninstall and reinstall Flex. Now when I run the installer, InstallAnyWhere gets to about 43% and stalls, then jumps to 99% and then asks for another location to extract the installer. When you specify a different location, the same thing happens all over again. This is the same installation file I used before, so I know it is not corrupt. Also, when I checked my registry, there is not entry for Flex under Adobe in HKEY_LOCAL_MACHINE -- Software. Any help is appreciated. Thanks!
[flexcoders] Re: DataGrid ItemRenderers and display text highlighted search text.
--- In flexcoders@yahoogroups.com, Todd tpreka...@... wrote: Hello All (probably one for Alex H), I know I've seen this implemented before somewhere around the web, but I've search for awhile and can't find it. I have a custom DataGrid that I've subclassed and do lots of trick functionality on it. I pass it a search string, and only the rows that contain that search string are displayed. This should be handled by the ListCollection that you're using as a dataProvider. Now, what I'd like to do is to customize the ItemRenderers so that the portion of text in any ItemRenderer that matches the search string is displayed in a different color and underlined. I know I've seen a demo of this somewhere? Any ideas? Or, any ideas how to implement? Maybe this is the demo you are thinking of: http://flexdiary.blogspot.com/2008/09/extended-datagrid-with-stylefunction.html
[flexcoders] dragdrop inside itemEditor in dataGrid...a tricky question
Hello all I'd really appreciate your help on this. I have a itemEditor in my datagrid (see attached code).. this is a dragdrop text input... I drag words inside and it concatenates them to a comma separated string... I've embedded it in the grid like that: mx:DataGridColumn headerText=Prevent ctx dataField=@prevent_ctxs rendererIsEditor=true width=200 itemRenderer=CtxTI editable=true/ The problem is that the grid does not sense the itemBegin/itemEnd events when I drag things inside.. and therefore does not activate the editor/automatically pull the data of the itemEditor and puts it into the grid.. Can anyone figure a way to correct/around this? Thanks in advance Afik Gal == CtxTI.mxml === ?xml version=1.0 encoding=utf-8? mx:TextInput xmlns:mx=http://www.adobe.com/2006/mxml; dragDrop=dragDrop(event) dragEnter=dragAccept(event) mx:Script ![CDATA[ import mx.events.DragEvent; import mx.managers.DragManager; import mx.controls.listClasses.ListData; import mx.controls.dataGridClasses.DataGridListData; import mx.controls.listClasses.BaseListData; override public function set data(value:Object):void { super.data=value; var attrib:String= DataGridListData(listData).dataField.substr(1,-1+DataGridListData(listData).dataField.length); var input:String; if (value) input=XML(value).attribute(attrib)[0].toString(); if (input!=) this.text=input; } private function dragAccept(event:DragEvent):void { var dropTarget:TextInput = event.currentTarget as TextInput; DragManager.acceptDragDrop(dropTarget); } private function dragDrop(event:DragEvent):void { if (!event.dragSource.hasFormat(treeItems)) return; var arr:Array = event.dragSource.dataForFormat(treeItems) as Array; var str:String = XML(arr[0])@label.tostring(); if ((this.text.substr(-1)!=,) (this.text.length0)) this.text+=,; this.text+=str+,; } ]] /mx:Script /mx:TextInput
[flexcoders] Re: Lazy loading in AdvancedDataGrid using RemoteObject
--- In flexcoders@yahoogroups.com, yossi.baram yossi.ba...@... wrote: one more thing, AdvancedDataGrid doesnt support DataDescriptor... Yes. You asked about general approaches and pointers in the right direction. I showed you an example that will take you part of the way there. The rest of it is up to you :)
RE: [flexcoders] how to call dynamic servlet
That should work, I use dynamic urls with HTTPService regularly. One suggestion, don't use binding. Instead, in the function where you invoke service.send(), set the url there. Additionally, unless you have a very special use case, you do not want resultFormat=xml, you want resultFormat=e4x. xml is the old AS object, and lacks most of the functionality available in e4x. _ From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of anitha2324 Sent: Saturday, March 07, 2009 2:35 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] how to call dynamic servlet Hi All, i have made a servelt which returns details in xml format , this is servlet is working fine if am calling it from flex in static way like this mx:HTTPService id=topSenders useProxy=false resultFormat=xml method=POST url=http://localhost: http://localhost:8080/Application/topSenderServlet?TYPE=4amp;USER_ID=12 8080/Application/topSenderServlet?TYPE=4amp;USER_ID=12 result=serv_result(event);/ but if i tried to call the servlet like this mx:HTTPService id=topSenders useProxy=false resultFormat=xml method=POST url={servletURL} result=serv_result(event);/ then it is not working , am not getting any error here is the full code for my mxml file ?xml version=1.0 encoding=utf-8? mx:Application xmlns:mx=http://www.adobe. http://www.adobe.com/2006/mxml com/2006/mxml layout=absolute creationComplete=init() mx:Script ![CDATA[ import flash.net.sendToURL; import mx.controls.Alert; import mx.rpc.events.FaultEvent; import mx.rpc.events.ResultEvent; import mx.rpc.xml.SimpleXMLDecoder; import mx.controls.Button; import mx.controls.Label; import mx.collections.ArrayCollection; [Bindable] public var expenses:ArrayCollection; [Bindable] public var userId:int; [Bindable] public var servletURL:String; private function init():void{ userId = 12; servletURL=http://localhost: http://localhost:8080/Application/topSenderServlet?TYPE=4amp;USER_ID= 8080/Application/topSenderServlet?TYPE=4amp;USER_ID=+userId; Alert.show(servletURL); topSenders.send(); } private function serv_result(evt:ResultEvent):void { /* Convert XMLNode to XMLDocument. */ var xmlStr:String = evt.result.toString(); var xmlDoc:XMLDocument = new XMLDocument(xmlStr); var decoder:SimpleXMLDecoder = new SimpleXMLDecoder(true); var resultObj:Object = decoder.decodeXML(xmlDoc); /* Assign the values... */ expenses = new ArrayCollection(); for(var i:int=0;iresultObj.top.sender.length;i++){ Alert.show(resultObj.top.sender[i].phone); } } ]] /mx:Script !--mx:HTTPService id=topSenders useProxy=false resultFormat=xml method=POST url=http://localhost: http://localhost:8080/Application/topSenderServlet?TYPE=4amp;USER_ID=12 8080/Application/topSenderServlet?TYPE=4amp;USER_ID=12 result=serv_result(event);/-- mx:HTTPService id=topSenders useProxy=false resultFormat=xml method=POST url={servletURL} result=serv_result(event);/ /mx:Application thanking you in advance
Re: [flexcoders] Is there a way to detect mouse button state without tracking events?
This is a very urgent issue for us. =( Any help is deeply appreciated! On Thu, Mar 5, 2009 at 5:14 PM, Dave Kong davek...@gmail.com wrote: I need to find out at this particular moment, if the mouse button is up or down. Trying to work around the issue with wmode=transparent in FF. If I scroll a list, and drags cursor outside of the player and then releases the button. That mouseUp event is never captured by Flash Player, so when I move mouse cursor back, buttonDown is always true for all mouse events. So I need a workaround on moues re-entry to detect if button is truly down, if not, call the scrollThumb's releaseButton function so it won't keep on scrolling. Thanks!
RE: [flexcoders] dragdrop inside itemEditor in dataGrid...a tricky question
For a renderer of that complexity, I would not use the DGs native editable process, but would handle the dataProvider item updates within the renderer itself. Tracy _ From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Gal Afik Sent: Saturday, March 07, 2009 10:42 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] dragdrop inside itemEditor in dataGrid...a tricky question Hello all I'd really appreciate your help on this. I have a itemEditor in my datagrid (see attached code).. this is a dragdrop text input... I drag words inside and it concatenates them to a comma separated string... I've embedded it in the grid like that: mx:DataGridColumn headerText=Prevent ctx dataField=@prevent_ctxs rendererIsEditor=true width=200 itemRenderer=CtxTI editable=true/ The problem is that the grid does not sense the itemBegin/itemEnd events when I drag things inside.. and therefore does not activate the editor/automatically pull the data of the itemEditor and puts it into the grid.. Can anyone figure a way to correct/around this? Thanks in advance Afik Gal == CtxTI.mxml === ?xml version=1.0 encoding=utf-8? mx:TextInput xmlns:mx=http://www.adobe. http://www.adobe.com/2006/mxml com/2006/mxml dragDrop=dragDrop(event) dragEnter=dragAccept(event) mx:Script ![CDATA[ import mx.events.DragEvent; import mx.managers.DragManager; import mx.controls.listClasses.ListData; import mx.controls.dataGridClasses.DataGridListData; import mx.controls.listClasses.BaseListData; override public function set data(value:Object):void { super.data=value; var attrib:String= DataGridListData(listData).dataField.substr(1,-1+DataGridListData(listData). dataField.length); var input:String; if (value) input=XML(value).attribute(attrib)[0].toString(); if (input!=) this.text=input; } private function dragAccept(event:DragEvent):void { var dropTarget:TextInput = event.currentTarget as TextInput; DragManager.acceptDragDrop(dropTarget); } private function dragDrop(event:DragEvent):void { if (!event.dragSource.hasFormat(treeItems)) return; var arr:Array = event.dragSource.dataForFormat(treeItems) as Array; var str:String = XML(arr[0])@label.tostring(); if ((this.text.substr(-1)!=,) (this.text.length0)) this.text+=,; this.text+=str+,; } ]] /mx:Script /mx:TextInput
[flexcoders] truncateToFit or multiline title in TitleWindow
Hi, I know this may not as easy as it sounds but does Flex provide out-of-the-shelf solutions for me to truncate the text in the title bar of my TitleWindow component? By out-of-the-shelf I mean things like setting properties, CSS, etc, without writing my own custom component? Thanks.
[flexcoders] What's the trick to subclassing DataGrid?
I have a class that extends DataGrid but it has some problems in Flex Builder design mode. When you drag DataGrid from the Components palette to the design area it defaults to a 3 column DG. When I drag my component it comes up as a blank DG, that is, no predefined columns. I tried to tweak my design.xml to replicate the framework's DG entry, but that did not work. I believe I'd have to crate my own plugin/extension to get that to work eh! TIA julio
[flexcoders] DataGrid extension does not render in FB3, why?
Hi, I have subclassed DataGridColumn but it fails to render in FB3 design mode. Everything works nice and dandy, it compiles and runs as expected. But if I use my DGC in a DataGrid nothing shows up in FB3 in design mode. Say I have a DG as: mx:DG mx:columns mx:DGC/ mx:DGC/ my:myDGC/ mxDGC/ /mx:columns /mx:DG Only columns 1,2,4 show up in design mode on FB3. I tried to look into the framework's design.xml but found nothing related to DGC. And nothing in DG or DGC source seems to indicate any code that' specific to FB3 design rendering. Any lead would be greatly appreciated. TIA julio
RE: [flexcoders] truncateToFit or multiline title in TitleWindow
Nope. You'll have to subclass and decide when to call truncateToFit on titleTextField. Alex Harui Flex SDK Developer Adobe Systems Inc.http://www.adobe.com/ Blog: http://blogs.adobe.com/aharui From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of gwangdesign Sent: Saturday, March 07, 2009 9:52 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] truncateToFit or multiline title in TitleWindow Hi, I know this may not as easy as it sounds but does Flex provide out-of-the-shelf solutions for me to truncate the text in the title bar of my TitleWindow component? By out-of-the-shelf I mean things like setting properties, CSS, etc, without writing my own custom component? Thanks.
RE: [flexcoders] XML File size limit?
The limit should be way more than 2mb. The limits are imposed by the amount of memory available, and the time required to process the XML.. Alex Harui Flex SDK Developer Adobe Systems Inc.http://www.adobe.com/ Blog: http://blogs.adobe.com/aharui From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Parkash Sent: Saturday, March 07, 2009 3:59 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] XML File size limit? Is there a limit to the size that an XML file can be? I am working with some huge XML files, and one that I am working with 98938 Lines and is about 2 megs...for some reason, it seems like my app is not reading the file all the way through...any ideas? __ Information from ESET Smart Security, version of virus signature database 3916 (20090307) __ The message was checked by ESET Smart Security. http://www.eset.com
[flexcoders] Any existing help systems for generating help for end users
Anyone know of systems for generating help within a flex application? I tried searching for previous posts but help and system are such generic terms I got a huge number of matches that were about developer help.
Re: [flexcoders] Re: Flex Builder 3 on Windows XP
As far as I know, FB3 doesn't use Windows Installer, so that utility probably won't help. InstallAnywhere is written is Java, so maybe its worth reinstalling Java to see if that'll help? 2009/3/7 hsam949 hsalam...@ccny.cuny.edu: I tried that, but when I run the utility Flex does not show up, since I believe it was uninstalled successfully. Thanks! --- In flexcoders@yahoogroups.com, oneworld95 oneworl...@... wrote: Try using the Microsoft Windows Installer CleanUp Utility (http://support.microsoft.com/kb/290301). I've had great luck with that tool. You might also need a registry cleanup tool. I don't know of any good free ones. Maybe someone else can post a reply on that. - Alex C --- In flexcoders@yahoogroups.com, hsam949 hsalama00@ wrote: I have a weird problem. My PC crashed yesterday and after re-booting Flex builder would not start. When clicking on the icon, you get the initial Flex screen but then it disappeared and nothing happens. After struggling for a couple of hours, I decided to uninstall and reinstall Flex. Now when I run the installer, InstallAnyWhere gets to about 43% and stalls, then jumps to 99% and then asks for another location to extract the installer. When you specify a different location, the same thing happens all over again. This is the same installation file I used before, so I know it is not corrupt. Also, when I checked my registry, there is not entry for Flex under Adobe in HKEY_LOCAL_MACHINE -- Software. Any help is appreciated. Thanks! -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Alternative FAQ location: https://share.acrobat.com/adc/document.do?docid=942dbdc8-e469-446f-b4cf-1e62079f6847 Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.comYahoo! Groups Links
[flexcoders] dataGrid not receiving user input (intermitently) in bottom right
I have a datagrid that works ~50% of the time. The other 50% of the time the dataGrid wont accept user interaction in the bottom right area (the bottom 3 (of 6) rows, right 2 (of 4) columns). i.e. that part of the grid does not react to mouse over events, not mouse click events. Sometimes is reacts to click events as if they are occurring in the row in which a mouse_over interaction was last observed. Looking at the redraw regions, I see that a redraw region occasionally appears in the bottom right of the grid - exactly where he grid is not receiving user input. So that is probably related. But I don't know what it is a redraw region for. I've checked my other component and they aren't near. I have the following custom item renderers: column 2: extends Canvas column 3: extends Label column 4: extends Label. Anyone know what might be causing this? Or how to fix it / diagnose it further? thanks tom
[flexcoders] Re: dragdrop inside itemEditor in dataGrid...a tricky question
Hmm... Thanks for the response...nice idea... but how do I access the right row in the dataprovider XMLListCollection? (rowIndex?) and if I choose this approach I simply turn the editor to renderer? Thanks Afik --- In flexcoders@yahoogroups.com, Tracy Spratt tspr...@... wrote: For a renderer of that complexity, I would not use the DGs native editable process, but would handle the dataProvider item updates within the renderer itself. Tracy _ From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Gal Afik Sent: Saturday, March 07, 2009 10:42 AM To: flexcoders@yahoogroups.com Subject: [flexcoders] dragdrop inside itemEditor in dataGrid...a tricky question Hello all I'd really appreciate your help on this. I have a itemEditor in my datagrid (see attached code).. this is a dragdrop text input... I drag words inside and it concatenates them to a comma separated string... I've embedded it in the grid like that: mx:DataGridColumn headerText=Prevent ctx dataField=@prevent_ctxs rendererIsEditor=true width=200 itemRenderer=CtxTI editable=true/ The problem is that the grid does not sense the itemBegin/itemEnd events when I drag things inside.. and therefore does not activate the editor/automatically pull the data of the itemEditor and puts it into the grid.. Can anyone figure a way to correct/around this? Thanks in advance Afik Gal == CtxTI.mxml === ?xml version=1.0 encoding=utf-8? mx:TextInput xmlns:mx=http://www.adobe. http://www.adobe.com/2006/mxml com/2006/mxml dragDrop=dragDrop(event) dragEnter=dragAccept(event) mx:Script ![CDATA[ import mx.events.DragEvent; import mx.managers.DragManager; import mx.controls.listClasses.ListData; import mx.controls.dataGridClasses.DataGridListData; import mx.controls.listClasses.BaseListData; override public function set data(value:Object):void { super.data=value; var attrib:String= DataGridListData(listData).dataField.substr(1,-1+DataGridListData(listData). dataField.length); var input:String; if (value) input=XML(value).attribute(attrib)[0].toString(); if (input!=) this.text=input; } private function dragAccept(event:DragEvent):void { var dropTarget:TextInput = event.currentTarget as TextInput; DragManager.acceptDragDrop(dropTarget); } private function dragDrop(event:DragEvent):void { if (!event.dragSource.hasFormat(treeItems)) return; var arr:Array = event.dragSource.dataForFormat(treeItems) as Array; var str:String = XML(arr[0])@label.tostring(); if ((this.text.substr(-1)!=,) (this.text.length0)) this.text+=,; this.text+=str+,; } ]] /mx:Script /mx:TextInput
[flexcoders] mxmlc rsl
Hi, I'm trying to compile a flex app using the flex 4 sdk's mxmlc. I'm using a custom swc as an rsl. While I can get everything to compile just fine, running the swf gives me a VerifyError 1014 Class ... not found. Here's what I'm using on the command line: mxmlc -load-config=../../../flash/flex_sdk_4.0.0.5201/frameworks/flex-config.xml -rslp=flare.swc,flare.swf -static-rsls=false -- SwcTest.as And this is the error I get from the debug player running locally: VerifyError: Error #1014: Class flare.animate::Tween could not be found. at SwcTest() Can anyone give me advice on what could be wrong? I'm at a loss. I've also tried the runtime-shared-library-path tag in a config file without any difference. If it helps I'm also running on the mac. Thanks. -Don Q.
RE: [flexcoders] dataGrid not receiving user input (intermitently) in bottom right
If you are pretty sure there is not something invisible covering that area, try cleaning the project. Tracy _ From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of tom s Sent: Saturday, March 07, 2009 6:31 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] dataGrid not receiving user input (intermitently) in bottom right I have a datagrid that works ~50% of the time. The other 50% of the time the dataGrid wont accept user interaction in the bottom right area (the bottom 3 (of 6) rows, right 2 (of 4) columns). i.e. that part of the grid does not react to mouse over events, not mouse click events. Sometimes is reacts to click events as if they are occurring in the row in which a mouse_over interaction was last observed. Looking at the redraw regions, I see that a redraw region occasionally appears in the bottom right of the grid - exactly where he grid is not receiving user input. So that is probably related. But I don't know what it is a redraw region for. I've checked my other component and they aren't near. I have the following custom item renderers: column 2: extends Canvas column 3: extends Label column 4: extends Label. Anyone know what might be causing this? Or how to fix it / diagnose it further? thanks tom
RE: [flexcoders] Re: dragdrop inside itemEditor in dataGrid...a tricky question
Yes, leave off renderIseditor=true. Your renderer will know which item it is currently associated with, since that reference gets passed into the renderer any time the underlying data changes in the set data() function. Further, if the renderer implements the IDropInListItemrrenderer interface, you will als have access to the listData and thus dataProvider, should you need to get the itemIndex using getItemIndex. _ From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Gal Afik Sent: Saturday, March 07, 2009 12:48 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: dragdrop inside itemEditor in dataGrid...a tricky question Hmm... Thanks for the response...nice idea... but how do I access the right row in the dataprovider XMLListCollection? (rowIndex?) and if I choose this approach I simply turn the editor to renderer? Thanks Afik --- In flexcod...@yahoogro mailto:flexcoders%40yahoogroups.com ups.com, Tracy Spratt tspr...@... wrote: For a renderer of that complexity, I would not use the DGs native editable process, but would handle the dataProvider item updates within the renderer itself. Tracy _ From: flexcod...@yahoogro mailto:flexcoders%40yahoogroups.com ups.com [mailto:flexcod...@yahoogro mailto:flexcoders%40yahoogroups.com ups.com] On Behalf Of Gal Afik Sent: Saturday, March 07, 2009 10:42 AM To: flexcod...@yahoogro mailto:flexcoders%40yahoogroups.com ups.com Subject: [flexcoders] dragdrop inside itemEditor in dataGrid...a tricky question Hello all I'd really appreciate your help on this. I have a itemEditor in my datagrid (see attached code).. this is a dragdrop text input... I drag words inside and it concatenates them to a comma separated string... I've embedded it in the grid like that: mx:DataGridColumn headerText=Prevent ctx dataField=@prevent_ctxs rendererIsEditor=true width=200 itemRenderer=CtxTI editable=true/ The problem is that the grid does not sense the itemBegin/itemEnd events when I drag things inside.. and therefore does not activate the editor/automatically pull the data of the itemEditor and puts it into the grid.. Can anyone figure a way to correct/around this? Thanks in advance Afik Gal == CtxTI.mxml === ?xml version=1.0 encoding=utf-8? mx:TextInput xmlns:mx=http://www.adobe. http://www.adobe. http://www.adobe.com/2006/mxml com/2006/mxml com/2006/mxml dragDrop=dragDrop(event) dragEnter=dragAccept(event) mx:Script ![CDATA[ import mx.events.DragEvent; import mx.managers.DragManager; import mx.controls.listClasses.ListData; import mx.controls.dataGridClasses.DataGridListData; import mx.controls.listClasses.BaseListData; override public function set data(value:Object):void { super.data=value; var attrib:String= DataGridListData(listData).dataField.substr(1,-1+DataGridListData(listData). dataField.length); var input:String; if (value) input=XML(value).attribute(attrib)[0].toString(); if (input!=) this.text=input; } private function dragAccept(event:DragEvent):void { var dropTarget:TextInput = event.currentTarget as TextInput; DragManager.acceptDragDrop(dropTarget); } private function dragDrop(event:DragEvent):void { if (!event.dragSource.hasFormat(treeItems)) return; var arr:Array = event.dragSource.dataForFormat(treeItems) as Array; var str:String = XML(arr[0])@label.tostring(); if ((this.text.substr(-1)!=,) (this.text.length0)) this.text+=,; this.text+=str+,; } ]] /mx:Script /mx:TextInput
[flexcoders] Re: dataGrid not receiving user input (intermitently) in bottom right
Has to be another object on top of the DataGrid. The redraw region is the clue. Look at the other objects in the same class as the DataGrid. -TH --- In flexcoders@yahoogroups.com, Tracy Spratt tspr...@... wrote: If you are pretty sure there is not something invisible covering that area, try cleaning the project. Tracy _ From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of tom s Sent: Saturday, March 07, 2009 6:31 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] dataGrid not receiving user input (intermitently) in bottom right I have a datagrid that works ~50% of the time. The other 50% of the time the dataGrid wont accept user interaction in the bottom right area (the bottom 3 (of 6) rows, right 2 (of 4) columns). i.e. that part of the grid does not react to mouse over events, not mouse click events. Sometimes is reacts to click events as if they are occurring in the row in which a mouse_over interaction was last observed. Looking at the redraw regions, I see that a redraw region occasionally appears in the bottom right of the grid - exactly where he grid is not receiving user input. So that is probably related. But I don't know what it is a redraw region for. I've checked my other component and they aren't near. I have the following custom item renderers: column 2: extends Canvas column 3: extends Label column 4: extends Label. Anyone know what might be causing this? Or how to fix it / diagnose it further? thanks tom
[flexcoders] Re: dragdrop inside itemEditor in dataGrid...a tricky question
Don't forget about listData.rowIndex as well. -TH --- In flexcoders@yahoogroups.com, Tracy Spratt tspr...@... wrote: Yes, leave off renderIseditor=true. Your renderer will know which item it is currently associated with, since that reference gets passed into the renderer any time the underlying data changes in the set data() function. Further, if the renderer implements the IDropInListItemrrenderer interface, you will als have access to the listData and thus dataProvider, should you need to get the itemIndex using getItemIndex. _ From: flexcoders@yahoogroups.com [mailto:flexcod...@yahoogroups.com] On Behalf Of Gal Afik Sent: Saturday, March 07, 2009 12:48 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Re: dragdrop inside itemEditor in dataGrid...a tricky question Hmm... Thanks for the response...nice idea... but how do I access the right row in the dataprovider XMLListCollection? (rowIndex?) and if I choose this approach I simply turn the editor to renderer? Thanks Afik --- In flexcod...@yahoogro mailto:flexcoders%40yahoogroups.com ups.com, Tracy Spratt tspratt@ wrote: For a renderer of that complexity, I would not use the DGs native editable process, but would handle the dataProvider item updates within the renderer itself. Tracy _ From: flexcod...@yahoogro mailto:flexcoders%40yahoogroups.com ups.com [mailto:flexcod...@yahoogro mailto:flexcoders%40yahoogroups.com ups.com] On Behalf Of Gal Afik Sent: Saturday, March 07, 2009 10:42 AM To: flexcod...@yahoogro mailto:flexcoders%40yahoogroups.com ups.com Subject: [flexcoders] dragdrop inside itemEditor in dataGrid...a tricky question Hello all I'd really appreciate your help on this. I have a itemEditor in my datagrid (see attached code).. this is a dragdrop text input... I drag words inside and it concatenates them to a comma separated string... I've embedded it in the grid like that: mx:DataGridColumn headerText=Prevent ctx dataField=@prevent_ctxs rendererIsEditor=true width=200 itemRenderer=CtxTI editable=true/ The problem is that the grid does not sense the itemBegin/itemEnd events when I drag things inside.. and therefore does not activate the editor/automatically pull the data of the itemEditor and puts it into the grid.. Can anyone figure a way to correct/around this? Thanks in advance Afik Gal == CtxTI.mxml === ?xml version=1.0 encoding=utf-8? mx:TextInput xmlns:mx=http://www.adobe. http://www.adobe. http://www.adobe.com/2006/mxml com/2006/mxml com/2006/mxml dragDrop=dragDrop(event) dragEnter=dragAccept(event) mx:Script ![CDATA[ import mx.events.DragEvent; import mx.managers.DragManager; import mx.controls.listClasses.ListData; import mx.controls.dataGridClasses.DataGridListData; import mx.controls.listClasses.BaseListData; override public function set data(value:Object):void { super.data=value; var attrib:String= DataGridListData(listData).dataField.substr(1,-1+DataGridListData(listDa\ ta). dataField.length); var input:String; if (value) input=XML(value).attribute(attrib)[0].toString(); if (input!=) this.text=input; } private function dragAccept(event:DragEvent):void { var dropTarget:TextInput = event.currentTarget as TextInput; DragManager.acceptDragDrop(dropTarget); } private function dragDrop(event:DragEvent):void { if (!event.dragSource.hasFormat(treeItems)) return; var arr:Array = event.dragSource.dataForFormat(treeItems) as Array; var str:String = XML(arr[0])@label.tostring(); if ((this.text.substr(-1)!=,) (this.text.length0)) this.text+=,; this.text+=str+,; } ]] /mx:Script /mx:TextInput
[flexcoders] Re: Lazy loading in AdvancedDataGrid using RemoteObject
Thanks Amy for your help, I'm going your way:), only one question if i may, Is it possible to activate ItemRenderer on my columns after fetching childrens from my RemoteObject? How do I do that based on your example? I need to manipulate the data (override set data()) based on the various columns, the childrens data is not always plain value. Thanks again :) Jo --- In flexcoders@yahoogroups.com, Amy amyblankens...@... wrote: --- In flexcoders@yahoogroups.com, yossi.baram yossi.baram@ wrote: one more thing, AdvancedDataGrid doesnt support DataDescriptor... Yes. You asked about general approaches and pointers in the right direction. I showed you an example that will take you part of the way there. The rest of it is up to you :)