Open UserControl on a TabPage - Phone Profile

0
0

Hi,

I’m building a sample web page application that should have a single page, hosting multiple User Controls inside a Tab Page Control. This project should have two different profiles: one for pc and another for phone.

On the main page, I have a toolbar on the top (which is the MenuBar component for the pc profile, and a panel with buttons for the phone profile) that will create new TabPages, with a UserControl on its body, inside the TabPageControl each time an item is clicked.

For the phone profile, I am docking every component of the UserControl on top, while for the desktop profile, I am not docking.

So, the issue is that, for the phone profile, the layout does not render as it is shown on Visual Studio, and the components are not docking.

How can I make the UserControl shows properly inside a TabPage on the Phone profile?

I have attached an example, for better understanding.

Thanks!

  • You must to post comments
0
0

Hi Joao,

Try adding a ClientProfiles.json configuration:

  1. Right-click your project in Visual Studio
  2. Add > New Item…
  3. Wisej 2 > Client Profiles

Also, add a Viewport to your project so it knows how to scale the screen for each device:

  1. Double-click Default.html
  2. Add:  <meta name=”viewport” content=”width=device-width, initial-scale=1.0″> in the <head> tag.

Try running the project, verify that the viewport is loaded in the “Elements” tab of Chrome under the <head> tag.

If it’s not loaded, try running the project in an Incognito window or clear your browser’s cache.

 

I tried this with your sample and it seemed to fix the issue. Please let me know if you run into any more issues!

Best regards,

Levie

 

  • You must to post comments
Showing 1 result
Your Answer

Please first to submit.