i m using this code and getting error whats wrong
if (sl.ShowDialog() == DialogResult.OK)
{
mytime = sl.monthCalendar1.SelectionStart.AddHours(sl.dateTimePicker1.Value.Hour).AddMinutes(sl.dateTimePicker1.Value.Minute).AddSeconds(sl.dateTimePicker1.Value.Second);
this.Visible = false;
} }
private void timer1_Tick(object sender, EventArgs e)
{
if (mytime.CompareTo(DateTime.Now) < 0)
{
this.Visible = true;
}
}
Error 1 'login.select_values' does not contain a definition for 'dateTimePicker1' and no extension method 'dateTimePicker1' accepting a first argument of type 'login.select_values' could be found (are you missing a using directive or an assembly reference?)
Loading

Anurag SarkarRank #1,049 · 1.8K reputationPosted Aug 10, 2013, 1:23 AM EDT
Iftikar HussainRank #423 · 5.9K reputationPosted Aug 9, 2013, 8:50 PM EDT
Can you please share the complete code as will help us to resolve your query?
Regards,
Iftikar
ta mu198 reputationPosted Aug 9, 2013, 9:19 PM EDT
public partial class add_reminder : Form
{
public add_reminder()
{
InitializeComponent();
}
select_values sl = new select_values();
private DateTime mytime;
private void linkLabel1_LinkClicked(object sender, LinkLabelLinkClickedEventArgs e)
{
if (sl.ShowDialog() == DialogResult.OK)
{
mytime = sl.monthCalendar1.SelectionStart.AddHours(sl.dateTimePicker1.Value.Hour).AddMinutes(sl.dateTimePicker1.Value.Minute).AddSeconds(sl.dateTimePicker1.Value.Second);
this.Visible = false;
} }
private void timer1_Tick(object sender, EventArgs e)
{
if (mytime.CompareTo(DateTime.Now) < 0)
{
this.Visible = true;
}
}
}
}
Iftikar HussainRank #423 · 5.9K reputationPosted Aug 9, 2013, 9:43 PM EDT
Regards,
Iftikar
ta mu198 reputationPosted Aug 9, 2013, 10:32 PM EDT
Iftikar HussainRank #423 · 5.9K reputationPosted Aug 9, 2013, 11:34 PM EDT
Regards,
Iftikar
ta mu198 reputationPosted Aug 10, 2013, 1:17 AM EDT
ta mu198 reputationPosted Aug 10, 2013, 1:38 AM EDT