How to assign JS screen.width to ASP.Net variable


Posted on 16th Feb 2014 07:03 pm by admin

I've got this ASP.net routine that gets the cookie value of the screen width, but now I need to change it so that it gets the width using Javascript, in case the users don't have cookies enabled. I need something like: Dim myWidth As String = ScriptManager.RegisterStartupScript(Me.Page, Me.Page.GetType, "screenwidth", "screen.width;", True) However, I get a blue line under this and it tells me that it doesn't produce a value How can I do this?
No comments posted yet

Your Answer:

Login to answer
256 Like 33 Dislike
Previous forums Next forums
Other forums

exclude characters from counting?
Hello, I wanted to ask if you have a string like:
Code: $my_s='ASRGREGTGTR----REGREGRE+++RRRRRR..

MVC - Code review
I'm in the process of trying to wrap my head around MVC, and as part of that, I'm attempting to impl

array empty
Hiya peeps,

Ok here is the codes.

order.php

Code:

Filtering Tables
Hello Thanks for any help any one can give Im very new to PHP..

I need to pull data for clien

what does this mean? +=
is anyone able to explain what this code is saying?

i had it written for me awhile back and n

Somebody hacked into my site and changed coding >>> URGENT HELP NEEDED <<<
I am not that much into programming , but somebody is hacking to my site and injecting some kind of

Update Database
Hi All,


I have a problem with this:

Code: [Select]<?php
session_start();

RadioButtonList data selection
view plaincopy to clipboardprint?

Help with PHP Email Script
Hi guys,

I'm a newbie to php and need help with the script below:

At the moment when I

need to apply an if/else statement to Tim Thumb script
Not sure how to work this. I essentially want to call a variety of image sizes based on which style

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash