• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Junilu Lacar
Sheriffs:
  • Rob Spoor
  • Liutauras Vilda
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Piet Souris
  • Tim Holloway
  • Jj Roberts
  • Stephan van Hulst
Bartenders:
  • Himai Minh
  • Carey Brown
  • Frits Walraven

File

 
Greenhorn
Posts: 26
Firefox Browser Tomcat Server Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Why should not working File.createTempFile method in windows 8 host?
 
Java Cowboy
Posts: 16084
88
Android Scala IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Maybe because you don't have permission to write in the directory that you are trying to create the temporary file in?

Without more details, it's hard to give you a useful answer. Is this a problem that you encounter in your application? Is your application a desktop Java application, or an applet, or something else? What does the code look like where you call File.createTempFile? In which directory are you trying to create a temporary file? Are you sure you have the right permissions? Do you get error messages? If yes, then what exactly are the error messages?
 
ssasi kumar
Greenhorn
Posts: 26
Firefox Browser Tomcat Server Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator


Error :
java.io.IOException: The system cannot find the path specified
at java.io.WinNTFileSystem.createFileExclusively(Native Method)
at java.io.File.checkAndCreate(File.java:1704)
at java.io.File.createTempFile(File.java:1792)
at TempFile.main(TempFile.java:10)

above the code folder name 'sasi' not available on E: drive. above that code working fine on windows xp. but windows 8 gave error... this is my problem dude...
 
Jesper de Jong
Java Cowboy
Posts: 16084
88
Android Scala IntelliJ IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The error message "The system cannot find the path specified" seems pretty clear.

Do you have a drive E: on the Windows 8 machine? Does a folder named "sasi" exist on drive E:?
Do you have permission to create a file in directory E:\sasi?
 
ssasi kumar
Greenhorn
Posts: 26
Firefox Browser Tomcat Server Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
i have E: drive partition also have permission for create folder in windows 8 machine.
 
Bartender
Posts: 6109
6
Android IntelliJ IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

ssasi kumar wrote:i have E: drive partition also have permission for create folder in windows 8 machine.



Does E:/sasi exist? (Not the same as E:/ exists.)

Is E:/sasi a directory?

Does the user executing your Java app have permission to create files in E:/sasi? (Not the same thing as having permission to create a file in on the machine or in E:/.)

 
Be reasonable. You can't destroy everything. Where would you sit? How would you read a tiny ad?
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
reply
    Bookmark Topic Watch Topic
  • New Topic