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

Page & Control Scaling?

Hello Everyone!

I am curious if anyone has done anything so automate the scaling of controls
based on screen resolution. In my case I have a minimum screen res of
1024x768 for my page size, which I designed to, but I know a lot of people
are now using 1280+ and am looking for any examples of ways to in code behind
do something like this.

if (screen.width < 1024)
{
string controlwidth = screen.width.value / 30%
contol1.width = controlwidth
}

I know this is very crude but has anyone seen something that can do this on
the web? I have a couple of controls and tables that I am using that have
assigned sizes that I would like to change on the fly if possible!

--
D @ premierdata
Nov 19 '05 #1
1 1216
Hi Dewright,

As for the auto adjusting Control's size according to clientside's Screen
Size question, here are some of my suggetions:

For WebApplication, client user visit the application through webbrowser
and most browsers provide some interfaces for retrieving clientside
environment info. And screenSize is one of them, however since this is a
clientside setting ,we need at least one round trip to the clientside to
gather this info. Also, I've found that we've discussed this question in a
former thread, and I've mentioend a means that use a central information
gather page(or an httphandler), all the session that dosn't contains clietn
screen size info will be redirected to that page/handler first. How do you
think of it?

#Control Scaling???
http://groups-beta.google.com/groups...8lBTw1J7xZp3d4
p9GYnQB_MuUCIzG_J0TEfwmEXeyg

Thanks,

Steven Cheng
Microsoft Online Support

Get Secure! www.microsoft.com/security
(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Nov 19 '05 #2

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

Similar topics

179
by: SoloCDM | last post by:
How do I keep my entire web page at a fixed width? ********************************************************************* Signed, SoloCDM
2
by: Christopher Ambler | last post by:
I'm wondering if there's a solution here - I have an ASPX page with a sole purpose of scaling an image. The ASPX page contains a single line with the codebehind tag, and the .cs file contains...
1
by: AndrewF | last post by:
Hi there, I have racked my brains for days on this and can't seem to find a solution. I have a form which is dynamically creating some text boxes on it. The text boxes are single line ones. ...
7
by: GaryDean | last post by:
In my old 1.1 apps the default was MS_POSITIONING="GridLayout" and Textboxes and labels and such always had POSITION: absolute; and I never had any distortion when the page was rendered. Life was...
3
by: Joseph Gruber | last post by:
Hi all -- I have two questions. First, I'm adding a control to my form at runtime and the control/form seems to ignore the anchor property of the runtime control. Any idea how I can get a...
0
by: CO2 | last post by:
And here is my second problem while converting webpages to pdf: Scaling large images to fit to the page. I was using the follwing code to scale the images: <fo:external-graphic src="{@src}"...
0
by: igalep132 | last post by:
Hey all, I was trying to resize control size to the form size. I'm changing my form size according to current Screen Size by using Screen.PrimaryScreen.WorkingArea; and then I'm making a...
4
by: =?Utf-8?B?R2lkaQ==?= | last post by:
Hi, I've a document which i'm creating and printing. i want to print 2 copies: 1. regular A4 copy 2. 70% of A4 size (like in copy machine, where you can choose the size of copy). how can...
9
by: raylopez99 | last post by:
After refering to the below thread, I take it for C# Forms 2.0, there a way to draw a 1 pixel by 1 pixel rectangle, which I was able to do just now successfully. ...
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...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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...
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
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
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
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...

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.