Click here to Skip to main content
15,887,676 members
Home / Discussions / ASP.NET
   

ASP.NET

 
GeneralRe: Implementing Audio Captcha Pin
Sachin Dubey6-Sep-09 20:25
Sachin Dubey6-Sep-09 20:25 
GeneralRe: Implementing Audio Captcha Pin
Christian Graus6-Sep-09 20:28
protectorChristian Graus6-Sep-09 20:28 
GeneralRe: Implementing Audio Captcha Pin
Sachin Dubey6-Sep-09 20:31
Sachin Dubey6-Sep-09 20:31 
GeneralRe: Implementing Audio Captcha Pin
N a v a n e e t h6-Sep-09 21:11
N a v a n e e t h6-Sep-09 21:11 
QuestionHow to implement state management in c# Pin
rj shukla6-Sep-09 19:50
rj shukla6-Sep-09 19:50 
AnswerRe: How to implement state management in c# Pin
Christian Graus6-Sep-09 20:03
protectorChristian Graus6-Sep-09 20:03 
AnswerRe: How to implement state management in c# Pin
sashidhar6-Sep-09 21:35
sashidhar6-Sep-09 21:35 
QuestionHow to avoid reinitialization of variables in page load Pin
amittinku6-Sep-09 17:28
amittinku6-Sep-09 17:28 
Code is below.
Problem is that when I delete 1st row, it gets deleted successfully.
When click happens, post back takes place. In page load, again resetting of dataset etc takes place. Now again dataset is populated with original values.
Please note that after deleting one row, I am not transferring the change back to connected data.
So how to achive it i.e. delete as many as rows in disconnected mode (without transferring any change to connected database).

IF I put all code of page load in (!Ispageback), it will not work because in deleting event, it will not find instance of ds etc.

More details:
Say 3 rows in dataset. I delete one. it is successful. post back takes place. In page load, again data set reinitialized, again filled up with 3 values (because after 1st deletion, we have not update the live data). So how to set the variables in such a way to achive it?

----------------------------------------------------------------
public partial class database : System.Web.UI.Page
{
OracleConnection oo;
String tt;
OracleDataAdapter adp;
DataSet ds ;

DataTable dt;
DataRow rw;

protected void Page_Load(object sender, EventArgs e)
{
oo = new OracleConnection(ConfigurationManager.ConnectionStrings["ConnectionString"].ConnectionString);

tt = "select emp_id,emp_name from ado";
adp = new OracleDataAdapter(tt, oo);
ds = new DataSet();
adp.Fill(ds, "ado");
GridView1.DataSource = ds;

if (!IsPostBack)
{

GridView1.DataBind();

}
}
protected void GridView1_RowDeleting(object sender, GridViewDeleteEventArgs e)
{
int pos = e.RowIndex;
ds.Tables[0].Rows[pos].Delete();
ds.AcceptChanges();
GridView1.DataBind();
}
}
AnswerRe: How to avoid reinitialization of variables in page load Pin
Christian Graus6-Sep-09 18:28
protectorChristian Graus6-Sep-09 18:28 
GeneralRe: How to avoid reinitialization of variables in page load Pin
amittinku6-Sep-09 18:52
amittinku6-Sep-09 18:52 
GeneralRe: How to avoid reinitialization of variables in page load Pin
Christian Graus6-Sep-09 19:22
protectorChristian Graus6-Sep-09 19:22 
Questiondata insertion in gridview Pin
swtlibra6-Sep-09 17:28
swtlibra6-Sep-09 17:28 
AnswerRe: data insertion in gridview Pin
Abhijit Jana6-Sep-09 18:16
professionalAbhijit Jana6-Sep-09 18:16 
AnswerRe: data insertion in gridview Pin
Christian Graus6-Sep-09 18:19
protectorChristian Graus6-Sep-09 18:19 
AnswerRe: data insertion in gridview Pin
mylogics6-Sep-09 20:10
professionalmylogics6-Sep-09 20:10 
AnswerRe: data insertion in gridview Pin
Vimalsoft(Pty) Ltd6-Sep-09 20:21
professionalVimalsoft(Pty) Ltd6-Sep-09 20:21 
Questionwebservice Pin
farokhian6-Sep-09 11:22
farokhian6-Sep-09 11:22 
AnswerRe: webservice Pin
Abhishek Sur6-Sep-09 12:15
professionalAbhishek Sur6-Sep-09 12:15 
GeneralRe: webservice Pin
farokhian6-Sep-09 21:00
farokhian6-Sep-09 21:00 
GeneralRe: webservice Pin
Abhishek Sur6-Sep-09 22:00
professionalAbhishek Sur6-Sep-09 22:00 
GeneralRe: webservice [modified] Pin
farokhian6-Sep-09 23:54
farokhian6-Sep-09 23:54 
AnswerRe: webservice Pin
Christian Graus6-Sep-09 12:19
protectorChristian Graus6-Sep-09 12:19 
QuestionUserControl and javascript. Pin
Matt Cavanagh6-Sep-09 8:05
Matt Cavanagh6-Sep-09 8:05 
AnswerRe: UserControl and javascript. Pin
Abhishek Sur6-Sep-09 10:55
professionalAbhishek Sur6-Sep-09 10:55 
GeneralRe: UserControl and javascript. Pin
Matt Cavanagh6-Sep-09 11:24
Matt Cavanagh6-Sep-09 11:24 

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.