473,466 Members | 1,290 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

User Control Renders on Separate Line

jdp
I've created a user control that I then place in a panel. The reason
it's in a panel is that it's part of search criteria that I hide/show
panels based on the type of search begin done. I can place a label
next to this control in the IDE and it looks fine but when I run the
app, the label is on the line above the control. I've tried placing
the label INSIDE the control, placing the user control inside a <div>
and allowing objects on either side and the same effect occurred.

Any help would be greatly appreciated.

Thanks.

Aug 4 '06 #1
5 1244
If you want them to appear next to each other, the easiest solution is to
build a two celled table.
Put the label in the left cell and the control in the right hand cell.

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
"jdp" <ja***********@pacourts.uswrote in message
news:11**********************@75g2000cwc.googlegro ups.com...
I've created a user control that I then place in a panel. The reason
it's in a panel is that it's part of search criteria that I hide/show
panels based on the type of search begin done. I can place a label
next to this control in the IDE and it looks fine but when I run the
app, the label is on the line above the control. I've tried placing
the label INSIDE the control, placing the user control inside a <div>
and allowing objects on either side and the same effect occurred.

Any help would be greatly appreciated.

Thanks.

Aug 4 '06 #2
jdp
Thanks for the reply.

I'm writing this site that has to be accessible to people with
disabilities. I'm under the impression that tables should only be used
to render data. Would the solution you're suggesting no longer be
valid or would the special screen readers interpret this correctly?

Thanks again.
Steve C. Orr [MVP, MCSD] wrote:
If you want them to appear next to each other, the easiest solution is to
build a two celled table.
Put the label in the left cell and the control in the right hand cell.

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
Aug 4 '06 #3
In that case tables might not be such a great solution.
Would absolute positioning help?

Here's more info:
http://SteveOrr.net/articles/ControlPositioning.aspx

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net

"jdp" <ja***********@pacourts.uswrote in message
news:11**********************@s13g2000cwa.googlegr oups.com...
Thanks for the reply.

I'm writing this site that has to be accessible to people with
disabilities. I'm under the impression that tables should only be used
to render data. Would the solution you're suggesting no longer be
valid or would the special screen readers interpret this correctly?

Thanks again.
Steve C. Orr [MVP, MCSD] wrote:
>If you want them to appear next to each other, the easiest solution is to
build a two celled table.
Put the label in the left cell and the control in the right hand cell.

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net

Aug 4 '06 #4
jdp
Thanks, I'll give it a read.

I don't know if you saw my other question in the other groups or not
but I'm trying to build a user control where, at design time, a
developer modifying a property will see those changes immediately
rather than at run time. For example, the control has a label in it
and the control exposes a LabelText property. If I set this property
at design time, I don't see the change until run time.

Any thoughts you might have or are able to point me in the right
direction would be greatly appreciated.

Thanks again.

Steve C. Orr [MVP, MCSD] wrote:
In that case tables might not be such a great solution.
Would absolute positioning help?

Here's more info:
http://SteveOrr.net/articles/ControlPositioning.aspx

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net

Aug 7 '06 #5
jdp
I found my problem: the user control had a <divelement defined. Once
I removed that, everything works great!

Thanks for you help!
Steve C. Orr [MVP, MCSD] wrote:
In that case tables might not be such a great solution.
Would absolute positioning help?

Here's more info:
http://SteveOrr.net/articles/ControlPositioning.aspx

--
I hope this helps,
Steve C. Orr, MCSD, MVP
http://SteveOrr.net
Aug 8 '06 #6

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

Similar topics

2
by: Sunny | last post by:
Hi, I have a usercontrol defined as: <P> <a id="sectionName" runat="server"></a> <asp:PlaceHolder id="detailsBody" runat="server"> </asp:PlaceHolder> <br> <asp:HyperLink id="hrefTop"...
4
by: Remi Hugnon | last post by:
Hi, I want to build an expandable treeview. I saw some code on VB but I know only C# I plan for my class that each nodes has its own id (using span for example). Into a single aspx page...
1
by: Joe Fallon | last post by:
I have a simple user control that I use for the footer of each page. It has one line of text with things link comapny name and a few hyperlinks to jump to other pages. If I want to use partial...
4
by: DotNetJunkies User | last post by:
I have created a User Control (a Pareto Chart) using C#. It works great in .Net Windows Apps, but I also need to use it in a Web Application (to view in IE). Everything I read on this seems to be...
6
by: Rob Morgan | last post by:
I have a grid and a user control on the same page. The user control has a save button that triggers a click event server side. Once the click event happens the page renders, but I need to update...
1
by: Mark | last post by:
What is the difference between a "user control" for Web Forms vs. Windows Forms? I have extensive use of user controls (.NET 1.1) in Web forms. Just wondering how they differ for Windows Forms. ...
5
by: paul.hester | last post by:
Hi all, I have a custom control with an overridden Render method. Inside this method I'm rendering each control in its collection using their RenderControl method. However, I'm running into a...
9
by: Nathan Sokalski | last post by:
I am using ASP.NET 2.0's ImageMap Control to create 2 imagemaps, one directly below the other. When I do this a thin blank space appears between them. After several days of frustration I realized...
2
by: =?Utf-8?B?UmljaA==?= | last post by:
On my development machine where I have Visual Studio 2005 loaded, I have an app that uses the Report control. I can view data in report format with the Report control -- the data renders OK in the...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
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
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
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
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...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

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.