首页 > 编程知识 正文

浏览器不支持java怎么办,outputstream用法

时间:2023-05-03 21:58:41 阅读:44656 作者:1122

我有让我做这项工作的问题。 包含由几个信息组成的字符串

但是,在尝试将String写入文件以跟踪程序随时间的变化时,发生了拒绝访问错误。

语音写入到文件(字符串输入) throws Exception{

file file=new file (c :weather exports\ export.txt ' );

if (! file.exists () }

file.createNewFile (;

}

try{

infile.append(input;

inFile.newLine (;

}catch(exceptione ) {

e .打印堆栈跟踪(;

}

inFile.close (;

}

堆栈跟踪是:

jva.io.file not found exception : c : (weather exports (export.txt (accessisdenied ) ) ) ) )

jva.io.file not found exception : c : (weather exports (export.txt (accessisdenied ) ) ) ) )

at Java.io.file output stream.open append (本机方法) )。

at Java.io.file output stream.(unknown source )

at Java.io.filewriter.(unknown source )

atorg.weather alert.infomanipmethods.write to file (infomanipmethods.Java :58 )。

atorg.weather alert.form.action performed (form.Java :108 )。

at javax.swing.jtextfield.fireactionperformed (unknown source ) )。

at javax.swing.jtextfield.post actionevent (unknown source ) )。

at javax.swing.jtextfield $ notify action.action performed (unknown source ) )

at javax.swing.swing utilities.notify action (unknown source ) )。

at javax.swing.jcomponent.process key绑定(unknown source ) )。

at javax.swing.jcomponent.process key绑定(unknown source ) )。

at javax.swing.jcomponent.process keyevent (unknown source ) )。

at Java.awt.com ponent.process event (unknown source ) )。

at Java.awt.container.process event (unknown source ) )。

at Java.awt.com ponent.dispatcheventimpl (未知源) )。

at Java.awt.container.dispatcheventimpl (未知源) )。

at Java.awt.com ponent.dispatch event (unknown source ) )。

at Java.awt.keyboardfocusmanager.redispatchevent (unknown source ) )。

at Java.awt.defaultkeyboardfocusmanager.dispatch keyevent (unknown source ) )。

at Java.awt.defaultkeyboardfocusmanager.predispatchkeyevent (未知源) )。

at Java.awt.defaultkeyboardfocusmanager.typeaheadassertions (未知源) )。

at Java.awt.defaultkeyboardfocusmanager.dispatch event (unknown source ) )。

at Java.awt.com ponent.dispatcheventimpl (未知源) )。

at Java.awt.container.dispatcheventimpl (未知源) )。

at Java.awt.window.dispatcheventimpl (未知源) )。

at Java.awt.com ponent.dispatch event (unknown source ) )。

at Java.awt.event queue.dispatcheventimpl (未知源) )。

at Java.awt.event queue.access $ 000 (未知源) )。

at Java.awt.event queue $1. run (unknown source ) )。

at Java.awt.event queue $1. run (unknown source ) )。

at Java.security.access controller.do privileged (本机方法) )。

at Java.security.accesscontrolcontext $1. dointersectionprivilege (unknown source ) )。

at Java.security.accesscontrolcontext $1. dointersectionprivilege (unknown source ) )。

at Java.awt.event queue $2. run (未知源) )。

at Java.awt.event queue $2. run (未知源) )。

at Java.security.access controller.do privileged (本机方法) )。

at Java.security.accesscontrolcontext $1. dointersectionprivilege (unknown source ) )。

at Java.awt.event queue.dispatch event (unknown source ) )。

at Java.awt.eventdispatchthread.pumponeeventforfilters (unknown source ) )。

at Java.awt.eventdispatchthread.pumpeventsforfilter (unknown source ) )。

at Java.awt.eventdispatchthread.pumpeventsforhierarchy (unknown source ) )。

at Java.awt.eventdispatchthread.pump events (unknown source ) )。

at Java.awt.eventdispatchthread.pump events (unknown source ) )。

at Java.awt.eventdispatchthread.run (unknown source )。

第58行:

版权声明:该文观点仅代表作者本人。处理文章:请发送邮件至 三1五14八八95#扣扣.com 举报,一经查实,本站将立刻删除。