<asp:Calendar ID="MyCalendar" runat="server" AutoPostBack="true" BackColor="White" BorderColor="Black" Font-Names="Times New Roman" Font-Size="10pt" ForeColor="Black" Height="220px" NextPrevFormat="FullMonth" OnSelectionChanged="MyCalendar_SelectionChanged" SelectionMode="DayWeek" Width="400px" DayNameFormat="Shortest" TitleFormat="Month" SelectedDate="12/23/2014 08:26:51"> <SelectedDayStyle BackColor="#CC3333" ForeColor="White" /> <OtherMonthDayStyle ForeColor="#999999" /> <TodayDayStyle BackColor="#CCCC99" /> <DayStyle Width="14%" /> <NextPrevStyle Font-Size="8pt" ForeColor="White" /> <DayHeaderStyle Font-Bold="True" Font-Size="7pt" BackColor="#CCCCCC" ForeColor="#333333" Height="10pt" /> <SelectorStyle BackColor="#CCCCCC" Font-Bold="True" Font-Names="Verdana" Font-Size="8pt" ForeColor="#333333" Width="1%" /> <TitleStyle BackColor="Black" Font-Bold="True" Font-Size="13pt" ForeColor="White" Height="14pt" /> </asp:Calendar>
protected void button2_Click(object sender, EventArgs e) { String strSQL; strSQL = "SELECT * FROM ADMS_Machining where datetime = '" + this.Label4.Text + "'"; SqlDataReader dtReader; objCmd = new SqlCommand(strSQL, objConn); dtReader = objCmd.ExecuteReader(); //*** BindData to Repeater ***//* myRepeater.DataSource = dtReader; myRepeater.DataBind(); dtReader.Close(); dtReader = null; } protected void MyCalendar_SelectionChanged(object sender, EventArgs e) { Label4.Text = "You selected these dates:<br />"; foreach (DateTime dt in MyCalendar.SelectedDates) { Label4.Text += dt.ToLongDateString() + "<br />"; } }
<globalization culture="en-US" uiCulture="en-US" />
<system.web> <compilation debug="true" targetFramework="4.0" /> <globalization fileEncoding="utf-8" requestEncoding="utf-8" responseEncoding="utf-8" culture="en-US" uiCulture="de-DE" />
เพื่อความปลอดภัยของเว็บบอร์ด ไม่อนุญาติให้แทรก แท็ก [img]....[/img] โดยการอัพโหลดไฟล์รูปจากที่อื่น เช่นเว็บไซต์ ฟรีอัพโหลดต่าง ๆ อัพโหลดแทรกรูปภาพ ให้ใช้บริการอัพโหลดไฟล์ของไทยครีเอท และตัดรูปภาพให้พอดีกับสกรีน เพื่อความโหลดเร็วและไฟล์ไม่ถูกลบทิ้ง