|
-
June 27th, 2007, 11:33 PM
#1
label runtime width
I am trying to set width of labels at runtime.
I tried lablel1.width=Unit.Pixel(50);
and
label1.width=Unit.Point(50);
I even tried lable.controlstyle.width, but nothing seems to work for me .at runtime the width of the label seems to get truncated.can anyone tell me how it can be done successfully.
-
June 28th, 2007, 10:00 AM
#2
Re: label runtime width
have you tried just
Code:
this.label1.width = 50;
hth,
mcm
rate my posts!
mcm
-
June 28th, 2007, 12:41 PM
#3
-
June 28th, 2007, 02:26 PM
#4
Re: label runtime width
are you sure your actually modifing the right label? is there a label on the page with the id "label1"? Or are you creating it from code? If it IS on the page already when you type
"this.label1" does the auto-complete and code hinting box come up with the available properties for a label object? Perhaps your just setting the width of a reference to a label, not an actual label itself.
hth,
mcm
rate my posts!
mcm
-
June 29th, 2007, 10:42 AM
#5
Re: label runtime width
its a pretty complecated thing i am doing.its a sharepoint 2007 site.i am developing a webpart through class library project.there i am creating labels at runtime.everything works, except the label width.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|