[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

microsoft.public.dotnet.framework.aspnet.mobile

IsMobileDevice returns false when connecting with WM 2003

Sacha Korell

12/21/2004 10:57:00 PM

Request.Browser("IsMobileDevice") returns false when connecting with my iPAQ
2215 (and other Windows Mobile 2003 devices), although
HTTPBrowserCapabilities "Platform" returns "WinCE".

What's going on? I'm using VS.NET2003 for development with DeviceUpdate4
installed.

I had a code snippet like:

If Not (Page.IsPostBack) Then
If (Device.IsMobileDevice) Then
RedirectToMobilePage("mobile/m_default.aspx")
Else
Response.Redirect("default.aspx")
End If
End If

It used to work just fine, but now "Device.IsMobileDevice" also returns
false.

Any ideas?

Thanks,

Sacha


3 Answers

Shaul Feldman

1/6/2005 9:31:00 PM

0

Hi,
why won''t you assign some special value to TYPE field in web.config
specification of your iPAQ and trest it this way:

if (Device.Type == "the value you have assigned")
RedirectToMobilePage("mobile.aspx");
else
Response.Redirect(:web.aspx");


--
With the best wishes,
Sean Feldman
"Sacha Korell" <korell@huntsville.sparta.com> wrote in message
news:erE2xB75EHA.3236@TK2MSFTNGP15.phx.gbl...
> Request.Browser("IsMobileDevice") returns false when connecting with my
> iPAQ
> 2215 (and other Windows Mobile 2003 devices), although
> HTTPBrowserCapabilities "Platform" returns "WinCE".
>
> What''s going on? I''m using VS.NET2003 for development with DeviceUpdate4
> installed.
>
> I had a code snippet like:
>
> If Not (Page.IsPostBack) Then
> If (Device.IsMobileDevice) Then
> RedirectToMobilePage("mobile/m_default.aspx")
> Else
> Response.Redirect("default.aspx")
> End If
> End If
>
> It used to work just fine, but now "Device.IsMobileDevice" also returns
> false.
>
> Any ideas?
>
> Thanks,
>
> Sacha
>
>


Sacha Korell

1/6/2005 10:14:00 PM

0

Thanks for your reply, Sean

Well, the problem is really that I want any mobile device to be redirected
whether it''s an iPAQ or a Smartphone device, but apparently devices running
Windows Mobile 2003 do not get recognized by Device.IsMobileDevice. I was
very enthusiastic when Microsoft started the whole "DeviceUpdate" thing, but
they must have quit that over a year ago. Now they refer to a vendor
(cyScape) in the machine.config that charges over $300 for new device
updates.

Here''s how I have solved the problem (for now):

If (Request.Browser("IsMobileDevice") = "true") Then
RedirectToMobilePage("mobile/m_default.aspx")
Else
Dim bc As HttpBrowserCapabilities = Request.Browser

''* Will be changed to ''Select Case'' later
If bc.Platform = "WinCE" Then
RedirectToMobilePage("mobile/m_default.aspx")
Else
Response.Redirect("default.aspx")
End If
End If


Sacha



"Sean Feldman" <sfeldman@writeme.com> wrote in message
news:OSu1EcD9EHA.3504@TK2MSFTNGP12.phx.gbl...
> Hi,
> why won''t you assign some special value to TYPE field in web.config
> specification of your iPAQ and trest it this way:
>
> if (Device.Type == "the value you have assigned")
> RedirectToMobilePage("mobile.aspx");
> else
> Response.Redirect(:web.aspx");
>
>
> --
> With the best wishes,
> Sean Feldman
> "Sacha Korell" <korell@huntsville.sparta.com> wrote in message
> news:erE2xB75EHA.3236@TK2MSFTNGP15.phx.gbl...
>> Request.Browser("IsMobileDevice") returns false when connecting with my
>> iPAQ
>> 2215 (and other Windows Mobile 2003 devices), although
>> HTTPBrowserCapabilities "Platform" returns "WinCE".
>>
>> What''s going on? I''m using VS.NET2003 for development with DeviceUpdate4
>> installed.
>>
>> I had a code snippet like:
>>
>> If Not (Page.IsPostBack) Then
>> If (Device.IsMobileDevice) Then
>> RedirectToMobilePage("mobile/m_default.aspx")
>> Else
>> Response.Redirect("default.aspx")
>> End If
>> End If
>>
>> It used to work just fine, but now "Device.IsMobileDevice" also returns
>> false.
>>
>> Any ideas?
>>
>> Thanks,
>>
>> Sacha
>>
>>
>
>


Shaul Feldman

1/7/2005 10:41:00 PM

0

Hi,
well, frankly speaking, I can''t figure out what''s going on with Mobile
ASP.Net. On one hand it''s a great piece of work, on other hand it''s kind of
stacked. For instance, the Xhtml adapters source I''ve being chasing after
aren''t on the MSDN or any other place. Aslo the mobile part of asp.net site
is quiet as dead place. Have a clue what are Microsoft''s plans?

--
With the best wishes,
Sean Feldman
"Sacha Korell" <korell@huntsville.sparta.com> wrote in message
news:uhpRxzD9EHA.3868@TK2MSFTNGP15.phx.gbl...
> Thanks for your reply, Sean
>
> Well, the problem is really that I want any mobile device to be redirected
> whether it''s an iPAQ or a Smartphone device, but apparently devices
> running Windows Mobile 2003 do not get recognized by
> Device.IsMobileDevice. I was very enthusiastic when Microsoft started the
> whole "DeviceUpdate" thing, but they must have quit that over a year ago.
> Now they refer to a vendor (cyScape) in the machine.config that charges
> over $300 for new device updates.
>
> Here''s how I have solved the problem (for now):
>
> If (Request.Browser("IsMobileDevice") = "true") Then
> RedirectToMobilePage("mobile/m_default.aspx")
> Else
> Dim bc As HttpBrowserCapabilities = Request.Browser
>
> ''* Will be changed to ''Select Case'' later
> If bc.Platform = "WinCE" Then
> RedirectToMobilePage("mobile/m_default.aspx")
> Else
> Response.Redirect("default.aspx")
> End If
> End If
>
>
> Sacha
>
>
>
> "Sean Feldman" <sfeldman@writeme.com> wrote in message
> news:OSu1EcD9EHA.3504@TK2MSFTNGP12.phx.gbl...
>> Hi,
>> why won''t you assign some special value to TYPE field in web.config
>> specification of your iPAQ and trest it this way:
>>
>> if (Device.Type == "the value you have assigned")
>> RedirectToMobilePage("mobile.aspx");
>> else
>> Response.Redirect(:web.aspx");
>>
>>
>> --
>> With the best wishes,
>> Sean Feldman
>> "Sacha Korell" <korell@huntsville.sparta.com> wrote in message
>> news:erE2xB75EHA.3236@TK2MSFTNGP15.phx.gbl...
>>> Request.Browser("IsMobileDevice") returns false when connecting with my
>>> iPAQ
>>> 2215 (and other Windows Mobile 2003 devices), although
>>> HTTPBrowserCapabilities "Platform" returns "WinCE".
>>>
>>> What''s going on? I''m using VS.NET2003 for development with DeviceUpdate4
>>> installed.
>>>
>>> I had a code snippet like:
>>>
>>> If Not (Page.IsPostBack) Then
>>> If (Device.IsMobileDevice) Then
>>> RedirectToMobilePage("mobile/m_default.aspx")
>>> Else
>>> Response.Redirect("default.aspx")
>>> End If
>>> End If
>>>
>>> It used to work just fine, but now "Device.IsMobileDevice" also returns
>>> false.
>>>
>>> Any ideas?
>>>
>>> Thanks,
>>>
>>> Sacha
>>>
>>>
>>
>>
>
>