AspNetAtoms.com daily updates on ASP.NET Tutorials, Articles, Authors and more. Subscribe to our newsletter and receive updates on ASP.NET resources on the Internet.

Categories

Recent Posts

Make Your ASP.NET Mobile Forms Timer-Refresh and Autoredirect : Peter Bromberg

Saturday, April 18 2009

You can't use javascript in Mobile Forms, and they won't render the META Refresh tag either. Here's a way to create a Mobile Form that will refresh and autoredirect based on a timer, that extends the Mobile Form class as a control. In my travels with an ASP.NET Mobile Device application, I ran into a need to display a status panel as the result of a repeated method call on a timed basis from the page. Under normal ASP.NET page scenarios this is easy: you can either use Javascript (such as with an Anthem.net timer control) or you can create a META Refresh tag inside your Page's HEAD tag, set the HEAD to runat=server, and use an HtmlMeta control to set your HtmlMeta tag Content attribute for the refresh time and / or redirect URL. In other words, you can either display a changing status message or you can display a message and then automatically redirect to another page after 5 seconds....

Read More:
Make Your ASP.NET Mobile Forms Timer-Refresh and Autoredirect : Peter Bromberg
Also See:
Uploading Files : Scott Mitchell
Easily turn a ListView into a nicely printed report, complete with print preview : Phillip Piper
Cure Code Bloat : Steve C. Orr
Building a Custom Confirmation Dialog Box : Haissam Abdul Malak
Interacting with Astoria Data Services : Granville Barnett

Post your comment

Comment