locked
MVC designer RRS feed

  • Question

  • User136806914 posted

    I mostly worked on traditional web forms & liked going to designer so i can check how UI looks for the web page. Now i started working in a new team & trying to figure out the application, is there a way for me to go to designer in MVC so i can confirm if i am navigating to the correct page

    Tuesday, June 18, 2019 11:22 AM

Answers

  • User-1038772411 posted

    Hello, PraveenAman

    Not clear about your question but as per my understanding i m giving you answer hope it will help you.

    " No you can not see designer part in mvc view page like webform designer and split window. So in mvc view page create design code than run view page and see the  output on browser tab directly."

    Thanks.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, June 18, 2019 11:38 AM
  • User475983607 posted

    I mostly worked on traditional web forms & liked going to designer so i can check how UI looks for the web page. Now i started working in a new team & trying to figure out the application, is there a way for me to go to designer in MVC so i can confirm if i am navigating to the correct page

    Your UI development is a bit different than mine.  I recommend using the browser, actually all major browsers, to validate the the UI and the navigation.  Visual Studio a feature where you can refresh the browser window when it detects a change in the markup.

    https://docs.microsoft.com/en-us/aspnet/visual-studio/overview/2013/using-browser-link

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, June 18, 2019 11:44 AM
  • User753101303 posted

    Hi,

    MVC doesn't have a designer. Unlike Web Forms which builds a control tree with design time support a Razor view is basically C# code that renders HTML markup directly to the browser (and so you have to run this code anyway to see how the page looks like).

    Even with Web Forms I stopped using designers a long time ago. With a bit of habit it is fairly easy (and likely quicker) to write your page so that it looks like how you want rather than looking at how it looks like and fixing it. If needed you can use F12 Elements and change styles in most if not all browsers to see how it looks like and then you'll just keep what you want in your style sheet.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, June 18, 2019 11:46 AM
  • User-821857111 posted

    Visual Studio doesn't offer a Design View for views and layouts. You should be able to tell from the URL which page you are looking at if the original developers stuck with the conventional routing set up. The url should be in the form of /controller/viewname, where the controller name is the name of the controller without "controller", so products/edit will be the Edit view on the ProductsController controller.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, June 18, 2019 11:48 AM

All replies

  • User-1038772411 posted

    Hello, PraveenAman

    Not clear about your question but as per my understanding i m giving you answer hope it will help you.

    " No you can not see designer part in mvc view page like webform designer and split window. So in mvc view page create design code than run view page and see the  output on browser tab directly."

    Thanks.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, June 18, 2019 11:38 AM
  • User475983607 posted

    I mostly worked on traditional web forms & liked going to designer so i can check how UI looks for the web page. Now i started working in a new team & trying to figure out the application, is there a way for me to go to designer in MVC so i can confirm if i am navigating to the correct page

    Your UI development is a bit different than mine.  I recommend using the browser, actually all major browsers, to validate the the UI and the navigation.  Visual Studio a feature where you can refresh the browser window when it detects a change in the markup.

    https://docs.microsoft.com/en-us/aspnet/visual-studio/overview/2013/using-browser-link

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, June 18, 2019 11:44 AM
  • User753101303 posted

    Hi,

    MVC doesn't have a designer. Unlike Web Forms which builds a control tree with design time support a Razor view is basically C# code that renders HTML markup directly to the browser (and so you have to run this code anyway to see how the page looks like).

    Even with Web Forms I stopped using designers a long time ago. With a bit of habit it is fairly easy (and likely quicker) to write your page so that it looks like how you want rather than looking at how it looks like and fixing it. If needed you can use F12 Elements and change styles in most if not all browsers to see how it looks like and then you'll just keep what you want in your style sheet.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, June 18, 2019 11:46 AM
  • User-821857111 posted

    Visual Studio doesn't offer a Design View for views and layouts. You should be able to tell from the URL which page you are looking at if the original developers stuck with the conventional routing set up. The url should be in the form of /controller/viewname, where the controller name is the name of the controller without "controller", so products/edit will be the Edit view on the ProductsController controller.

    • Marked as answer by Anonymous Thursday, October 7, 2021 12:00 AM
    Tuesday, June 18, 2019 11:48 AM
  • User1520731567 posted

    Hi PraveenAmar,

    is there a way for me to go to designer in MVC so i can confirm if i am navigating to the correct page

    If you want to preview the page effect, you could right click "View in Browser" directly on the page and it render the current page quickly.

    If you would like to test front and rear linkage effect,such as: Redirect to another page,

    you could enter F11 on the page,and add breakpoints in Controller or View to check if the redirect is successful

    ,or open F12 developer tool on the browser and check for HTTP errors.

    Best Regards.

    Yuki Tao

    Wednesday, June 19, 2019 6:20 AM