473,406 Members | 2,705 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Dynamic Controls and Page_Init


Hello again to all of you geniuses,

I'm having a problem trying to load dynamic controls at the initialization phase.

I've read the docs, and I thought I had it figured out:
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
.NET Framework Class Library

Control.Init Event [C#]

C#
public event EventHandler Init;

Event Data
The event handler receives an argument of type EventArgs.

Remarks
Server controls should perform any initialization steps that are required
to create and set up an instance. You cannot use view-state information
within this event; it is not populated yet. You should not access another
server control during this event, regardless of whether it is a child or
parent to this control. Other server controls are not certain to be created
and ready for access.

Example
[C#] The following example assigns a custom event handler, Control_Init,
to the Init event of a control, myControl, when the Page_Init method is
called on the page that contains the control.

[C#]
void Page_Init(object sender,EventArgs e)
{
// Add a event Handler for 'Init'.
myControl.Init += new System.EventHandler(Control_Init);
}

void Control_Init(object sender,EventArgs e)
{
Response.Write("The ID of the object initially : " + myControl.ID);
// Change the ID property.
myControl.ID="TestControl";
Response.Write("<br>The changed ID : " + myControl.ID);
}

© 2001-2002 Microsoft Corporation. All rights reserved.

<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>

One thing I don't understand is: Where did "myControl" come from in the
given example?

In my own effort, I tried to attach a literal control to a placeholder:
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>

void Page_Init(object sender,EventArgs e)
{
// Add a event Handler for 'Init'.
// myControl.Init += new System.EventHandler(Control_Init);
PlaceHolder plc_hldr = (PlaceHolder) FindControl ("Dyn_Control_Placeholder");
plc_hldr.Init += new System.EventHandler (plc_hldr_Control_Init);
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
Label lbl_msg01 = (Label) FindControl ("Message01");

Dyn_Control_Placeholder.Controls.Add
( new LiteralControl("<br>added 1 on init<br>") );
PlaceHolder plc_hldr = (PlaceHolder) FindControl ("Dyn_Control_Placeholder");

lbl_msg01.Text = "The ID of the object initially : " + plc_hldr.ID;
Response.Write("The ID of the object initially : " + plc_hldr.ID);

plc_hldr.Controls.Add ( new LiteralControl("<br>added 2 on init<br>") );
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>

... and nothing happened - the literal control was not there.

I'm hoping that someone smarter than me can clue me in on this
- I would be most grateful.

My complete code is as follows:
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<%@ Page Language="C#" AutoEventWireup="True" %>

<html>
<head>

<script runat="server">

/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

/* -+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- */
public class sys_obj_class
{
private ControlCollection pram_ph01_ctrl;
public ControlCollection Get_pram_ph01_ctrl
{ get { return pram_ph01_ctrl; } }

private Page this_page01;
public Page Get_this_page01
{ get { return this_page01; } }

private PlaceHolder Obj_Dyn_Ctrl_Placeholder;
public PlaceHolder Get_Obj_Dyn_Ctrl_Placeholder
{ get { return Obj_Dyn_Ctrl_Placeholder; } }

private Label Obj_Dyn_Label01;
public Label Get_Obj_Dyn_Label01
{ get { return Obj_Dyn_Label01; } }
public sys_obj_class
(PlaceHolder Dyn_Ctrl_Placeholder, Label Dyn_Label)
{ pram_ph01_ctrl = Dyn_Ctrl_Placeholder.Controls;
this_page01 = Dyn_Ctrl_Placeholder.Page;
Obj_Dyn_Ctrl_Placeholder = Dyn_Ctrl_Placeholder;
Obj_Dyn_Label01 = Dyn_Label;
}
}

/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void Page_Init(object sender,EventArgs e)
{
// Add a event Handler for 'Init'.
// myControl.Init += new System.EventHandler(Control_Init);
PlaceHolder plc_hldr = (PlaceHolder) FindControl ("Dyn_Control_Placeholder");
plc_hldr.Init += new System.EventHandler(plc_hldr_Control_Init);
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
Label lbl_msg01 = (Label) FindControl ("Message01");
PlaceHolder plc_hldr = (PlaceHolder) FindControl ("Dyn_Control_Placeholder");

lbl_msg01.Text = "The ID of the object initially : " + plc_hldr.ID;
Response.Write("The ID of the object initially : " + plc_hldr.ID);

plc_hldr.Controls.Add ( new LiteralControl("<br>added on init<br>") );
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
protected void Page_Load (Object sender, EventArgs e)
{
PlaceHolder plc_hldr = (PlaceHolder) FindControl ("Dyn_Control_Placeholder");
Label lbl_msg01 = (Label) FindControl ("Message01");
sys_obj_class sys_obj = new sys_obj_class (plc_hldr, lbl_msg01);

ctrl_pair_creation_01 ccp1 = new ctrl_pair_creation_01 (sys_obj);

ccp1.create_ctrl_pair_01 ();
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

/* - - - - - - - - - - - - - - - - - - - - - - */
/* - - - - - - - - - - - - - - - - - - - - - - */
protected class base_create_ctrl_pair
{
protected TextBox UserTextBox0x;
protected Button button0x;
protected ControlCollection ph01_ctrl;
protected PlaceHolder base_Dyn_Ctrl_Placeholder;
protected Label Dyn_Lbl_msg01;

// constructor
protected base_create_ctrl_pair (sys_obj_class sys_obj)
{ ph01_ctrl = sys_obj.Get_pram_ph01_ctrl;
base_Dyn_Ctrl_Placeholder = sys_obj.Get_Obj_Dyn_Ctrl_Placeholder;
Dyn_Lbl_msg01 = sys_obj.Get_Obj_Dyn_Label01;
}

protected TextBox create_text_box_control (String text_box_id)
{ // Create UserTextBox TextBox control.
TextBox new_TextBox = new TextBox ();

// Configure the UserTextBox TextBox control.
new_TextBox.ID = text_box_id;

// Add UserTextBox TextBox control to the Controls collection
// of the Dyn_Control_Placeholder PlaceHolder control.
ph01_ctrl.Add (new_TextBox);

return new_TextBox;
}

/* --------------------------------------------------------- *
Example: The following example creates a Button,
sets its DialogResult property to DialogResult.OK,
and adds it to a Form.
* --------------------------------------------------------- */
protected void InitializeMyButton (String Btn_ID, String Btn_text)
{ // Create and initialize a Button.
button0x = new Button();
button0x.ID = Btn_ID;
button0x.Text = Btn_text;

ph01_ctrl.Add ( new LiteralControl("<br><br>") );
ph01_ctrl.Add (button0x);
}

protected void init_single_line_text_box (TextBox new_TextBox, int col_sz)
{ new_TextBox.Columns = col_sz; }

protected void create_ctrl_pair_0x
(String TB_ID, String DB_ID, String DB_txt)
{ // Create UserTextBox TextBox control.
UserTextBox0x = create_text_box_control (TB_ID);
InitializeMyButton(DB_ID, DB_txt);
}

/* -+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- */
private String submit_click_str01 = "The TextBox";

private String submit_click_str02
= " control above is dynamically generated. <br> You entered: ";
public void Submit_Click (Object sender, EventArgs e)
{ // Retrieve the UserTextBox TextBox control from the
Dyn_Control_Placeholder
// PlaceHolder control.
TextBox TempTextBox = (TextBox)
base_Dyn_Ctrl_Placeholder.FindControl("UserTextBox 1");

// Display the Text property.
Dyn_Lbl_msg01.Text = submit_click_str01 + '1' + submit_click_str02 +
TempTextBox.Text;
}
/* -+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+- */

}
/* - - - - - - - - - - - - - - - - - - - - - - */
/* - - - - - - - - - - - - - - - - - - - - - - */
protected class ctrl_pair_creation_01 : base_create_ctrl_pair
{
private sys_obj_class lcl_sys_obj;

// constructor
public ctrl_pair_creation_01 (sys_obj_class sys_obj) : base (sys_obj)
{ lcl_sys_obj = sys_obj; }

/* . . . . . . . . . . . . . */
public void create_ctrl_pair_01 ()
{ create_ctrl_pair_0x
("UserTextBox1", "DButton01", "Submit 01");

button0x.Click += new EventHandler (Submit_Click);

if (!lcl_sys_obj.Get_this_page01.IsPostBack)
init_single_line_text_box (UserTextBox0x, 22);

ph01_ctrl.Add ( new LiteralControl("<br><br>") );
}
/* . . . . . . . . . . . . . */
}
/* - - - - - - - - - - - - - - - - - - - - - - */
/* - - - - - - - - - - - - - - - - - - - - - - */
/* - - - - - - - - - - - - - - - - - - - - - - */

</script>
</head>

<body>

<form runat="server">

<h3> Control Init </h3>

Enter some text and click the Submit button. <br><br>

<asp:PlaceHolder ID="Dyn_Control_Placeholder" runat="server"/>

<asp:Label ID="Message01" runat="server"/>

</form>

</body>
</html>

<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
- wASP
Nov 17 '05 #1
9 17582
This is an example of dynamically adding an event handler to a control. They
are assuming the control is already there.

"wASP" <wylbur[at]ev1[dot]net> wrote in message
news:r6********************************@4ax.com...

Hello again to all of you geniuses,

I'm having a problem trying to load dynamic controls at the initialization
phase.

I've read the docs, and I thought I had it figured out:
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
.NET Framework Class Library

Control.Init Event [C#]

C#
public event EventHandler Init;

Event Data
The event handler receives an argument of type EventArgs.

Remarks
Server controls should perform any initialization steps that are required
to create and set up an instance. You cannot use view-state information
within this event; it is not populated yet. You should not access another
server control during this event, regardless of whether it is a child or
parent to this control. Other server controls are not certain to be
created
and ready for access.

Example
[C#] The following example assigns a custom event handler, Control_Init,
to the Init event of a control, myControl, when the Page_Init method is
called on the page that contains the control.

[C#]
void Page_Init(object sender,EventArgs e)
{
// Add a event Handler for 'Init'.
myControl.Init += new System.EventHandler(Control_Init);
}

void Control_Init(object sender,EventArgs e)
{
Response.Write("The ID of the object initially : " + myControl.ID);
// Change the ID property.
myControl.ID="TestControl";
Response.Write("<br>The changed ID : " + myControl.ID);
}

© 2001-2002 Microsoft Corporation. All rights reserved.

<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>

One thing I don't understand is: Where did "myControl" come from in the
given example?

In my own effort, I tried to attach a literal control to a placeholder:
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>

void Page_Init(object sender,EventArgs e)
{
// Add a event Handler for 'Init'.
// myControl.Init += new System.EventHandler(Control_Init);
PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");
plc_hldr.Init += new System.EventHandler (plc_hldr_Control_Init);
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
Label lbl_msg01 = (Label) FindControl ("Message01");

Dyn_Control_Placeholder.Controls.Add
( new LiteralControl("<br>added 1 on init<br>") );
PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");

lbl_msg01.Text = "The ID of the object initially : " + plc_hldr.ID;
Response.Write("The ID of the object initially : " + plc_hldr.ID);

plc_hldr.Controls.Add ( new LiteralControl("<br>added 2 on
init<br>") );
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>

... and nothing happened - the literal control was not there.

I'm hoping that someone smarter than me can clue me in on this
- I would be most grateful.

My complete code is as follows:
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<%@ Page Language="C#" AutoEventWireup="True" %>

<html>
<head>

<script runat="server">

/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

/* -+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
*/
public class sys_obj_class
{
private ControlCollection pram_ph01_ctrl;
public ControlCollection Get_pram_ph01_ctrl
{ get { return pram_ph01_ctrl; } }

private Page this_page01;
public Page Get_this_page01
{ get { return this_page01; } }

private PlaceHolder Obj_Dyn_Ctrl_Placeholder;
public PlaceHolder Get_Obj_Dyn_Ctrl_Placeholder
{ get { return Obj_Dyn_Ctrl_Placeholder; } }

private Label Obj_Dyn_Label01;
public Label Get_Obj_Dyn_Label01
{ get { return Obj_Dyn_Label01; } }
public sys_obj_class
(PlaceHolder Dyn_Ctrl_Placeholder, Label Dyn_Label)
{ pram_ph01_ctrl = Dyn_Ctrl_Placeholder.Controls;
this_page01 = Dyn_Ctrl_Placeholder.Page;
Obj_Dyn_Ctrl_Placeholder = Dyn_Ctrl_Placeholder;
Obj_Dyn_Label01 = Dyn_Label;
}
}

/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void Page_Init(object sender,EventArgs e)
{
// Add a event Handler for 'Init'.
// myControl.Init += new System.EventHandler(Control_Init);
PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");
plc_hldr.Init += new System.EventHandler(plc_hldr_Control_Init);
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
Label lbl_msg01 = (Label) FindControl ("Message01");
PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");

lbl_msg01.Text = "The ID of the object initially : " + plc_hldr.ID;
Response.Write("The ID of the object initially : " + plc_hldr.ID);

plc_hldr.Controls.Add ( new LiteralControl("<br>added on init<br>") );
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
protected void Page_Load (Object sender, EventArgs e)
{
PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");
Label lbl_msg01 = (Label) FindControl ("Message01");
sys_obj_class sys_obj = new sys_obj_class (plc_hldr, lbl_msg01);

ctrl_pair_creation_01 ccp1 = new ctrl_pair_creation_01 (sys_obj);

ccp1.create_ctrl_pair_01 ();
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

/* - - - - - - - - - - - - - - - - - - - - - - */
/* - - - - - - - - - - - - - - - - - - - - - - */
protected class base_create_ctrl_pair
{
protected TextBox UserTextBox0x;
protected Button button0x;
protected ControlCollection ph01_ctrl;
protected PlaceHolder base_Dyn_Ctrl_Placeholder;
protected Label Dyn_Lbl_msg01;

// constructor
protected base_create_ctrl_pair (sys_obj_class sys_obj)
{ ph01_ctrl = sys_obj.Get_pram_ph01_ctrl;
base_Dyn_Ctrl_Placeholder =
sys_obj.Get_Obj_Dyn_Ctrl_Placeholder;
Dyn_Lbl_msg01 = sys_obj.Get_Obj_Dyn_Label01;
}

protected TextBox create_text_box_control (String text_box_id)
{ // Create UserTextBox TextBox control.
TextBox new_TextBox = new TextBox ();

// Configure the UserTextBox TextBox control.
new_TextBox.ID = text_box_id;

// Add UserTextBox TextBox control to the Controls collection
// of the Dyn_Control_Placeholder PlaceHolder control.
ph01_ctrl.Add (new_TextBox);

return new_TextBox;
}

/* --------------------------------------------------------- *
Example: The following example creates a Button,
sets its DialogResult property to DialogResult.OK,
and adds it to a Form.
* --------------------------------------------------------- */
protected void InitializeMyButton (String Btn_ID, String
Btn_text)
{ // Create and initialize a Button.
button0x = new Button();
button0x.ID = Btn_ID;
button0x.Text = Btn_text;

ph01_ctrl.Add ( new LiteralControl("<br><br>") );
ph01_ctrl.Add (button0x);
}

protected void init_single_line_text_box (TextBox new_TextBox,
int col_sz)
{ new_TextBox.Columns = col_sz; }

protected void create_ctrl_pair_0x
(String TB_ID, String DB_ID, String DB_txt)
{ // Create UserTextBox TextBox control.
UserTextBox0x = create_text_box_control (TB_ID);
InitializeMyButton(DB_ID, DB_txt);
}
/* -+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
*/
private String submit_click_str01 = "The TextBox";

private String submit_click_str02
= " control above is dynamically generated. <br> You
entered: ";
public void Submit_Click (Object sender, EventArgs e)
{ // Retrieve the UserTextBox TextBox control from the
Dyn_Control_Placeholder
// PlaceHolder control.
TextBox TempTextBox = (TextBox)
base_Dyn_Ctrl_Placeholder.FindControl("UserTextBox 1");

// Display the Text property.
Dyn_Lbl_msg01.Text = submit_click_str01 + '1' +
submit_click_str02 +
TempTextBox.Text;
}

/* -+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-
*/

}
/* - - - - - - - - - - - - - - - - - - - - - - */
/* - - - - - - - - - - - - - - - - - - - - - - */
protected class ctrl_pair_creation_01 : base_create_ctrl_pair
{
private sys_obj_class lcl_sys_obj;

// constructor
public ctrl_pair_creation_01 (sys_obj_class sys_obj) : base
(sys_obj)
{ lcl_sys_obj = sys_obj; }

/* . . . . . . . . . . . . . */
public void create_ctrl_pair_01 ()
{ create_ctrl_pair_0x
("UserTextBox1", "DButton01", "Submit 01");

button0x.Click += new EventHandler (Submit_Click);

if (!lcl_sys_obj.Get_this_page01.IsPostBack)
init_single_line_text_box (UserTextBox0x, 22);

ph01_ctrl.Add ( new LiteralControl("<br><br>") );
}
/* . . . . . . . . . . . . . */
}
/* - - - - - - - - - - - - - - - - - - - - - - */
/* - - - - - - - - - - - - - - - - - - - - - - */
/* - - - - - - - - - - - - - - - - - - - - - - */

</script>
</head>

<body>

<form runat="server">

<h3> Control Init </h3>

Enter some text and click the Submit button. <br><br>

<asp:PlaceHolder ID="Dyn_Control_Placeholder" runat="server"/>

<asp:Label ID="Message01" runat="server"/>

</form>

</body>
</html>

<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
- wASP

Nov 17 '05 #2
On Thu, 28 Jul 2005 14:16:18 -0400, "Marina" <so*****@nospam.com> wrote:
This is an example of dynamically adding an event handler to a control. They
are assuming the control is already there.


Hi Marina,

OK - so I'm trying to add a handler to a control that has yet to be instantiated?

Can you give me a clue as to how would I add a dynamic control
to a placeholder before Page_Load gets fired and the viewstate
is recovered on postback?

... or ...

How could I save the viewstate for a specific control (created dynamically)
then recover it on Page_Load? ... THAT is a more important question.
Do you know of any good docs/books that might spell it out for a fool like myself?

I'm a newbie on this - and I've got a lot to learn.

- wASP
Nov 17 '05 #3
No, the control in this example has been instantiated. It exists, it is
declared in the .aspx page, and by the time Init runs it points to a real
object.

In the Init or Load event, you would declare a variable of the type you
want. You would create an instance of whatever object it is you want, and
then add it to your placeholder. Then you would the handler to this object
you just created. If the page has viewstate on, the control should just
maintain its viewstate. You have to do this on every postback.

"wASP" <wylbur[at]ev1[dot]net> wrote in message
news:i8********************************@4ax.com...
On Thu, 28 Jul 2005 14:16:18 -0400, "Marina" <so*****@nospam.com> wrote:
This is an example of dynamically adding an event handler to a control.
They
are assuming the control is already there.


Hi Marina,

OK - so I'm trying to add a handler to a control that has yet to be
instantiated?

Can you give me a clue as to how would I add a dynamic control
to a placeholder before Page_Load gets fired and the viewstate
is recovered on postback?

... or ...

How could I save the viewstate for a specific control (created
dynamically)
then recover it on Page_Load? ... THAT is a more important question.
Do you know of any good docs/books that might spell it out for a fool like
myself?

I'm a newbie on this - and I've got a lot to learn.

- wASP

Nov 17 '05 #4
On Thu, 28 Jul 2005 15:14:08 -0400, "Marina" <so*****@nospam.com> wrote:
No, the control in this example has been instantiated. It exists, it is
declared in the .aspx page, and by the time Init runs it points to a real
object.
Going back to my original post ...

So then this:

PlaceHolder plc_hldr = (PlaceHolder) FindControl ("Dyn_Control_Placeholder");

... should return a valid reference to the placeholder, right?

If not, then how would I get a valid reference?

In the Init or Load event, you would declare a variable of the type you
want. You would create an instance of whatever object it is you want, and
then add it to your placeholder. Then you would the handler to this object
you just created. If the page has viewstate on, the control should just
maintain its viewstate. You have to do this on every postback.
I thought I did that?

/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void Page_Init(object sender,EventArgs e)
{
// Add a event Handler for 'Init'.
PlaceHolder plc_hldr = (PlaceHolder) FindControl ("Dyn_Control_Placeholder");
plc_hldr.Init += new System.EventHandler (plc_hldr_Control_Init);
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
Dyn_Control_Placeholder.Controls.Add
( new LiteralControl("<br>added 1 on init<br>") );
...
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

I also tried doing this:

/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
this.Controls.Add
( new LiteralControl("<br>added 1 on init<br>") );
...
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

... with the same (non)result.
You have to do this on every postback.
I realize this, but I can't even get it to work on the first posting
- never mind postback.

So am I just stupid or som'tin'?

In my own effort, I tried to attach a literal control to a placeholder:
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>

void Page_Init(object sender,EventArgs e)
{
// Add a event Handler for 'Init'.
// myControl.Init += new System.EventHandler(Control_Init);
PlaceHolder plc_hldr = (PlaceHolder) FindControl ("Dyn_Control_Placeholder");
plc_hldr.Init += new System.EventHandler (plc_hldr_Control_Init);
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
Label lbl_msg01 = (Label) FindControl ("Message01");

Dyn_Control_Placeholder.Controls.Add
( new LiteralControl("<br>added 1 on init<br>") );
PlaceHolder plc_hldr = (PlaceHolder) FindControl ("Dyn_Control_Placeholder");

lbl_msg01.Text = "The ID of the object initially : " + plc_hldr.ID;
Response.Write("The ID of the object initially : " + plc_hldr.ID);

plc_hldr.Controls.Add ( new LiteralControl("<br>added 2 on init<br>") );
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>



"wASP" <wylbur[at]ev1[dot]net> wrote in message
news:i8********************************@4ax.com.. .
On Thu, 28 Jul 2005 14:16:18 -0400, "Marina" <so*****@nospam.com> wrote:
This is an example of dynamically adding an event handler to a control.
They
are assuming the control is already there.


Hi Marina,

OK - so I'm trying to add a handler to a control that has yet to be
instantiated?

Can you give me a clue as to how would I add a dynamic control
to a placeholder before Page_Load gets fired and the viewstate
is recovered on postback?

... or ...

How could I save the viewstate for a specific control (created
dynamically)
then recover it on Page_Load? ... THAT is a more important question.
Do you know of any good docs/books that might spell it out for a fool like
myself?

I'm a newbie on this - and I've got a lot to learn.

- wASP


- wASP
Nov 17 '05 #5
Don't you already have a direct reference to this placeholder? You dragged
it on to the page, presumably. Which means a variable got created for it.

"wASP" <wylbur[at]ev1[dot]net> wrote in message
news:uv********************************@4ax.com...
On Thu, 28 Jul 2005 15:14:08 -0400, "Marina" <so*****@nospam.com> wrote:
No, the control in this example has been instantiated. It exists, it is
declared in the .aspx page, and by the time Init runs it points to a real
object.


Going back to my original post ...

So then this:

PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");

... should return a valid reference to the placeholder, right?

If not, then how would I get a valid reference?

In the Init or Load event, you would declare a variable of the type you
want. You would create an instance of whatever object it is you want, and
then add it to your placeholder. Then you would the handler to this
object
you just created. If the page has viewstate on, the control should just
maintain its viewstate. You have to do this on every postback.


I thought I did that?

/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void Page_Init(object sender,EventArgs e)
{
// Add a event Handler for 'Init'.
PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");
plc_hldr.Init += new System.EventHandler (plc_hldr_Control_Init);
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
Dyn_Control_Placeholder.Controls.Add
( new LiteralControl("<br>added 1 on init<br>") );
...
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

I also tried doing this:

/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
this.Controls.Add
( new LiteralControl("<br>added 1 on init<br>") );
...
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

... with the same (non)result.
You have to do this on every postback.


I realize this, but I can't even get it to work on the first posting
- never mind postback.

So am I just stupid or som'tin'?

In my own effort, I tried to attach a literal control to a placeholder:
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>

void Page_Init(object sender,EventArgs e)
{
// Add a event Handler for 'Init'.
// myControl.Init += new System.EventHandler(Control_Init);
PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");
plc_hldr.Init += new System.EventHandler (plc_hldr_Control_Init);
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
Label lbl_msg01 = (Label) FindControl ("Message01");

Dyn_Control_Placeholder.Controls.Add
( new LiteralControl("<br>added 1 on init<br>") );
PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");

lbl_msg01.Text = "The ID of the object initially : " + plc_hldr.ID;
Response.Write("The ID of the object initially : " + plc_hldr.ID);

plc_hldr.Controls.Add ( new LiteralControl("<br>added 2 on
init<br>") );
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>



"wASP" <wylbur[at]ev1[dot]net> wrote in message
news:i8********************************@4ax.com. ..
On Thu, 28 Jul 2005 14:16:18 -0400, "Marina" <so*****@nospam.com> wrote:

This is an example of dynamically adding an event handler to a control.
They
are assuming the control is already there.

Hi Marina,

OK - so I'm trying to add a handler to a control that has yet to be
instantiated?

Can you give me a clue as to how would I add a dynamic control
to a placeholder before Page_Load gets fired and the viewstate
is recovered on postback?

... or ...

How could I save the viewstate for a specific control (created
dynamically)
then recover it on Page_Load? ... THAT is a more important question.
Do you know of any good docs/books that might spell it out for a fool
like
myself?

I'm a newbie on this - and I've got a lot to learn.

- wASP


- wASP

Nov 17 '05 #6
> PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");
plc_hldr.Init += new System.EventHandler(plc_hldr_Control_Init);


You can replace that with:

Dyn_Control_Placeholder.Init += new
System.EventHandler(plc_hldr_Control_Init);

Elements on the page are accessible by their ID.

I don't understand why your plc_hldr_Control_Init isn't called though. I
tried a very simple sample, with this code:

void Page_Init(object sender, EventArgs e)
{
myControl.Init += new System.EventHandler(Control_Init);
}

void Control_Init(object sender, EventArgs e)
{
Response.Write("Control_Init called);
}

I could break on the Page_Init() function, but the breakpoint in
Control_Init() never went off. Perhaps someone else has a clue ?

Greetings,
Wessel
Nov 17 '05 #7
On Thu, 28 Jul 2005 15:40:44 -0400, "Marina" <so*****@nospam.com> wrote:
Don't you already have a direct reference to this placeholder? You dragged
it on to the page, presumably. Which means a variable got created for it.
I'm afraid I didn't drag anything onto any pages: I'm not using studio.
I'm just using notepad at this point.

I tried using Wessel's suggestion:

Dyn_Control_Placeholder.Init += new
System.EventHandler(plc_hldr_Control_Init);

... and that didn't work either.

wASP
==============================

"wASP" <wylbur[at]ev1[dot]net> wrote in message
news:uv********************************@4ax.com.. .
On Thu, 28 Jul 2005 15:14:08 -0400, "Marina" <so*****@nospam.com> wrote:
No, the control in this example has been instantiated. It exists, it is
declared in the .aspx page, and by the time Init runs it points to a real
object.


Going back to my original post ...

So then this:

PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");

... should return a valid reference to the placeholder, right?

If not, then how would I get a valid reference?

In the Init or Load event, you would declare a variable of the type you
want. You would create an instance of whatever object it is you want, and
then add it to your placeholder. Then you would the handler to this
object
you just created. If the page has viewstate on, the control should just
maintain its viewstate. You have to do this on every postback.


I thought I did that?

/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void Page_Init(object sender,EventArgs e)
{
// Add a event Handler for 'Init'.
PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");
plc_hldr.Init += new System.EventHandler (plc_hldr_Control_Init);
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
Dyn_Control_Placeholder.Controls.Add
( new LiteralControl("<br>added 1 on init<br>") );
...
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

I also tried doing this:

/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
this.Controls.Add
( new LiteralControl("<br>added 1 on init<br>") );
...
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

... with the same (non)result.
You have to do this on every postback.


I realize this, but I can't even get it to work on the first posting
- never mind postback.

So am I just stupid or som'tin'?

In my own effort, I tried to attach a literal control to a placeholder:
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>

void Page_Init(object sender,EventArgs e)
{
// Add a event Handler for 'Init'.
// myControl.Init += new System.EventHandler(Control_Init);
PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");
plc_hldr.Init += new System.EventHandler (plc_hldr_Control_Init);
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
Label lbl_msg01 = (Label) FindControl ("Message01");

Dyn_Control_Placeholder.Controls.Add
( new LiteralControl("<br>added 1 on init<br>") );
PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");

lbl_msg01.Text = "The ID of the object initially : " + plc_hldr.ID;
Response.Write("The ID of the object initially : " + plc_hldr.ID);

plc_hldr.Controls.Add ( new LiteralControl("<br>added 2 on
init<br>") );
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */

<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>



"wASP" <wylbur[at]ev1[dot]net> wrote in message
news:i8********************************@4ax.com ...
On Thu, 28 Jul 2005 14:16:18 -0400, "Marina" <so*****@nospam.com> wrote:

>This is an example of dynamically adding an event handler to a control.
>They
>are assuming the control is already there.

Hi Marina,

OK - so I'm trying to add a handler to a control that has yet to be
instantiated?

Can you give me a clue as to how would I add a dynamic control
to a placeholder before Page_Load gets fired and the viewstate
is recovered on postback?

... or ...

How could I save the viewstate for a specific control (created
dynamically)
then recover it on Page_Load? ... THAT is a more important question.
Do you know of any good docs/books that might spell it out for a fool
like
myself?

I'm a newbie on this - and I've got a lot to learn.

- wASP


- wASP


- wASP
Nov 17 '05 #8
On Thu, 28 Jul 2005 21:49:59 +0200, "Wessel Troost" <no*****@like.the.sun> wrote:
PlaceHolder plc_hldr = (PlaceHolder) FindControl
("Dyn_Control_Placeholder");
plc_hldr.Init += new System.EventHandler(plc_hldr_Control_Init);
You can replace that with:

Dyn_Control_Placeholder.Init += new
System.EventHandler(plc_hldr_Control_Init);

Elements on the page are accessible by their ID.


I just tried replacing my FindControl with this - it didn't do any good
- same (non)result.

I don't understand why your plc_hldr_Control_Init isn't called though. I
tried a very simple sample, with this code:

void Page_Init(object sender, EventArgs e)
{
myControl.Init += new System.EventHandler(Control_Init);
}

void Control_Init(object sender, EventArgs e)
{
Response.Write("Control_Init called);
}

I could break on the Page_Init() function, but the breakpoint in
Control_Init() never went off. Perhaps someone else has a clue ?

Greetings,
Wessel


THAT is not good - not good at all. :-(

Can you try it with my code?
This is the only change from the code in my first post:
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void Page_Init(object sender,EventArgs e)
{
// Add a event Handler for 'Init'.
Dyn_Control_Placeholder.Init
+= new System.EventHandler (plc_hldr_Control_Init);
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ */
void plc_hldr_Control_Init (object sender,EventArgs e)
{
Label lbl_msg01 = (Label) FindControl ("Message01");

// Dyn_Control_Placeholder.Controls.Add
this.Controls.Add
( new LiteralControl ("<br>added 1 on init<br>") );
}
/* ------------------------------------------------------------------ */
/* ------------------------------------------------------------------ *

Maybe it's time I started thinking about getting an IDE - Studio perhaps?

Does anyone have any suggestions?

- wASP
Nov 17 '05 #9

OK.

It seems to me that the only reason why I would want to create dynamic controls
in the initialization stage (Page_Init) would be to maintain viewstate.

If I were to save the viewstates for the dynamic controls by overriding
the functions with my own, then I could load everything during the Page_Load event
- and THEN load the viewstates for those controls at that time of the cycle
- and just sidestep the whole Page_Init problem entirely.

I've been reviewing the docs, and these are the given examples for those controls:
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>

Example

The following example overrides the SaveViewState method in a custom ASP.NET server
control.
When this method is invoked, it determines whether the control has any child controls
and whether the containing Page object is the result of a postback. If both are true,
it changes the Text property of a Label Web server control to read Custom Control Has
Saved State. It then saves the view state of the control as an array of objects,
named allStates.

protected override object SaveViewState()
{ // Change Text Property of Label when this function is invoked.
if(HasControls() && (Page.IsPostBack))
{
((Label)(Controls[0])).Text = "Custom Control Has Saved State";
}
// Save State as a cumulative array of objects.
object baseState = base.SaveViewState();
string userText = UserText;
string passwordText = PasswordText;
object[] allStates = new object[3];
allStates[0] = baseState;
allStates[1] = userText;
allStates[2] = PasswordText;
return allStates;
}

<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>

I can follow that, but what do I do about non-textual controls?
... such as radio buttons?

Would I have to design my own logic to recover the states for those?

That isn't an insurmountable problem (I don't think), but if there is
already a mechanism for doing this, then I wouldn't have to bother.

Do all of the elements in the "allStates" object have to be strings?
... or can I give it ANY type?

I'm thinking that the data stored within that viewstate object
would be in the same direct binary format as it is presented by the control
- as would have to be the case for the recovery of ALL viewstates
- whether it's done automatically or by explicit invocation.

OK - and here's where I need experienced input and perspective ...

Are there any potential pitfalls that I should be aware of in taking this course?

I have a feeling that this isn't going to be as simple as I think it might be.

This is the given example for the LoadViewState method:
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>

Example

The following example overrides the LoadViewState method for a custom ASP.NET
server control. It creates an Object array to contain the view state information
passed in the savedState parameter, and then calls the base implementation of
the LoadViewState method for the first index location of the array. It assigns
the values stored at the next two index locations to variables named UserText
and PasswordText, respectively.

protected override void LoadViewState(object savedState)
{
if (savedState != null)
{
// Load State from the array of objects that was saved at ;
// SavedViewState.
object[] myState = (object[])savedState;
if (myState[0] != null)
base.LoadViewState(myState[0]);
if (myState[1] != null)
UserText = (string)myState[1];
if (myState[2] != null)
PasswordText = (string)myState[2];
}
}
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>-<[+]>
- wASP
Nov 17 '05 #10

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

6
by: Mark | last post by:
I have been working for quite some time on this issue which in theory should be quite simple. The problem is that the Cancel and Save events are not fired when their respective buttons are...
4
by: Tom Wisnowski | last post by:
Hello all, Here is a simple example of what I'm doing... Create a ASPX page Add a PlaceHolder(plch) and a Button(btn) to the page. In the code behind on Page_load add the following......
4
by: Chuck Ritzke | last post by:
Hi, I've searched the newsgroup and other sources to understand how to handle runtime controls and see I'm not the only one who's confused, but I'm still not quite sure of the best way to handle...
3
by: Leo J. Hart IV | last post by:
OK, here's another question for the experts: I am building a multi-step (3 steps actually) form using a panel for each step and hiding/displaying the appropriate panel/panels depending on which...
0
by: Phl | last post by:
Hi, I am trying to create an webform which loads usercontrols dyanamically. I know exactly what to load for some of these controls but for some, I dont want to load it until the user has press a...
0
by: jonelling | last post by:
I am having a problem where the page load event is not being fired for certain user controls that I load dynamically in placeholders. Here is what I'm doing in brief, with full test code supplied...
13
by: rn5a | last post by:
In a shopping cart app, suppose a user has placed 5 orders, I want to show him 5 LinkButtons (one for each order) so that when he clicks the first LinkButton, he would be shown the details of his...
2
by: BillE | last post by:
I have a web form which has dynamic controls for order entry, (item selected, #,etc.) which are wired to an event handler which fires when the dynamic controls content changes. These controls...
4
Frinavale
by: Frinavale | last post by:
Introduction Sometimes, when developing web applications, we need to be able to dynamically load controls based on user selections. The following article describes a simple scenario where TextBox...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.