Refactoring in Razor pages

8 posts, 0 answers
  1. John
    John avatar
    36 posts
    Member since:
    Oct 2006

    Posted 05 Aug 2012 Link to this post

    I have several web projects and for some reason refactoring seems to be disabled for one of the projects.  I have checked all the options and cant seem to find any differences.  I beleive i am on the latest JustCode version but beleive i hvae been having this issue this for some.
    I have ininstalled the JustCode and reinstalled but the same issue is still present.

    Hope you can help

    John
  2. John
    John avatar
    36 posts
    Member since:
    Oct 2006

    Posted 05 Aug 2012 Link to this post

    I also forgot to mention Code Analysis is not functioning on Razor pages as well in this project but work as expected int he otther project.

    John
  3. DevCraft banner
  4. Zdravko
    Admin
    Zdravko avatar
    657 posts

    Posted 07 Aug 2012 Link to this post

    Hi, 

    Thanks for contacting us.
    In order to investigate the issue I will ask you some questions.
    • I would like to ask you what exactly are you missing from the refactoring? Maybe some screenshots would help.
    • What kind of projects with missing refactoring do you have ?
    • Are there any errors or exceptions and would you send us your logs located in %localappdata%\JustCode\Logs ?
    • Would you provide us a sample project that reproduces this behaviour?
    Please, provide information about your JustCode's version. 


    If you are willing to send us the required files, please open a private ticket.
    Thanks for your help.

    All the best,
    Zdravko
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  5. Zdravko
    Admin
    Zdravko avatar
    657 posts

    Posted 07 Aug 2012 Link to this post

    Hello,

     One more thing to ask you.
    Would you check what is the "Build action" of your Razor pages that have no analysis?
    Thanks.

    All the best,
    Zdravko
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  6. John
    John avatar
    36 posts
    Member since:
    Oct 2006

    Posted 07 Aug 2012 Link to this post

    Hi Zdravko
    That was the problem.  The "Build action" was set to None so changed to "Content".  I noticed lat yesterday that soem pages worked as expected so was going to investigate today but all solved now thanks.  I guess the reason is migrated thos pages from aspx/ascx to Razor.

    I have also put the logs of today here https://dl.dropbox.com/u/51775182/Logs.zip.  I noticed there are some errors being reported, these logs are just from opening the project.

    Thanks again for you help

    John 
  7. Zdravko
    Admin
    Zdravko avatar
    657 posts

    Posted 09 Aug 2012 Link to this post

    Hello John,

     Thanks for the logs.
    To turn on the analysis of a file you should put the Build action to "Compile".
    Except this, should I understand that everything is working properly including the refactoring?
    Thanks.

    All the best,
    Zdravko
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

  8. John
    John avatar
    36 posts
    Member since:
    Oct 2006

    Posted 13 Aug 2012 Link to this post

    Hello Zdravko

    Thanks for the update. 
    Am I correct in understanding you are saying the Build Action should be "Compile" for cshtml (Razor) pages.  When you create a new cshtml (Razor) page VS sets the build action for "Content".  Is there a benefit to chaging this to "Compile"  I did a search but couldn't find anything for this change,  if you can let me know the reason to change from the default that would be great.
    Thnaks

    John
  9. Ivan
    Admin
    Ivan avatar
    106 posts

    Posted 14 Aug 2012 Link to this post

    Hi,

    I am sorry for the wrong information. You do not need to change the Build Action to compile in order to get JustCode analyzing cshtml files. Such files with Build Action set to "Content" should be analyzed just fine.
    However, if the build action is set to "None" we do not analyze them.
    Thank you for your help and again sorry for the inconvenience!

    Regards,
    Ivan
    the Telerik team

    Explore the entire Telerik portfolio by downloading Telerik DevCraft Ultimate.

Back to Top
DevCraft banner