473,378 Members | 1,377 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,378 software developers and data experts.

Position Web control within Panel on Web Form ... programatically

M-
Is it possible to position a Web Form control within a
Panel ... programattically? That is, by adding lines to
the following code:
protected System.Web.UI.WebControls.Panel Panel1;

private void Page_Load(object sender, System.EventArgs e)
{
Panel1.BackColor= System.Drawing.Color.White;
Panel1.Height=95;
Panel1.Width=200;
System.Web.UI.WebControls.DropDownList DDL1 = new
DropDownList();
DDL1.Height=30;
DDL1.Width=120;
Panel1.Controls.Add(TB2);
}

or, some other way?

Thanks.

Nov 17 '05 #1
1 3225
M-
An sample code - server-side or client-side would be
appreciated.

-----Original Message-----
Is it possible to position a Web Form control within a
Panel ... programattically? That is, by adding lines to
the following code:
protected System.Web.UI.WebControls.Panel Panel1;

private void Page_Load(object sender, System.EventArgs e)
{
Panel1.BackColor= System.Drawing.Color.White;
Panel1.Height=95;
Panel1.Width=200;
System.Web.UI.WebControls.DropDownList DDL1 = new
DropDownList();
DDL1.Height=30;
DDL1.Width=120;
Panel1.Controls.Add(TB2);
}

or, some other way?

Thanks.

.

Nov 17 '05 #2

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

Similar topics

1
by: Dune | last post by:
Saw a post a about hiding a panel using javascript a while back and that got me curious and i tried it out. I have a Panel control with id equal to PanelId and it is nested inside a form tag...
2
by: Joe Au | last post by:
I first add a grid layout panel control to a web form, then put a data grid inside the panel. When I run the web form, the data grid is filled up but it throws outside the panel control. The panel...
0
by: Joe Au | last post by:
I create a simple web form with a data grid and a panel control. The code is shown here: <asp:DataGrid id="DataGrid1" style="Z-INDEX: 101; LEFT: 120px; POSITION: absolute; TOP: 56px"...
1
by: Rob R. Ainscough | last post by:
I'm at a new level of frustration just trying to get my controls to line up and stay in place. I'm using a MultiView containing 4 views - some views have Panels. I can't use absolution position...
10
by: Yuk Tang | last post by:
Another step on the road to enlightenment, aka producing a UI. I've added a webbrowser control to a form, and I want it to fill the space of the form. Playing around with docking, left, top,...
2
by: Paul E Collins | last post by:
I'm writing an application whose main window consists of a particular UserControl that I have placed inside a docked Panel so that it will fill the whole window. The panel also has the AutoScroll...
15
by: rizwanahmed24 | last post by:
Hello i have made a custom control. i have placed a panel on it. I want this panel to behave just like the normal panel. The problem i was having is that the panel on my custom control doesnt...
4
by: =?Utf-8?B?UmljaEI=?= | last post by:
I am trying to create a project using the ASP.NET AJAX accordion control. I would like to dynamically add panes to the control with a form template added when the pane is added. I have tried...
7
by: RichB | last post by:
I am trying to get to grips with the asp.net ajaxcontrol toolkit, and am trying to add a tabbed control to the page. I have no problems within the aspx file, and can dynamically manipulate a...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 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 former...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

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.