.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

Create web site specific to mobile device, how to detect?

Posted By:      Posted Date: August 21, 2010    Points: 0   Category :ASP.Net


I have a website that is written in .Net 2.0 which uses all the nice rich functionality of the web (Ajax, javascript etc..).  However I have noticed that the site does not display very well on mobile devices. 

So therefore I would like to create a more streamlined version of my site that is better tailored to these devices.  However how do detect that the user has come to the site via a mobile device and how can i redirect them to my tailored page

Many thanks in advance

View Complete Post

More Related Resource Links

How to create a windows mobile (Smart Device) .Cab installer

A Cab file is the default setup format for Windows CE and Windows Mobile devices (similar to windows .msi files). You probably already have installed several application using .cab files, and are familiar with the concept. One point which is often unknown is that .cab files are processed by wceloader.exe, and it can only install one .cab file at a time. That means we cannot have nested .cab files. It doesn't mean we cannot have .cab files contained by another .cab, but the contained .cab files will not be installed during the installation of the container .cab. We should install it manually after the container .cab file installation has been completed.

There are two ways to create a cabinet (.Cab) file. The traditional one, and the friendly VS Smart Device Cab project which doesn't require additional coding, but which also relies on the traditional one at low-level.

Access via mobile device on claims based site



I have a claims based site with FBA setup. I have two problems:

- I use a custom made login page instead of the default FBA login. This works fine in the desktop browser, but it gives me a 403 error on my mobile device.
- I checked which page should be the mobile login. That seems to be /_layouts/mobile/default.aspx. I can access that page with my mobile device, but when I try to login, it throws an error on the server: "The security token username and password could not be validated" and I cannot log in.

I know quite sure the security token service has been configured properly, since I can login via desktop browser. I've tried entering my loginname as username, domain\user and even the claims based user id (i:0#.w|domain\username); they all fail.

MCTS in Web Application Development in .NET 2.0

How do I detect if a browser is from a mobile device?



I have an existing ASP.NET (VB.NET) created with Visual Web Developer Express 2008.

I have recently created new pages for iPhone and other mobile devices: www.mysite.com/mobile/home

What's the best way to check if the user is using a mobile device and so redirect them to the URL above?


How to transfer files between computer and mobile device using bluetooth

What is Bluetooth? How can I have it on my computer?

Bluetooth wireless technology is a communication technology that allows two devices to communicate wirelessly. Most of the notebooks are nowadays equipped with bluetooth. For those notebooks or computers that don't, you can use a bluetooth dongle to add the functionality and it just costs you around $5. Although higher price range bluetooth dongles are available but it makes no sense of buying them if you just plan to connect your mobile device to the computer. Look for one that has Bluetooth v2.0 + EDR (Enhance Data Rate) supporting speeds of upto 3Mbps and with Vista support. You can easily have one of that kind in just $5.

Setting up bluetooth to work on your computer

Just Insert the bluetooth dongle in the USB.
It should get detected by your Operating System and should be ready to use. In case it is just detected as a new hardware, you need to install drivers for it that came with your bluetooth dongle (You can try Google to find the drivers).
Once drivers are installed, a bluetooth notification icon will appear in your system tray.
Right Click on it to access Settings (This may vary with your bluetooth dongle).
Make sure you have turned Discovery On (It allow others to see your computer).
Switch On the bluetooth on the mobile device.

Create Web Site vs Web Application


I follow the tutorial and creted a web site for my company sales system. One of my collegue mention we use the wrong templet, we should use Web application for company application.

Should i continue using web site or change to web application? We are creating application for company sales, inventory, hr ,etc where possible more than 1000++ user. And during month end, it will be high traffic and transaction. can Web Site Template with BLL and DAL handle it? or i just need a powerful server?

Guideline for a Mobile compatible ASP.NET site


Hello ,

     I am looking for a guidelines or considerations one should keep in mind while developing a website or web app which can run on desktop as well as Mobiles. Can any one help me by providing a link for resources on this topic from Devloper/Arche. perspective.

Any help will be appreciated.

Nilkanth Desai


Runtime development for All mobile device



   I am planning to implement a runtime or Environment . which allow any Mobile application to run on top of IT.

  Please give me couple of links or materials to help me out.

Thanks in advance.


Device detection: standard & mobile web applications


I would like to host standard web pages as well as mobile web pages on a single website/virtual directory.


Is there a simple way of sniffing out the machine type and then presenting either web or mobile application depending on the device?

Or is there a better solution other than creating separate website?

Many thanks

how to create a mobile version of a website?


 how to create a mobile version of a website?
Is there any server support needed?
How does the browser detect whether the url is accessed via mobile device or a PC?

Need To Create A Mobile App for All Mobile's Models, No WAP Browser Intrection


Hi all,

I have an assignment to develop a mobile application for My company's customers (around 250000). its could be download from our website or we can also provide to our customers those are visiting our branches, on their demand.


1- this application should execute/compatible with all kind off mobile phone (Nokia, Samsun, LG, Motrola, Black Berry, iPhone..... every one). when it install on customer phone it will provide some certian option under the my company Icon to the user, like:

         1- Help Line Numbers

         2- Branches Address/Details

         3- My Last Visit Informations.

         4- My Next Appointment.

         5- My Payment History   and more etc etc......

         the user will select any one option and then get the response by return text Message against the option he selected from our Site/Service (I dont konw what we will say this system who will response to the customers)

My Problem is that I saw/Check many fourms and articals they are giving the tips/det

How to detect mobile phone name/model no from asp.net?


Hi experts,

Can I detect the Name/model no of the mobile phones ,which are browsing my asp.net website from C# code behind? I need to show welcome message, addressing their model numbers and redirect to appropriate pages.

Thanks in advance for your reply.


How to detect Mobile devices like Pocket PC??

Hi all,
Need help on this. As you know there is PDA-phone like Pocket PC-phone run on Window Mobile 2003 and above. It has Ms Internet Explorer of scale down version.

So, the question is this kind of device is under mobile device category but having IE browser. So, how to detect this kind of MObile device using MobileCapabilities class?  YOu see, SmartPhone also have Ms IE browser. How to tell them apart?? If I serve Pda-html website to SmartPhone, its screen size will be too small for it.

My objective is this : to detect the PDA device and Mobile Phone .

If it is PocketPC-phone, I will serve PDA-html website or Mobile web base on customer selection.
If it is smartphone or WAP 2.0 -base mobile phone, I will serve  Mobile Web.

please help.

Obtain mobile device screen size



I am trying to get the screenHeight and width:


 // Get MobileCapabilities from current Request.Browser
        MobileCapabilities currentCapabilities = (MobileCapabilities)Request.Browser;
        // get a property of the  browser 
        Response.Write(currentCapabilities.ScreenPixelsHeight +  " <br>");
        Response.Write(currentCapabilities.ScreenPixelsWidth  + " <br>");


 but this is always show that the Height is 480 & the width is 640

I am trying on HTC with Opera Mobile 9.5

Any Advice?

Going Places: Mobile Device Provisioning With SyncML


OMA Device Management (OMA-DM), based on a dialect of XML called SyncML, can be used to provision and manage mobile devices in an enterprise scenario. We'll show you how.

Ramon Arjona

MSDN Magazine February 2009

Go Mobile: Create Compact, Robust Mobile Apps with SQL Server CE 2.0 and the .NET Compact Framework


Developers have myriad options when it comes to creating solutions for mobile devices. One of the greatest challenges facing mobile developers is finding a compact yet robust local storage solution. SQL Server CE 2.0 promises to deliver on both fronts. This new release represents a tremendous leap in terms of features and performance over its predecessor. This article will review some of the platform and tools choices developers have today. The authors will compare and contrast the significant new features in SQL Server CE 2.0 with the previous release. Following that, they will build a sample app for illustration.

Mark Brown and David Meunier

MSDN Magazine January 2003

Wireless Web: Microsoft Mobile Internet Toolkit Lets Your Web Application Target Any Device Anywhere


If you've built Web sites using ASP.NET, you'll welcome the Microsoft Mobile Internet Toolkit (MMIT). MMIT extends the Visual Studio .NET IDE you already know by providing new controls for handheld devices letting you easily develop applications for wireless devices. This means you can write less code while adapting it to more devices. Not only does MMIT integrate with Visual Studio .NET, it extends ASP.NET as well. This article gives you the background you need to write, test, and deploy a site with MMIT and make all your code able to target specific devices for a custom fit.

Paul Yao and David Durant

MSDN Magazine November 2002

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend