or
[NullReferenceException: Object reference not set to an instance of an object.]at the same time I get the model dialog that says the web.config registration is missing.
System.Web.Hosting.VirtualPathProvider.CombineVirtualPaths(VirtualPath basePath, VirtualPath relativePath) +11
System.Web.Hosting.VirtualPathProvider.CombineVirtualPathsInternal(VirtualPath basePath, VirtualPath relativePath) +26
System.Web.UI.MasterPage.CreateMaster(TemplateControl owner, HttpContext context, VirtualPath masterPageFile, IDictionary contentTemplateCollection) +85
System.Web.UI.Page.get_Master() +48
System.Web.UI.Page.ApplyMasterPage() +18
System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +685
How do you set a two-state button as "checked" in program code? For example, in the following Telerik example how do you set as checked the button having ImageUrl="~/Images/J.gif" ?
protected void tsTabs_TabClick(object sender, TabStripEventArgs e)
{
mpContent.SelectedIndex = e.Tab.Index;
}
And TabStripEventArgs is giving me an error. What should I replace it with?
Thanks
| ClientScriptManager cs = m_Instance.Page.ClientScript; |
| string pb = String.Empty; |
| if (!cs.IsClientScriptBlockRegistered(this.GetType(), "ProcessSelectedItemsBatch")) |
| { |
| pb = cs.GetPostBackEventReference(this, "***"); |
| StringBuilder cstext = new StringBuilder(); |
| cstext.Append("<script type=\"text/javascript\">"); |
| cstext.Append("function ProcessSelectedItemsBatch(sender)"); |
| cstext.Append("{"); |
| cstext.Append(pb.Replace("'***'", "sender")); |
| cstext.Append("}"); |
| cstext.AppendLine("</script>"); |
| cs.RegisterClientScriptBlock(this.GetType(), "ProcessSelectedItemsBatch", cstext.ToString(), false); |
| } |
| String call = String.Format("ProcessSelectedItemsBatch('{0}')", m_ScreenPart.GID.ToString()); |
| this.m_Instance.Attributes.Add("onblur", call); |
| this.m_Instance.MasterTableView.Attributes.Add("onblur", call); |
| this.m_Instance.ClientSettings.ClientEvents.OnRowSelected = call; |
| this.m_Instance.ClientSettings.ClientEvents.OnRowDeselected = call; |
| <script type="text/javascript">function ProcessSelectedItemsBatch(sender){__doPostBack('ctl00$CPBody$_se$ctl12',sender)}</script> |
| Sys.Application.add_init(function() { |
| $create(Telerik.Web.UI.RadGrid, {"AllowMultiRowSelection":true,"ClientID":"ctl00_CPBody__se_screen__04e3347b33fa41e68b37a936cef7eee6","ClientSettings":{"PostBackFunction":"__doPostBack(\u0027{0}\u0027,\u0027{1}\u0027)","AllowDragToGroup":true,"AllowExpandCollapse":true,"AllowGroupExpandCollapse":true,"ColumnsReorderMethod":0,"ShouldCreateRows":true,"Selecting":{"AllowRowSelect":true,"EnableDragToSelectRows":true},"Scrolling":{"SaveScrollPosition":true,"ScrollHeight":"300px"},"Resizing":{"ClipCellContentOnResize":true},"ClientMessages":{"DragToGroupOrReorder":"Drag to group or reorder","DragToResize":"Drag to resize","DropHereToReorder":"Drop here to reorder","PagerTooltipFormatString":"Page: \u003cb\u003e{0}\u003c/b\u003e out of \u003cb\u003e{1}\u003c/b\u003e pages"}},"ShowGroupPanel":true,"Skin":"Default","UniqueID":"ctl00$CPBody$_se$screen__04e3347b33fa41e68b37a936cef7eee6","_activeRowData":"","_clientKeyValues":{},"_currentPageIndex":0,"_gridTableViewsData":"[{\"ClientID\":\"ctl00_CPBody__se_screen__04e3347b33fa41e68b37a936cef7eee6_ctl00\",\"UniqueID\":\"ctl00$CPBody$_se$screen__04e3347b33fa41e68b37a936cef7eee6$ctl00\",\"PageSize\":10,\"PageCount\":1,\"CurrentPageIndex\":0,\"Name\":\"\",\"IsItemInserted\":false,\"clientDataKeyNames\":[],\"_selectedItemStyle\":\"\",\"_selectedItemStyleClass\":\"SelectedRow_Default\",\"_renderActiveItemStyle\":\"\",\"_renderActiveItemStyleClass\":\"ActiveRow_Default\",\"_columnsData\":[{\"UniqueName\":\"GID\",\"Resizable\":true,\"Reorderable\":true,\"Groupable\":true,\"Display\":false},{\"UniqueName\":\"TaxID\",\"Resizable\":true,\"Reorderable\":true,\"Groupable\":true,\"Display\":true},{\"UniqueName\":\"GivenName\",\"Resizable\":true,\"Reorderable\":true,\"Groupable\":true,\"Display\":true},{\"UniqueName\":\"Surname\",\"Resizable\":true,\"Reorderable\":true,\"Groupable\":true,\"Display\":true},{\"UniqueName\":\"DateOfBirth\",\"Resizable\":true,\"Reorderable\":true,\"Groupable\":true,\"Display\":true},{\"UniqueName\":\"GenderID\",\"Resizable\":true,\"Reorderable\":true,\"Groupable\":true,\"Display\":true}]}]","_groupPanelClientID":"ctl00_CPBody__se_screen__04e3347b33fa41e68b37a936cef7eee6_GroupPanel_TB","_groupPanelItems":"[]","_loadingText":"Loading...","_masterClientID":"ctl00_CPBody__se_screen__04e3347b33fa41e68b37a936cef7eee6_ctl00","_popUpIds":"[]","_readyText":"Ready","_statusLabelID":"","clientStateFieldID":"ctl00_CPBody__se_screen__04e3347b33fa41e68b37a936cef7eee6_ClientState"}, {"rowDeselected":ProcessSelectedItemsBatch('04e3347b-33fa-41e6-8b37-a936cef7eee6'),"rowSelected":ProcessSelectedItemsBatch('04e3347b-33fa-41e6-8b37-a936cef7eee6')}, null, $get("ctl00_CPBody__se_screen__04e3347b33fa41e68b37a936cef7eee6")); |