Announcement

Collapse
No announcement yet.

Best way to convert?

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Best way to convert?

    Hello

    I have a html file in Solution Explorer in Visual Studio (VS) 2013 that I need to convert to an aspx file.

    What is the best way to do that, please? If I try simply to rename the file, I get a warning from VS about changing file extensions.

    Thanks!

  • #2
    You probably already took care of this, but the best way is to simply create a new ASPX and then paste in your HTML.

    Since it's just an HTML file, there's no real concerns about just doing it this - if it's from ASPX to something else then it can more complicated.
    Signature Image Rotator will return when I have time to fix it

    Running Scoreboard
    Anthony : 3 points

    Comment


    • #3
      Hello putts

      Thanks for your reply.

      Yes, that's just what I did and things have turned out fine!

      Thanks again!

      Comment


      • #4
        Alternatively, i do believe that you could have just changed the extension to the html page, and then added any server side code you required to it.

        If you get a warning, you should just ignore it in this situation, as there are no complications due to the conversion of HTML to ASPX.

        Just like if you were to take a spreadsheet and convert it to a .zip so you can read the xml behind it
        Who needs a Signature?

        Comment


        • #5
          The problem with that approach comes if you typically use a separate file for your code-behind and if you use a Master page.

          The "create-then-copy" approach allows you to create your ASPX file the way you always do and allows you to choose options such as Master Page or Code-behind, etc.
          Signature Image Rotator will return when I have time to fix it

          Running Scoreboard
          Anthony : 3 points

          Comment

          Working...
          X