473,509 Members | 11,437 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Part of checkbox.Text is not displaying

3 New Member
This is probably a stupid question but why is part of my text missing when I add a checkbox to my panel?

Displays fine:
ASLThoracic.Text = "L Thoracic";
ASLThoracic.Text = "L Thoracic/Lum";

Only displays "L":
ASLThoracic.Text = "L Thoracic/Lumbar";

I've tried moving it around on the page to make sure it isn't being cut off by another checkbox or label. I've also extended the width of the panel but that doesn't seem to help either.
Jul 20 '10 #1
3 8347
GaryTexmo
1,501 Recognized Expert Top Contributor
Is the checkbox itself wide enough to contain the text?

Check to see if the AutoSize property is set to false.
Jul 20 '10 #2
thirdconspiracy
3 New Member
I did not define a size or any settings so it should all be default. Here is it is in full.

public Panel panelOne()
{
Panel panel1 = new Panel();
panel1.Location = new Point(0, 0);
panel1.Size = new Size(296, 400);
panel1.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;

Label LowerExtremity = new Label();
CheckBox LELAnkle = new CheckBox();
CheckBox LERAnkle = new CheckBox();
CheckBox LELKnee = new CheckBox();
CheckBox LERKnee = new CheckBox();
CheckBox LELHip = new CheckBox();
CheckBox LERHip = new CheckBox();
Label UpperExtremity = new Label();
CheckBox UELWrist = new CheckBox();
CheckBox UERWrist = new CheckBox();
CheckBox UELElbow = new CheckBox();
CheckBox UERElbow = new CheckBox();
CheckBox UELShoulder = new CheckBox();
CheckBox UERShoulder = new CheckBox();
Label AxialSkeleton = new Label();
CheckBox ASLThorax = new CheckBox();
CheckBox ASRThorax = new CheckBox();
CheckBox ASLHead = new CheckBox();
CheckBox ASRHead = new CheckBox();
CheckBox ASLLumbar = new CheckBox();
CheckBox ASRLumbar = new CheckBox();
CheckBox ASLThoracic = new CheckBox();
CheckBox ASRThoracic = new CheckBox();
CheckBox lSelectAll = new CheckBox();
CheckBox rSelectAll = new CheckBox();

LowerExtremity.Text = "Lower Extremity";
LELAnkle.Text = "L Ankle";
LERAnkle.Text = "R Ankle";
LELKnee.Text = "L Knee";
LERKnee.Text = "R Knee";
LELHip.Text = "L Hip";
LERHip.Text = "R Hip";
UpperExtremity.Text = "Upper Extremity";
UELWrist.Text = "L Wrist";
UERWrist.Text = "R Wrist";
UELElbow.Text = "L Elbow";
UERElbow.Text = "R Elbow";
UELShoulder.Text = "L Shoulder";
UERShoulder.Text = "R Shoulder";
AxialSkeleton.Text = "Axial Skeleton";
ASLThorax.Text = "L Thorax/Pelvis";
ASRThorax.Text = "R Thorax/Pelvis";
ASLHead.Text = "L Head/Thorax";
ASRHead.Text = "R Head/Thorax";
ASLLumbar.Text = "L Lumbar/Pelvis";
ASRLumbar.Text = "R Lumbar/Pelvis";
ASLThoracic.Text = "L Thoracic";
//ASLThoracic.Text = "L Thoracic/Lumbar";
// for some reason when you put the last part on there, it doesn't show up
ASRThoracic.Text = "R Thoracic/Lumbar";
lSelectAll.Text = "Select All";
rSelectAll.Text = "Select All";

LowerExtremity.Location = new Point(15, 16);
LELAnkle.Location = new Point(15, 34);
LELKnee.Location = new Point(15, 52);
LELHip.Location = new Point(15, 70);
UpperExtremity.Location = new Point(15, 94);
UELWrist.Location = new Point(15, 112);
UELElbow.Location = new Point(15, 130);
UELShoulder.Location = new Point(15, 148);
AxialSkeleton.Location = new Point(15, 172);
ASLThorax.Location = new Point(15, 190);
ASLHead.Location = new Point(15, 208);
ASLLumbar.Location = new Point(15, 226);
ASLThoracic.Location = new Point(15, 246);
lSelectAll.Location = new Point(15, 280);

//LERAnkle.Location = new Point(
//LERKnee.Location = new Point(
//LERHip.Location = new Point(
//UERWrist.Location = new Point(
//UERElbow.Location = new Point(
//UERShoulder.Location = new Point(

//ASRThorax.Location = new Point(
//ASRHead.Location = new Point(
//ASRLumbar.Location = new Point(
//ASRThoracic.Location = new Point(
//rSelectAll.Location = new Point(

panel1.Controls.Add(LowerExtremity);
panel1.Controls.Add(LELAnkle);
panel1.Controls.Add(LELKnee);
panel1.Controls.Add(LELHip);
panel1.Controls.Add(UpperExtremity);
panel1.Controls.Add(UELWrist);
panel1.Controls.Add(UELElbow);
panel1.Controls.Add(UELShoulder);
panel1.Controls.Add(AxialSkeleton);
panel1.Controls.Add(ASLThorax);
panel1.Controls.Add(ASLHead);
panel1.Controls.Add(ASLLumbar);
panel1.Controls.Add(ASLThoracic);
panel1.Controls.Add(lSelectAll);
return panel1;
}
Jul 20 '10 #3
thirdconspiracy
3 New Member
I fixed it by adding:
ASLThoracic.AutoSize = true;

Thank you GaryTexmo!
Jul 20 '10 #4

Sign in to post your reply or Sign up for a free account.

Similar topics

1
11709
by: Kb | last post by:
Hi all, I have an asp:checkbox on a form, and i added onclick attribute to it. When the checkbox is clicked I want to add its text to a textbox. But I can't get its text. The checkbox is rendered...
0
924
by: SirPoonga | last post by:
I am using Web Matrix to create my ASP page. I have a checkbox that I want text to the left of it. Teh way the code is going to work is when you check the checkbox it will enable a dropdown box. ...
0
1502
by: tshad | last post by:
How do you (or can you) align the text vertically on a checkbox control? You can move the whole control (text and box) up or down and you can use textalign to align the text left or right. The...
3
3592
by: Jim Bancroft | last post by:
Hi everyone, This is a silly one I'm sure, but I'm having a whale of a time putting some text into my asp checkbox. Here's what I'd like to do: <asp:CheckBox runat="server"...
3
4289
by: Bahman | last post by:
Hello! May be I am missing something. In the library it says the property is called 'TextAlign' or some such thing. But nothing works here like that. Is the library up to date or am I...
3
6231
by: mpmason14 | last post by:
i tried to convert the yes/no TEXT value in a form to a CHECKBOX and the values all went to 0 (NO) on me and there was no way for me to reverse it. regardless, i need to find a way to convert the...
1
1603
by: neilr | last post by:
MSDN lists .text as a propoerty of the asp check obox but can anyone help me to find out how to access it? We have a panel at the top of our list forms that allows the user to select which columns...
1
2079
by: hariharan2105 | last post by:
I have an single column document. How would I render a small part of text (say, figure caption) in two columns. I use Apache FOP. Any suggestions?
4
2894
by: aditya2 | last post by:
I am having problem displaying the contents of array into Smarty Checkbox in HTML The details of array $people are: $people = Array ( => Allen Jamie => Browning Andy => Barrett Rich =>...
0
7237
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
7137
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
7349
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,...
1
7074
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
5659
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,...
1
5063
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
3210
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
780
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
0
445
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

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.