Click here to Skip to main content
16,013,322 members
Home / Discussions / ASP.NET
   

ASP.NET

 
AnswerRe: how to do update Pin
SimulationofSai28-May-07 20:13
SimulationofSai28-May-07 20:13 
QuestionAll Contents in page are not coming on print paper Pin
pjc*28-May-07 20:05
pjc*28-May-07 20:05 
AnswerRe: All Contents in page are not coming on print paper Pin
SimulationofSai28-May-07 20:10
SimulationofSai28-May-07 20:10 
QuestionType is not resolved for member - CSLA.Security.BusinessPrincipal Exception Pin
JagaSoft28-May-07 19:51
JagaSoft28-May-07 19:51 
Questionhow to access listbox items filled by javascript, on code behind Pin
Amit Sk Sharma28-May-07 19:48
Amit Sk Sharma28-May-07 19:48 
AnswerRe: how to access listbox items filled by javascript, on code behind Pin
ash0428-May-07 20:20
ash0428-May-07 20:20 
QuestionInvalid postback or callback argument. Event validation is enabled using in configuration ...... Pin
vijay258328-May-07 19:32
vijay258328-May-07 19:32 
Questiondynamic image button click event Pin
harithadotnet28-May-07 19:20
harithadotnet28-May-07 19:20 
Hi
I created image buttons dynamicaly and i have added click event for image controls. but click event is not working
code is as follows

ImageButton img ;
private void Page_Load(object sender, System.EventArgs e)
{
if (!IsPostBack)
{
for (int i = 1; i < 11; i++)
{
img = new ImageButton();
img.ID = "img" +i.ToString();
img.ImageUrl="pg/1212/"+ i +".jpg";

pl.Controls.Add(img); (pl is place holder control id)
}
}
img.Click += new ImageClickEventHandler( img_Click );

( while debugging showing the error in the above line as "object reference not set to instance of an object)

}



protected void img_Click ( object sender, ImageClickEventArgs e )

{

ImageButton img = ( ImageButton )sender;

Response.Write(img.ID + "");

}

plz let me know whats that error how to rectify that
thanks in advance




Haritha

AnswerRe: dynamic image button click event Pin
VenkataRamana.Gali28-May-07 20:07
VenkataRamana.Gali28-May-07 20:07 
Questionprofessional to expert books for asp.net Pin
Balaji.K28-May-07 19:17
Balaji.K28-May-07 19:17 
AnswerRe: professional to expert books for asp.net Pin
VenkataRamana.Gali28-May-07 19:27
VenkataRamana.Gali28-May-07 19:27 
AnswerRe: professional to expert books for asp.net Pin
Sandeep Akhare28-May-07 19:42
Sandeep Akhare28-May-07 19:42 
QuestionFetching Undelivered Mail From Outllook Through ASP.NET 2.0 Pin
varshavmane28-May-07 19:13
varshavmane28-May-07 19:13 
AnswerRe: Fetching Undelivered Mail From Outllook Through ASP.NET 2.0 Pin
Sandeep Akhare28-May-07 19:39
Sandeep Akhare28-May-07 19:39 
GeneralRe: Fetching Undelivered Mail From Outllook Through ASP.NET 2.0 Pin
varshavmane28-May-07 20:01
varshavmane28-May-07 20:01 
GeneralRe: Fetching Undelivered Mail From Outllook Through ASP.NET 2.0 Pin
SimulationofSai28-May-07 20:06
SimulationofSai28-May-07 20:06 
GeneralRe: Fetching Undelivered Mail From Outllook Through ASP.NET 2.0 Pin
varshavmane28-May-07 20:18
varshavmane28-May-07 20:18 
Questiondata formatting expression Pin
Member 387988128-May-07 19:02
Member 387988128-May-07 19:02 
AnswerRe: data formatting expression Pin
ash0428-May-07 19:43
ash0428-May-07 19:43 
GeneralRe: data formatting expression Pin
Member 387988128-May-07 20:07
Member 387988128-May-07 20:07 
GeneralRe: data formatting expression Pin
ash0428-May-07 22:20
ash0428-May-07 22:20 
GeneralRe: data formatting expression Pin
Member 387988128-May-07 23:15
Member 387988128-May-07 23:15 
GeneralRe: data formatting expression Pin
ash0429-May-07 0:49
ash0429-May-07 0:49 
QuestionWorking with Data Grids Pin
rangaSL28-May-07 18:52
rangaSL28-May-07 18:52 
AnswerRe: Working with Data Grids Pin
VenkataRamana.Gali28-May-07 18:55
VenkataRamana.Gali28-May-07 18:55 

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.