mohaammed talha

mohaammed talha

  • NA
  • 445
  • 51.8k

How to set >= Condition in dropdownList using C#

Jun 10 2021 7:16 AM

How to set >= Condition in dropdown list using asp.net c#

Query:

if (ddlToTimeHour >= ddlFromTimeHour)
{            
    query = "insert into ied_fsentry(fse_Unit,fse_Line,fse_Shift,fse_Date,fsm_Id,fse_Remarks,fse_From,fse_To,fse_EntryDate) values ('" + ddlUnit.SelectedValue + "','" + ddlLine.SelectedValue + "','" + ddlShift.SelectedValue + "', '" + values[2] + "-" + values[1] + "-" + values[0] + "','" + ddlLineStoppageReason.SelectedValue + "','" + txtRemarks.SelectedItem.Text + "','" + FromtimeString.ToString() + "','" + ToTimeString.ToString() + "',now())";
    Console.WriteLine("Data Succesfuuly Inserted");
}
else
{
    ShowMessage("Unable to save data. Please check entry.", MessageType.Error);
}


Answers (1)