dynamic-controls

Create an exact copy of TPanel on Delphi5

I have a TPanel pnlMain, where several dynamic TPanels are created (and pnlMain is their Parent) according to user actions, data validations, etc. Every panel contains one colored grid full of strings. Apart from panels, there are some open source arrows components and a picture. Whole bunch of stuff. Now I want user to be able to print...

dynamic dropdownlist in asp.net

hello I created dropdownlist at runtime when a button is clicked.and i palced another button to get the selected text from dynamic dropdownlist.When i try to retrieve the selected text from dropdownlist it gives me the error called object reference not set, following is my code. TableRow tr; TableCell tc; DropDownList dp; T...

When to create controls dynamically, so that when I click a button I can save their values?

I am creating some textboxes dynamically and I try to get their values when I click a button, but they are gone. I create the text boxes (declaration, initialization, adding them to the place holder) in another click button event. What shall I change to be able to read their values? ...

Error on setting TDateTimePicker.Font.Style to italic in Delphi 5

Is it possible to set TDateTimePicker’s font to italic? I am doing it in this code var DatEdit : TDateTimePicker; begin //I know Canvas is a stupid name for TPanel DatEdit:=TDateTimePicker.Create(Canvas); DatEdit.OnEnter := CtrlInputProc; DatEdit.OnExit := CtrlExitProc; DatEdit.Enabled := false; DatEdit.Font.Style := DatE...

C# dynamically created control issue

i'm having issues retreiving the values out of a dynamically created dropdownlist. all controls are created in the Page_Init section. the listitems are added at that time as well from an array of listitems. (the controls are named the same so should be accessable to the viewstate for appropriate setting.) here is the function that at...

wpf dynamic window

Hello I am trying to create a window to act as a switch board for testing an application I'm working on, and having two problems doing so. The first problem is trying to set the size & margin of buttons that need to be added to a stack panel dynamically. In XAML, the properties look like this: <StackPanel Name="_mainStackPanel" > ...

Controls are empty after submit

I have a checkboxlist and textbox controls on my asp.net page and the are dynamically created and added to the page. When I populate the values and submit the form, the values are empty by the time it hits the server. Any help? ...

ViewState error: Concurrent users modifying dynamic controls.

Have a page that adds controls dynamically. Control state is being retrieved from database and controls are re-added to page on postback. User can add/delete controls through UI. When two users are on the same page and one adds/removes controls the other user will get ViewState error next time he tries to modify control state. "Failed ...

Add dynamic controls in ASP.NET, is there a difference between 1.1 and 2.0?

I am pretty sure back in the days of ASP.NET 1.0/1.1, controls created during runtime needs to be added before Page_Load event of the Page Lifecycle (i.e. inside Page_Init). Here's one article by Microsoft on it (for .NET 1.0/1.1): HOW TO: Dynamically Create Controls in ASP.NET: Note When you create dynamic controls on a Web Form,...

Dynamic control and its Event

Hi all, We are creating dynamic text boxes and buttons inside a grid for each row. Now we want to create click event for each button. Tocreate button inside the grid in using ITemplate. Code: ImageButton imbtnAdd = new ImageButton(); imbtnAdd.ID = "imbtn" + columnName; imbtnAdd.ImageUrl = "btn_add_icon....

How Do I Get a Dynamic Control's Value after Postback?

I have a listview that adds controls in the ItemDataBound Event. When the postback occurs, I cannot find the new controls. After a bit of research, I found that ASP .NET needs these controls created every time, even after postback. From there I moved the function to bind the ListView outside of the if (!Page.IsPostBack) conditional. ...

Dynamic textbox inside gridview

Hi all, We are creating dynamic textbox inside the gridview. Without entering data in the textbox the tab key is working fine. But pressing tab key after entering values in the textbox creating problem like 1. Grid getting refresh 2. cursor is not in the next textbox. Regards, Geetha ...

Silverlight Dynamic Control not displaying

I have a simple control with code to add some paths. When I add my control to the control canvas, nothing shows up. To make sure that I wasn't crazy, I debugged through the code, and created a XAML equivalent and placed it off to the side of where my control should be showing up. I've tried changing the z-index and various Top/Left combi...

Register the dynamic control using jquery for autocomplete

i am creating the textboxes dynamically using jquery on a button click. <table width="100%" border="0" cellpadding="0" cellspacing="0"> <tr> <td> <div id="lblCustName"> </div> </td> <td> <div id="lblRemove"> </div> </t...

how to post a dynamically created fields in a table using jquery / asp.net mvc

I have a button that will create a new entry (row in a table) dynamically using jquery. Each entry is a row in a html table. for each row, each column has an input (textbox, radio button, checkbox) etc. because you can add as many rows as you like you end up with some array or collection of these rows. When i post the form, i dont ...

how to create gridview dynamicaly in content page asp.net 2.0?

As the dynamically gridview can only be placed in form which is runat server.so when i tried to gridview dynamically in content view like form1.Controls.Add(grid), i got the error like there must be only single form tag.now the problem is that i cannot place form tag in content page as well as i can't use the form tag of the master page....

Dynamic Controls State Management - View State Vs Database

Hi All, What is the best option to store data pertaining to dynamic controls. Here is my scenario. At any time around 5 to 15 master tables to retreive from. Dynamic Controls can be of type TextBox, DropDownList, ListBox, GridView. Master's are not going to change on postback, but page will incur many postbacks in a same session. I'm...

LoadControl in static/shared function

Anyone know how I can dynamically load a control inside of a shared/static function? The function itself is inside of a mustinherit/abstract class. (It's an ASP.NET project in VB) I want to do something like this: VB: Public Shared Function GetWidget(ByVal name As WidgetName) As Control Select Case name Case Wi...

Dynamically adding a textbox to a panel on button click

I just don't understand how this is done. I've gone through several questions here and from a few other websites. Basically, a company will be adding process steps, and I want there to be a textbox with a button next to it that reads "Add another step." Once clicked, a new textbox will appear beneath the current one, and the button will...

building dynamic controls on postback (asp.net)

I'm sure this has been answered but I cannot find it...perhaps because the terms are used for so many differing questions...anyway. how is the best way to store information about building dynamic controls on postback etc in the init event... e.g. take the classic "questionnaire" scenario...question.aspx?id=1 get the id from the que...