This is a migrated thread and some comments may be shown as answers.

RenderMode="Auto"

1 Answer 209 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
miksh
Top achievements
Rank 1
Iron
miksh asked on 25 Jun 2015, 05:44 PM

How does the RenderMode="Auto" work?

E.g. Grid documentation reads:

Auto — this option will automatically decide how to render the control on a smartphone, tablet or PC and will switch between Classic and Mobile render modes (depending on the used device).

So "Auto" could never set Lightweight mode?

 

 

1 Answer, 1 is accepted

Sort by
0
Accepted
Dimitar
Telerik team
answered on 26 Jun 2015, 10:15 AM
Hi,

In order for RenderMode="Auto" to work properly, you should add a reference to the RadDeviceDetectionFramework to your project, which would enable detection of mobile browsers on the server.

With RenderMode="Auto" when viewed on a mobile device browser, controls would try to render in the following order of render mode fallback priority:
- Controls supporting Mobile would be rendered as Mobile;
- Controls supporting Lightweight render mode would be rendered as Lightweight;
- If a certain control does not support Lightweight, it will be rendered as Classic.


And in case your app is viewed on a desktop browser, the same logic will be applied, except that no Mobile rendering will be applied. Or in other words, if a control supports Lightweight, it will be rendered as Lightweight. If not, it will be rendered as Classic. And also note that some controls are lightweight by design, although the applied render mode would state Classic.


The statement in the RadGrid's documentation that RadGrid with Auto would be rendered as Classic on desktop is specific to the RadGrid, based on the render modes it supports. The documentation should be updated, however, as recently we released Lightweight RenderMode support for RadGrid. We will update this part of the article as soon as possible.

I hope the above explains how RenderMode="Auto" works.

Regards,
Dimitar
Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
Tags
General Discussions
Asked by
miksh
Top achievements
Rank 1
Iron
Answers by
Dimitar
Telerik team
Share this question
or