Start by moving some of the code outside the loop:
decimal month;
if (!decimal.TryParse(txt_monthInstall.Text, out month))
{
}
else
{
DateTime InstallDate;
if (!DateTime.TryParse(txt_dated.Text, out InstallDate))
{
}
else
{
for (int i = 0; i <= int.Parse(txt_bank1.Text); i++)
{
conn.filldatatable("ERP.sp_InstallmentMaster_Insert '" + txt_enqno.Text + "'," + month + ",'" + InstallDate + "','0'," + month + ",'True'");
month++;
}
}
}
Then, find a way to do that that doesn't involve concatenating strings: Never concatenate strings to build a SQL command. It leaves you wide open to accidental or deliberate SQL Injection attack which can destroy your entire database. Use Parametrized queries instead.