Well...I figured out a solution. It seems kinda clunky, but sometimes whatever gets the job done is the right way to do it.

Anyone interested in my solution can read on...

Through much scouring of the web, I discovered that if I bound my DataGrid to a DataSet component, it would magically allow me to edit the contents of the DataGrid. Being new to Flash/actionscript, I'm not sure if that is just "The Way it Works" or if I'm still missing something simple. I don't know why I would be allowed to edit the contents of the DataGrid when it is bound to an array, but not when it is bound to a recordset. Come to think of it, now that I've got one solution, I could probably have just converted the recordset into a two dimensional array and have been done with it. Bah! too easy (although probably faster and I may do it yet.) Anyhow, I digress. From there it was simply a matter of defining a DataSet schema dynamically, setting up my DataGrid columns to match the DataSet schema, and binding them to my data source and each other. Hmm...actually that sounds pretty easy now....why the #$% did it take me so long to figure that out? And why am I taking a mental diarrhea on the BBS? I guess as long as it only happens once in a blue moon it's ok...Now where was I? Oh...right defining the schema, etc...The only problem with doing it this way is that it requires another database query, which I'm trying to keep to a minimum because some of my end-users will most likely be serving up the data over a DSL or Cable connection. Oh well, it's already taken too much of my time, so they'll just have to deal. If there's anyone still reading at this point and still interested, here's the applicable code:

Code:

GradeBook.getColumns(getColumnsReply, SchoolID, TeacherID, ddCourse.value, ddQuarter.value);

var getColumnsReply = new Object();
getColumnsReply.onResult = function(result) {
spMain.content.centerGrid.removeAllColumns();
var myschema = "<properties>";
// Count backwards because otherwise the stupid DataGrid displays everything in reverse order....bleh!
for (var i=(result.length-1);i>=0; i--) {
spMain.content.centerGrid.columnNames[i] = result.items[i].TaskID;
myschema += "<property name=\"" + result.items[i].TaskID + "\"><type name=\"String\" original=\"false\">";
myschema += "<validation className=\"mx.data.types.Str\"><settings /></validation></type></property>";
}
myschema += "</properties>";
dataset1_ds.schema = new XML(myschema);
GradeBook.getGrades(getGradesReply, SchoolID, TeacherID, ddCourse.value, ddQuarter.value);
}

var getGradesReply = new Object();
getGradesReply.onResult = function(result) {
dataset1_ds.dataProvider = result;
spMain.content.centerGrid.dataProvider = dataset1_ds.dataProvider;
}


_________________________
~ John