P
Patch61
I am new to .Net programming, but I am experienced with VB6. I am using VB
2008 Express to write a small program to copy a directory structure and files
from a CD to a folder on C: drive.
I have a form with 2 buttons; one to do the copying and one to cancel.
Here is my code for the copying button:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click
My.Computer.FileSystem.CopyDirectory("F:\WAFS Blocks - Test",
"C:\HES\WAFS\WAFS Blocks", FileIO.UIOption.AllDialogs)
End Sub
When I click button1, I get an error that says:
............
Application attempted to perform an operation not allowed by the security
policy. To grant this application the required permission, contact your
system administrator, or use the Microsoft .NET Framework Configuration tool.
Request for the permission of type
'System.Security.Permissions.FileIOPermission, mscorlib, Version=2.0.0.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089'
............
My IT department has no idea what to do about this. They have given my user
account full admin rights with the same results.
What do I need to do to correct this? I need to deploy this on several
systems in several office locations.
Thanks in advance for any help.
2008 Express to write a small program to copy a directory structure and files
from a CD to a folder on C: drive.
I have a form with 2 buttons; one to do the copying and one to cancel.
Here is my code for the copying button:
Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles Button1.Click
My.Computer.FileSystem.CopyDirectory("F:\WAFS Blocks - Test",
"C:\HES\WAFS\WAFS Blocks", FileIO.UIOption.AllDialogs)
End Sub
When I click button1, I get an error that says:
............
Application attempted to perform an operation not allowed by the security
policy. To grant this application the required permission, contact your
system administrator, or use the Microsoft .NET Framework Configuration tool.
Request for the permission of type
'System.Security.Permissions.FileIOPermission, mscorlib, Version=2.0.0.0,
Culture=neutral, PublicKeyToken=b77a5c561934e089'
............
My IT department has no idea what to do about this. They have given my user
account full admin rights with the same results.
What do I need to do to correct this? I need to deploy this on several
systems in several office locations.
Thanks in advance for any help.