GDI+ - screen resolution in asp.net

Asked By Developer Developer
08-Aug-08 12:00 AM
I have created an asp.net web app on my machine where the resolution is
set to 1024 x 768.
When i m trying to view the web page on other system screen, some
of the Page controls display differently than on my screen where the looking allright.
Anybody know how to handle resolution problems in asp.net?

Thanks in advance

get the resolution and try to match with yr server  get the resolution and try to match with yr server

08-Aug-08 12:04 AM
<script runat="server" language="C#">

    public void Page_Load(Object sender, EventArgs e){

        if (Session["ScreenResolution"] == null) {
            // Session variable is not set
            // Redirect to the screen resolution detection script
            Response.Redirect("detectscreen.aspx");
        } else {
            // Session variable is set
            // Display it on the page
            screenresolution.Text = Session["ScreenResolution"].ToString();
        }
        
    }

</script>
first fined the resolution and then set it as u wnat.

See this  See this

08-Aug-08 12:13 AM

See this article will tell you about a technique through which you can make intelligent ASP.NET websites which will automatically detect the resolution of the visitor's desktop and generate a resolution optimized mark-up of a page, not forcing the visitor to keep the resolution of his/her desktop according to the website's best view resolution.

It is unpredictable for a website to be dynamic in visual appearance for multiple resolutions. Typically, graphic designers design the page graphics and the elements optimized for a certain screen resolution. Visitors having varying resolutions different from that recommended for the website will experience a less comfortable view of the pages.

Through a mix of ASP.NET and JavaScript, we can build such pages for a website which will show up according to the resolution of the visitor's PC. See this link to know abt that.

http://www.codeproject.com/KB/aspnet/DynamicScreens.aspx

Also go thr these links;

http://bytes.com/forum/thread319672.html

http://www.devcity.net/Articles/64/1/screenresolution.aspx

Best Luck!!!!!!!!!!!!!!!!!!!
Sujit.

hmm...  hmm...

08-Aug-08 12:23 AM

You need to look at the CSS for the pages you developed and make sure you test the app in different resolutions and make a page which is accepted by most of the resolutions...

You can detect the browser and resolution in javascript and do the coding accordingly...

Issue...  Issue...
08-Aug-08 12:24 AM

Basically this problem is not with your asp.net application. If the other machine having the resolution lesser that your computer resolution then this problem occurs. You can get the resolution of client machine and handle accordingly.

There are different layout structures in asp.net such as flow layout etc. You can use those layouts to design your web pages. Or u can give message to the client that this site is best viewed in 1024X768 resolution.

Others, you can use the html tables in your asp.net application and put the width of main table as

Width = "100%"

so when browser opens that page that table is resized and best viwed at the browser window. This technique is mainly applied in many applications.

Using HTML U get the screen reslution as

Height = screen.availHeight & Width = screen.availWidth

Links:

http://www.velocityreviews.com/forums/t87595-screen-resolution-in-aspnet.html

http://bytes.com/forum/thread319672.html

try this...  try this...
08-Aug-08 12:43 AM

Hi,

set the page width to 100% and heigh to 100%.

and set inner cells, rows hieght in percentages not in pixels...

so when ever the resolution changes, the page will be expand or shrink to fit the screen resolution.

screen resolution  screen resolution
08-Aug-08 12:49 AM

u have to place all the controls inside an <table> tag,

dont do just drag and drop.

<table>

<tr>

<td>place the one control here</td>

</tr>

</table>

implement   implement "fluid" Web page layout
08-Aug-08 12:56 AM
You can make your web page spread across the screen dimensions available by using either Tables or CSS. The article here - http://www.sitepoint.com/print/liquid-design talks about fluid Web page layout in detail with code.

To implement fluid Web page layout with tables you have to set the table width as a percentage rather than as pixels.
try this  try this
08-Aug-08 01:02 AM
hi,
if your pages have to display in a fixed size for all resolution
then mention the table width and height in the pixel

<table width="1000" height="100">
...
...
...
</table>


if  your pages have to expand or shrink accroding to resolution then
set the table width and height in percentage

<table width="100%" height="90%">
...
...
...
</table>

  Developer Developer replied to sri sri
08-Aug-08 03:31 AM
thanking you so much for all friends.
Create New Account
help
post html to asp.net page for validation and emailing .NET Framework Hello, I am pretty new to asp.net and I've been trying to figure out how to take a static HTML web form data and send it to an asp.net page to validate 1 field and then if it passes the validation, create an e- mail
load file in asp.net dropdown list ASP.NET I have a dropdown button in asp.net page which shows all the xml files on the ftp and when i open the particular file then that file load on asp.net page http: / / dotnetspidor.blogspot.com / 2009 / 04 / bind-aspnet-dropdownlist-to-xml-file.html
Printing from an ASP.NET page .NET Framework I have an ASP.NET page that displays work orders in a GridView. In that GridView is a checkbox column. When fine in the Visual Studio 2005 development environment on localhost. But, when I move the page to the web server, I get the error "Settings to access printer ' \ ServerName \ PrinterName' are I try this while logged into the server, but I can successfully print a test page from the server. This printer is installed on the server and is the default printer
Tracing in ASP.NET? hi all, what is tracing? how to achieve tracing in asp.net? different ways of doing tracing? thanks and regards Aman Khan hi. . Tracing in ASP.NET 2.0 Tracing is a way to monitor the execution of your ASP.NET application. You can record exception details and program flow in a way that doesn't
Migration from ASP to ASP.net How to convert ASP site to ASP.NET site using C# http: / / www.asp.net / downloads / archived-v11 / migration-assistants / asp-to-aspnet hi, ASP.NET framework is very much different from unstrucured ASP and there is no correct way to