Hi All,
I'm using Telerik Grid and binded an XML through dataset. I've a autyo generate edit coulmn.
When I press edit, I get a text box with exisitng value and update, cancel button. After typing new value whren i press am not getting the new value in the grid. Can any one help on this. I'm using updatecommand event,but no use so far. Here is my code
Hashtable newValues = new Hashtable();
((GridEditableItem)e.Item).ExtractValues(newValues);
GridEditableItem editItem = (GridEditableItem)e.Item;
GridEditableItem editedItem = e.Item as GridEditableItem;
GridEditManager editMan = editedItem.EditManager;
var obj = editItem.GetDataKeyValue("ConnectionString");
//TextBox txt = e.Item.FindControl("txtValue") as TextBox;
//if (txt != null)
//{
// string s = txt.Text;
//}
ds.Tables["add"].Rows[editItem.DataSetIndex][1] = "XXXXX";
//radDisplay.DataSource = ds.Tables["add"];
radDisplay.Rebind();
StringWriter sw = new StringWriter();
ds.WriteXml(sw);
Session["decryptesXMLString"] = sw.ToString();
.RadComboBoxDropDown ul li, .rtsLI, .reEditorModes li, .rtLI, .rmItem, .rwControlButtons li
{
background-image: none;
}
.RadWindow TD
{
border: 0;
padding:0;
}
But this is a nuisance to have to add these fixes everytime I notice an issue. I would expect that all RAD controls would override all CSS values and I think this should be fixed.
protected
void
Page_Load(
object
sender, EventArgs e)
{
if
(!Page.IsPostBack)
{
GridBoundColumn boundColumn =
new
GridBoundColumn();
boundColumn.HeaderStyle.Width =
new
Unit(100, UnitType.Pixel);
boundColumn.ItemStyle.Width =
new
Unit(100, UnitType.Pixel);
boundColumn.ItemStyle.CssClass =
"noWrapEllipsis"
;
rgCool.MasterTableView.Columns.Add(boundColumn);
}
}
protected
void
rgv_ItemCreated(
object
sender, GridItemEventArgs e)
{
if
(e.Item
is
GridCommandItem)
{
Button btncmd = (e.Item
as
GridCommandItem).FindControl(
"ExportToExcelButton"
)
as
Button;
if
(btncmd !=
null
) { RadScriptManager.GetCurrent(
this
.Page).RegisterPostBackControl(btncmd); }
btncmd = (e.Item
as
GridCommandItem).FindControl(
"ExportToWordButton"
)
as
Button;
if
(btncmd !=
null
) { RadScriptManager.GetCurrent(
this
.Page).RegisterPostBackControl(btncmd); }
btncmd = (e.Item
as
GridCommandItem).FindControl(
"ExportToCsvButton"
)
as
Button;
if
(btncmd !=
null
) { RadScriptManager.GetCurrent(
this
.Page).RegisterPostBackControl(btncmd); }
}
}
<
telerik:RadScriptManager
id
=
"ScriptManager"
runat
=
"server"
EnablePageMethods
=
"false"
EnablePartialRendering
=
"true"
EnableScriptGlobalization
=
"false"
EnableScriptLocalization
=
"true"
ScriptMode
=
"Release"
/>