Click here to Skip to main content
15,893,668 members

Comments by Qureshali (Top 42 by date)

Qureshali 2-May-12 1:34am View    
Also this above code is for downloading the file....
Qureshali 2-May-12 1:31am View    
It could not find the file. My file is stored in my project in Files folder.
.../Files/abc.docx
So, my statement is:
string FullFilePath =".../Files/abc.docx";
But when debugger comes to if(file.exists) it doesn't go inside the condition
Qureshali 26-Apr-12 6:17am View    
Ok but how to post back form using jQuery on radio button checked change
Qureshali 26-Mar-12 3:16am View    
Yes sir I have crossed check many times but it is working fine at localhost then y not on server.
Qureshali 26-Mar-12 3:13am View    
Sure sir,
protected void btnnext_Click(object sender, EventArgs e)
{

try
{
Int32 i = grdallques.Rows.Count;
btnprev.Enabled = true;
if (Convert.ToInt32(lblqno.Text) < i)
{
//==========================================================================
/*For retrieving the last question's checked value
* and the selecting the corresponding radio button=TRUE*/
//==========================================================================
//qid = Convert.ToInt32(grdallques.Rows[Convert.ToInt32(lblqno.Text) - 1].Cells[8].Text);



qid = Convert.ToInt32(lblqno.Text) + 1;

oTestGivenEntity = new TestGivenEntity();
oTestGivenEntity = TestGivenBL.GetFromTestGivenSelectedValueForRadioBotton(qid, Global.UserId);
if (oTestGivenEntity != null)
{
if (oTestGivenEntity.OptionChecked == "A")
{
rbtnopt1.Checked = true;
rbtnopt2.Checked = false;
rbtnopt3.Checked = false;
rbtnopt4.Checked = false;
rbtnopt5.Checked = false;
}
if (oTestGivenEntity.OptionChecked == "B")
{
rbtnopt1.Checked = false;
rbtnopt2.Checked = true;
rbtnopt3.Checked = false;
rbtnopt4.Checked = false;
rbtnopt5.Checked = false;
}
if (oTestGivenEntity.OptionChecked == "C")
{
rbtnopt1.Checked = false;
rbtnopt2.Checked = false;
rbtnopt3.Checked = true;
rbtnopt4.Checked = false;
rbtnopt5.Checked = false;
}
if (oTestGivenEntity.OptionChecked == "D")
{
rbtnopt1.Checked = false;
rbtnopt2.Checked = false;
rbtnopt3.Checked = false;
rbtnopt4.Checked = true;
rbtnopt5.Checked = false;
}
if (oTestGivenEntity.OptionChecked == "E")
{
rbtnopt1.Checked = true;
rbtnopt2.Checked = false;
rbtnopt3.Checked = false;
rbtnopt4.Checked = false;
rbtnopt5.Checked = true;
}
}
else
{
/// For All radio buttons checked=FALSE
//rbtnopt1.Checked = false;
//rbtnopt2.Checked = false;
//rbtnopt3.Checked = false;
//rbtnopt4.Checked = false;
//rbtnopt5.Checked = false;
}
// For submitting the answer
// Inserting the data into TestGiven Table
if (rbtnopt1.Checked == true || rbtnopt2.Checked == true || rbtnopt3.Checked == true || rbtnopt4.Checked == true || rbtnopt5.Checked == true)
{
//Get questionId for the currently displyed question
Int32 q_ID = Convert.ToInt32(grdallques.Rows[Convert.ToInt32(lblqno.Text) - 1].Cells[8].Text);

oTestGivenEntity = new TestGivenEntity();
oTestGivenEntity.TestPaper