Click here to Skip to main content
15,884,099 members
Home / Discussions / ASP.NET
   

ASP.NET

 
Questionhow to traverse a datarow in as datatable and modify that datarow Pin
Flavia A22-Nov-09 18:40
Flavia A22-Nov-09 18:40 
AnswerRe: how to traverse a datarow in as datatable and modify that datarow Pin
Amit Spadez22-Nov-09 19:14
professionalAmit Spadez22-Nov-09 19:14 
GeneralRe: how to traverse a datarow in as datatable and modify that datarow Pin
Flavia A22-Nov-09 19:35
Flavia A22-Nov-09 19:35 
GeneralRe: how to traverse a datarow in as datatable and modify that datarow Pin
Amit Spadez22-Nov-09 19:38
professionalAmit Spadez22-Nov-09 19:38 
QuestionProblem of adding malicious script tag in every page automatically Pin
cooolguymca22-Nov-09 18:26
cooolguymca22-Nov-09 18:26 
AnswerRe: Problem of adding malicious script tag in every page automatically Pin
Abhijit Jana22-Nov-09 18:27
professionalAbhijit Jana22-Nov-09 18:27 
GeneralRe: Problem of adding malicious script tag in every page automatically Pin
April Fans24-Nov-09 0:52
April Fans24-Nov-09 0:52 
Questionpage containing datatable has to be built and rebuilt again and again Pin
Flavia A22-Nov-09 17:11
Flavia A22-Nov-09 17:11 
hello,
I have a gridview in a webpage where i use a datatable to populate the gridview,but only if the website is built and rebuilt the webpage works properly without exceptions,as the datatable does not retain any data that has been asign to it on the button click.
Following is the code,
 static DataTable dtvalues = new DataTable();
       public static IICDServices icdObj;
    protected void Page_Load(object sender, EventArgs e)
    {
               if (!IsPostBack)
        {
                       
        }

    }

    private void Createdatatable()
    {
        dtvalues.Columns.Add("DL_No");
        dtvalues.Columns.Add("F_Name");
        dtvalues.Columns.Add("M_Name");
        dtvalues.Columns.Add("L_Name");
        dtvalues.Columns.Add("Unit");
        dtvalues.Columns.Add("Birth_Date");
        dtvalues.Columns.Add("Mobile_No");
        
    }
//on the add button click i want all data from the textboxes to be assigned to the datatable.
for which i have written the following code

 {

                        DataRow drvalues = dtvalues.NewRow();
                        drvalues["DL_No"] = TxtDLNO.Text.ToUpper();
                        drvalues["F_Name"] = txtFname.Text;
                        drvalues["M_Name"] = txtMName.Text;
                        drvalues["L_Name"] = txtLName.Text;
                        drvalues["Unit"] = ddlUnit.SelectedItem.Text;
                        drvalues["Birth_Date"] = Gmdatepicker3.Date;
                        drvalues["Mobile_No"] = TxtMobileNo.Text;
                        dtvalues.Rows.Add(drvalues);
                        GridView1.DataSource = dtvalues;
                        GridView1.DataBind();
                        TxtDLNO.Text = "";
                        txtFname.Text = "";
                        txtMName.Text = "";
                        txtLName.Text = "";
                        TxtMobileNo.Text = "";
                    }
on the submit button click i want to redirect this page back to itself but it throws an exception as the page has npt been rebuilt.
please help me out with this.
     thanks.

AnswerRe: page containing datatable has to be built and rebuilt again and again Pin
Abhijit Jana22-Nov-09 18:32
professionalAbhijit Jana22-Nov-09 18:32 
QuestionFormat some lines in listbox Pin
Member 470414322-Nov-09 14:04
Member 470414322-Nov-09 14:04 
AnswerRe: Format some lines in listbox Pin
Abhijit Jana22-Nov-09 16:07
professionalAbhijit Jana22-Nov-09 16:07 
GeneralRe: Format some lines in listbox Pin
Member 470414323-Nov-09 14:57
Member 470414323-Nov-09 14:57 
QuestionExpire a link Pin
Calvin1122-Nov-09 7:22
Calvin1122-Nov-09 7:22 
AnswerRe: Expire a link Pin
Abhishek Sur22-Nov-09 8:49
professionalAbhishek Sur22-Nov-09 8:49 
GeneralRe: Expire a link Pin
Calvin1122-Nov-09 10:36
Calvin1122-Nov-09 10:36 
GeneralRe: Expire a link Pin
Abhishek Sur22-Nov-09 12:05
professionalAbhishek Sur22-Nov-09 12:05 
GeneralRe: Expire a link Pin
Calvin1122-Nov-09 13:06
Calvin1122-Nov-09 13:06 
GeneralRe: Expire a link Pin
amol ambilwade6-Jul-10 10:05
amol ambilwade6-Jul-10 10:05 
QuestionSearch suggestion in ASP/ASP.Net; need help!! Pin
maddy201222-Nov-09 6:49
maddy201222-Nov-09 6:49 
AnswerRe: Search suggestion in ASP/ASP.Net; need help!! Pin
Blue_Boy22-Nov-09 6:58
Blue_Boy22-Nov-09 6:58 
AnswerRe: Search suggestion in ASP/ASP.Net; need help!! Pin
Abhishek Sur22-Nov-09 9:21
professionalAbhishek Sur22-Nov-09 9:21 
QuestionSharepoint Pin
vimalkumarsinghal22-Nov-09 5:22
vimalkumarsinghal22-Nov-09 5:22 
AnswerRe: Sharepoint Pin
Abhishek Sur22-Nov-09 5:24
professionalAbhishek Sur22-Nov-09 5:24 
Questionhow to programatically click on LINK Pin
Muhammad Nauman Yousuf22-Nov-09 4:23
Muhammad Nauman Yousuf22-Nov-09 4:23 
AnswerRe: how to programatically click on LINK Pin
N a v a n e e t h22-Nov-09 4:25
N a v a n e e t h22-Nov-09 4:25 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.