0 Replies Latest reply on Oct 10, 2009 1:20 PM by RedOctober57

    Need advice on layout

    RedOctober57 Level 1



      Using CF9 and FB4, I'm building an image catalog.  Data about the images is stored in a database (Firebird).  The images themselves are stored in files in my file system.  (M$ Windows XP Pro).  In an attempt to allow the user to control which images are displayed, my search function retrieves a list of image descriptions, text only, in a DataGrid, that occupies only the left half of the screen. (Forcing the user to wait until all 140 images download and display is not good).  The user can then select which images they want to see by "doing an action" (which I haven't decided yet, like clicking the DataGrid, double clicking the DataGrid, selecting then click a button, etc) then I want to display the image file and the associated image record, together, in a logical grouping, in another panel on the right hand side of the screen.  All the controls for finding image records, and displaying image descriptions, (IOW the Left side of the screen) is all done, and mostly working (except for the data bound tab labels which Adobe is working to fix as I type this).  It's the righ hand side of the screen that I have not begun yet.




      I'm at a loss as to where to begin.  Do I use a DataGrid?  If so, how to I display an image file which is not part of the table in the back end DB.  Do I make another custom column to hold the image then load the image?  If so, how do I load the image in the proper record?  (Code snippet please).  Also, how would you suggest I fetch the image record data from the DB? (One at a time via the unique record ID?) Ok, but how?  The only return types available from a CF function is String, Date, Number etc.... no "Image"  I would need to see the code for the CF Function as well as the ActionScript that would call it, in order to load the correct image into the correct record of... oh ya, that's my other question, what holds the data that the DataGrid on the right side of the screen (the one that displays images) uses as a dataProvider?  A temporary "in memory" table?  What would that be called?  Can a data grid display an image in a row?


      Maybe that's all too complicated.  Is there a smarter simpler "standard" way of doing this?  In all of the Flex 3 component demos, all the data for all the cool images in a grid type layout pattern was hard coded into the example.


      Do I have to build my own component?  If so, what "container" do I put them in, in FB4, that would allow them to be shown in a scrollable grid/grouping? (The user may select more images than can be displayed on the screen at one time)


      I don't want to waste a bunch of time experimenting.  I'm sure there must be a common, standard way of displaying images and associated data, in a "grid" type layout, based on user selection from another control.


      (Example:  Each time the user clicks on an item in the DataGrid that contains the image description, a new object (or record?) is created that displays the image on the right hand side of the screen.  The user may select one out of 20 descriptions, or more, or may select all.  In any case the user must be in control of which images get rendered on screen, so that they may control their "wait time")


      Thanks in advance for any help you can provide.