2 Replies Latest reply on Nov 14, 2007 11:31 AM by FlashForumName

    dynamic datagrid

    FlashForumName Level 1
      Hey all, I have a datagrid which I have generated all the columns dynamically. I've given them a datafield and they show up on my datagird just fine. The problem arises when I try to insert the data into this datagrid. I am receiving my data as one large string from php read out of a mysql database. Problem is, whenever I try to insert the parsed data into the columns, it views it as say one big object and puts the entire string into one cell or puts the first value across an entire row based upon what I do (since it's looking for an object and I'm actually working with a string).

      I know that you can usually use the dot notation with the column name to put in the value you want, for example, I have an id and date column and my datagrid's id is grid1. I know you can do something like this:

      grid1.id = whatever;
      grid1.date = whatever;

      and sure, that works perfectly but it's not dynamic because I had to actually type .id and .date in reference to the column names. So, what I am asking is is there some way to do that in a dynamic fashion? I'm really drawing a blank with how to get my data into that datagrid in the correct fasion. Thanks in advance