2/05/2014

How To Change .txt Files To .java By Showing Windows File Name Extensions

How To Change .txt Files To .java By Showing Windows File Name Extensions

Overview:

Head First Java 2nd Edition Book Kindle And Paperback If you're writing a Java program using Windows Text Document, the simple notepad program, you'll notice that when you save the file it defaults to a .txt file naturally. In order for Command Prompt to properly read and compile the program, the file extensions must be changed to a .java. We can do this by highlighting the .txt at the end of the file name and replacing it with .java, but you may notice a problem. The file type will still remain a Text Document even though you see it says .java. All that happens is .java gets added to the extension, even though you don't see it. For example, if you're file was Java1.txt it would now be Java1.txt.java or Java1.txt.txt or Java1.java.txt and these will not work. We want the file to be Java1.java. How we do this is very simple, follow the steps below:

The Tutorial:

1: Click Start
2: Click Control Panel
3: Click Appearance And Personalization
4: Click Folder Options
5: Once Inside Folder Options select the View tab
6: Scroll until you find Hide extensions for known file types and uncheck the box to the left (see above image for reference)
7: Click OK and you're done!

Now you'll see the true file extensions in your folder and can adjust them accordingly. To make your Java1.txt.java file proper, simply highlight the .txt.java and replace it with .java. Furthermore when you change the file type you'll be prompted with a pop up box that says "If you change a file name extension, the file might become unusable. Are you sure you want to change it? Click OK.

Still having issues? Visit: Microsoft Windows page on how to show or hide file name extensions

If you found this tutorial useful, please leave a comment below and visit my Java Page for more tutorials, information and projects!

Previous Post
Next Post

I'm a creative individual that makes a living from the dynamics of digital technology.

Related Posts

10 comments:


  1. Hi I am Emi from Chennai. Thanks for sharing the informative post about Java technology. It’s really useful for me to know more about this technology. Recently I did Java Training Chennai at a leading Java Training Institutes in Chennai.

    ReplyDelete
  2. Software developers to create stunning mobile application with ease. Further, they can make use of this platform at free of cost. Java Course in Chennai | Best JAVA Training in ChennaiThanks for your informative post on Java application development.

    ReplyDelete
  3. Programming modelers to make Hadoop Training in Chennai staggering insignificant application no sweat. Further, they can make usage Hadoop Training Chennai of this stage at free of cost. A pledge of gratefulness is all together for your strong post on Java application progress.

    ReplyDelete
  4. Great post and informative blog.it was awesome to read, thanks for sharing this great content to my vision.
    Seo job training in chennai

    ReplyDelete
  5. Thanks for your informative sharing...its useful for us...
    online marketing courses in chennai

    ReplyDelete
  6. Oracle DBA Training in Chennai
    Thanks for sharing this informative blog. I did Oracle DBA Certification in Greens Technology at Adyar. This is really useful for me to make a bright career..

    ReplyDelete
  7. Jharkhand Labour Department Recruitment 2016


    It’s amazing how interesting it is, My first visit made me very happy, Thanks to author..............

    ReplyDelete
  8. Such a informative post.Thanks for sharing your knowledge with us.keep it up for updating post..
    http://sonymobileservicecenterinchennai.in/AboutUs.html

    ReplyDelete
  9. great article!!!!!This is very importent information for us.I like all content and information.I have read it.You know more about this please visit again.
    Informatica Training In Chennai
    Hadoop Training In Chennai
    Oracle Training In Chennai
    Pega Training In Chennai

    ReplyDelete