Click here to Skip to main content
15,921,793 members
Home / Discussions / C#
   

C#

 
GeneralRe: ASP.NET C# Custom Control with Postback. Pin
Forbiddenx14-Aug-13 3:57
Forbiddenx14-Aug-13 3:57 
AnswerRe: ASP.NET C# Custom Control with Postback. Pin
Richard Deeming14-Aug-13 4:01
mveRichard Deeming14-Aug-13 4:01 
GeneralRe: ASP.NET C# Custom Control with Postback. Pin
Forbiddenx14-Aug-13 5:18
Forbiddenx14-Aug-13 5:18 
GeneralRe: ASP.NET C# Custom Control with Postback. Pin
Forbiddenx14-Aug-13 7:35
Forbiddenx14-Aug-13 7:35 
GeneralRe: ASP.NET C# Custom Control with Postback. Pin
Richard Deeming14-Aug-13 7:55
mveRichard Deeming14-Aug-13 7:55 
GeneralRe: ASP.NET C# Custom Control with Postback. Pin
Forbiddenx14-Aug-13 8:03
Forbiddenx14-Aug-13 8:03 
GeneralRe: ASP.NET C# Custom Control with Postback. Pin
Richard Deeming14-Aug-13 8:14
mveRichard Deeming14-Aug-13 8:14 
GeneralRe: ASP.NET C# Custom Control with Postback. Pin
Forbiddenx16-Aug-13 7:59
Forbiddenx16-Aug-13 7:59 
Hi Rich,

Its ok, I manged to figure it out..
I wanted to add the solution to the post too so other may do the same.

Right after your add your control, and then your event via the init...
If you want to put your control inside a update panel and stop a full page post back then you must register your control with the parent page and do it inside the actually control code itself... outside dont seem to work via the main page containing the control.

C#
protected override void OnInit(EventArgs e)
{
base.OnInit(e);

ScriptManager script = ScriptManager.GetCurrent(Page);
TxtParamValue = new TextBox();
TxtParamValue.TextChanged += new EventHandler(TxtParamValue_TextChanged);
if (script != null) { script.RegisterAsyncPostBackControl(TxtParamValue);}
base.Controls.Add(TxtParamValue);
}


Thanks, and enjoy all!
=)

QuestionASP.NET C# Custom Control with Postback. Pin
Forbiddenx14-Aug-13 3:04
Forbiddenx14-Aug-13 3:04 
AnswerRe: ASP.NET C# Custom Control with Postback. Pin
Pete O'Hanlon14-Aug-13 3:12
mvePete O'Hanlon14-Aug-13 3:12 
AnswerRe: ASP.NET C# Custom Control with Postback. Pin
Pete O'Hanlon14-Aug-13 3:41
mvePete O'Hanlon14-Aug-13 3:41 
GeneralRe: ASP.NET C# Custom Control with Postback. Pin
Forbiddenx14-Aug-13 3:44
Forbiddenx14-Aug-13 3:44 
AnswerRe: ASP.NET C# Custom Control with Postback. Pin
Jay Nardev18-Aug-13 3:13
Jay Nardev18-Aug-13 3:13 
Questionc# Pin
Virendra Yaduvanshi14-Aug-13 2:15
Virendra Yaduvanshi14-Aug-13 2:15 
AnswerRe: c# Pin
Pete O'Hanlon14-Aug-13 2:35
mvePete O'Hanlon14-Aug-13 2:35 
AnswerRe: c# Pin
Abhinav S14-Aug-13 17:53
Abhinav S14-Aug-13 17:53 
AnswerRe: c# Pin
Sivaraman Dhamodharan16-Aug-13 0:01
Sivaraman Dhamodharan16-Aug-13 0:01 
QuestionRegarding license file Pin
ShaneSpecial14-Aug-13 0:51
ShaneSpecial14-Aug-13 0:51 
AnswerRe: Regarding license file Pin
Richard MacCutchan14-Aug-13 0:59
mveRichard MacCutchan14-Aug-13 0:59 
QuestionDot net Windows Service Pin
Hemant Thaker13-Aug-13 20:52
Hemant Thaker13-Aug-13 20:52 
AnswerRe: Dot net Windows Service Pin
Manfred Rudolf Bihy13-Aug-13 21:10
professionalManfred Rudolf Bihy13-Aug-13 21:10 
AnswerRe: Dot net Windows Service Pin
Jay Nardev18-Aug-13 3:28
Jay Nardev18-Aug-13 3:28 
QuestionDigital Signature in PDF using USB Token (C#) Pin
dsshiny13-Aug-13 19:02
dsshiny13-Aug-13 19:02 
AnswerRe: Digital Signature in PDF using USB Token (C#) Pin
Eddy Vluggen14-Aug-13 6:06
professionalEddy Vluggen14-Aug-13 6:06 
GeneralRe: Digital Signature in PDF using USB Token (C#) Pin
dsshiny15-Aug-13 23:04
dsshiny15-Aug-13 23:04 

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.