Dear telerik team
My case is like this:
I have a table, which has column Author, Filename,
The table will be display in rad grid view.
Initially, the table is empty, when user click a button on the grid view, the rad upload control appear. then user can upload the file to a folder in server side and save the file name and author to table in back end.
The grid view will display the input from the table.
I have read some example such as :
http://demos.telerik.com/aspnet-ajax/controls/examples/integration/raduploadinajaxifiedgrid/defaultcs.aspx?product=upload
What confuse me in the above example is :
1 I can see the control radUpload in the apsx file;
2 in c# code,
How to get the "editor", if column is not a image column.
If you have a good example code, that is much better to help me.
Thanks a lot!
Qixiong
My case is like this:
I have a table, which has column Author, Filename,
The table will be display in rad grid view.
Initially, the table is empty, when user click a button on the grid view, the rad upload control appear. then user can upload the file to a folder in server side and save the file name and author to table in back end.
The grid view will display the input from the table.
I have read some example such as :
http://demos.telerik.com/aspnet-ajax/controls/examples/integration/raduploadinajaxifiedgrid/defaultcs.aspx?product=upload
What confuse me in the above example is :
1 I can see the control radUpload in the apsx file;
2 in c# code,
protected void RadGrid1_ItemCreated(object sender, GridItemEventArgs
e)
{
if
(e.Item is GridEditableItem && e.Item.IsInEditMode)
{
GridBinaryImageColumnEditor
editor =
((GridEditableItem)e.Item).EditManager.GetColumnEditor("Upload") as
GridBinaryImageColumnEditor;
TableCell cell =
(TableCell)editor.RadUploadControl.Parent;
CustomValidator
validator = new CustomValidator();
validator.ErrorMessage =
"Please select file to be uploaded";
validator.ClientValidationFunction
= "validateRadUpload";
validator.Display =
ValidatorDisplay.Dynamic;
cell.Controls.Add(validator);
}
}
How to get the "editor", if column is not a image column.
If you have a good example code, that is much better to help me.
Thanks a lot!
Qixiong