谁能解释我为什么在IO操作中会发生此错误?

问题描述:

大家好,我有一个小型Windows应用程序,已在此 http://justlikeamagic.wordpress.com/2009/03/27/programmatically-compress-and-decompress-files/. [ ^ ]在此,我想压缩sample.txt文件.
但是遇到此错误时,请对此提供帮助
拒绝访问路径"C:\ Documents and Settings \ hemanth.vemu \ Desktop \ Compress"."

hi everyone ,I have a small windows app which was given in this http://justlikeamagic.wordpress.com/2009/03/27/programmatically-compress-and-decompress-files/.[^]In this i wanna to compress a sample.txt file.
But am getting this error please help me regarding this
"Access to the path ''C:\Documents and Settings\hemanth.vemu\Desktop\Compress'' is denied."

您的路径应为
C:\ Documents and Settings \ hemanth.vemu \ Desktop \ Compress \ sample.txt.
您还需要在路径中添加文件名.
Your path should be
C:\Documents and Settings\hemanth.vemu\Desktop\Compress\sample.txt.
U need to add the file name also to ur path.