emailsenddate
public void timerTickEvent(DateTime emailsenddate) { Timer timer = new Timer(); Label clockLabel = new Label(); timer.ID = ID + "_tiker"; clockLabel.ID = ID + "_l"; UpdatePanel updatePanel = new UpdatePanel(); Control controlContainer = updatePanel.ContentTemplateContainer; controlContainer.Controls.Add(clockLabel); controlContainer.Controls.Add(timer); updatePanel.Triggers.Add(new AsyncPostBackTrigger() { ControlID = timer.ID, EventName = "Tick" }); updatePanel.ChildrenAsTriggers = true; clockLabel.Text = DateTime.Now.ToString(); timer.Interval = 60000; updatePanel.RenderMode = UpdatePanelRenderMode.Block; base.Controls.Add(updatePanel); emailSend(); }
double interval = 0; if (emailsenddate > dateTime.Now) { TimeSpan span = emailsenddate - dateTime.Now; interval = span.TotalMilliseconds; }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)