or
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"> <AjaxSettings> <telerik:AjaxSetting AjaxControlID="RadAjaxManager1"> <UpdatedControls> <telerik:AjaxUpdatedControl ControlID="RadSchedulerTemplate" /> </UpdatedControls> </telerik:AjaxSetting> <telerik:AjaxSetting AjaxControlID="RadSchedulerTemplate"> <UpdatedControls> <telerik:AjaxUpdatedControl ControlID="RadSchedulerTemplate" /> </UpdatedControls> </telerik:AjaxSetting> </AjaxSettings> </telerik:RadAjaxManager>Dim app As Appointment = e.AppointmentDim subject As String = app.SubjectDim startDate As DateTime = app.StartDim endDate As DateTime = app.EndDim recurrenceRule As String = app.RecurrenceRuleDim recurrenceParentID As Integer = app.RecurrenceParentIDDim description As String = app.DescriptiondbConnection.ConnectionString = ConfigurationManager.ConnectionStrings("Test").ConnectionStringdbConnection.Open()dbCommand = dbConnection.CreateCommanddbCommand.CommandType = CommandType.StoredProceduredbCommand.CommandText = "S_Test"dbCommand.Parameters.Add("@Subject", SqlDbType.VarChar).Value = subjectdbCommand.Parameters.Add("@StartDate", SqlDbType.DateTime).Value = startDatedbCommand.Parameters.Add("@EndDate", SqlDbType.DateTime).Value = endDateIf Not String.IsNullOrEmpty(recurrenceRule) Then dbCommand.Parameters.Add("@RecurrenceRule", SqlDbType.VarChar).Value = recurrenceRuleEnd IfIf recurrenceParentID <> 0 Then dbCommand.Parameters.Add("@RecurrenceParentID", SqlDbType.Int).Value = recurrenceParentIDEnd IfIf Not String.IsNullOrEmpty(description) Then dbCommand.Parameters.Add("@Description", SqlDbType.VarChar).Value = descriptionEnd IfdbCommand.ExecuteNonQuery()RadSchedulerTemplate.Rebind()
protected void Page_Load(object sender, EventArgs e){ RadListBox1.ItemDataBound += new Telerik.Web.UI.RadListBoxItemEventHandler(RadListBox1_ItemDataBound); RadListBox1.SelectedIndexChanged += new EventHandler(RadListBox1_SelectedIndexChanged); }void RadListBox1_SelectedIndexChanged(object sender, EventArgs e){ #region Start mode customization via Web Query String int idx = 0; int auto = 0; string qry = ""; try { qry = "auto"; qry = (Request.QueryString[qry] == null) ? "" : Request.QueryString[qry]; if (qry != "") { auto = int.Parse(qry); } } catch { } // Item index try { qry = "item"; qry = (Request.QueryString[qry] == null) ? "" : Request.QueryString[qry]; if (qry != "") { idx = int.Parse(qry); } } catch { } #endregion Literal1.Text = YouTubeScript.Get(RadListView1.SelectedItems[0].GetDataKeyValue("Video_Path").ToString(), auto, _W, _H); Label1.Text = RadListView1.SelectedItems[0].GetDataKeyValue("Video_Path").ToString();}protected void RadListView1_ItemDataBound(object sender, Telerik.Web.UI.RadListViewItemEventArgs e){ Literal1.Text = YouTubeScript.Get(RadListView1.Items[0].GetDataKeyValue("Video_Path").ToString(), 0, _W, _H).ToString(); Label1.Text = RadListView1.Items[0].GetDataKeyValue("Video_Description").ToString();}
|