Click here to Skip to main content
15,913,388 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: my own dll Pin
jonathan152-Sep-04 2:36
jonathan152-Sep-04 2:36 
GeneralRe: my own dll Pin
Pablo.ar3-Sep-04 0:40
Pablo.ar3-Sep-04 0:40 
GeneralFind reserved keywords for SQL Server Pin
xshi00531-Aug-04 14:30
xshi00531-Aug-04 14:30 
GeneralRe: Find reserved keywords for SQL Server Pin
Dave Kreskowiak1-Sep-04 1:47
mveDave Kreskowiak1-Sep-04 1:47 
Generalmanaging explorer Pin
discombobulatorybob31-Aug-04 13:13
discombobulatorybob31-Aug-04 13:13 
GeneralRe: managing explorer Pin
Purple Monk1-Sep-04 0:40
Purple Monk1-Sep-04 0:40 
GeneralTransparent PictureBox Pin
hayedid31-Aug-04 9:15
hayedid31-Aug-04 9:15 
GeneralDirectory.Delete Pin
KreativeKai31-Aug-04 8:05
professionalKreativeKai31-Aug-04 8:05 
I have the following code where I want to delete a directory that might have multiple levels of sub-directories and multiple files and additional folders within each directory.

Try
Dim strToDir As String = "c:\test"
If Directory.Exists(strToDir) Then
Directory.Delete(strToDir, True)
End If
Catch ex As Exception
MsgBox("Error: " & ex.Message)
End Try

When one of the files anywhere within the directory that I am deleting is read-only, I receive the following error:

Error: Access to the path "IamReadOnlyHaHa.txt" is denied.

Is there any way around this error?
Thanks in advance for any input you might have... Confused | :confused:

Lost in the vast sea of .NET
GeneralRe: Directory.Delete Pin
Dave Kreskowiak31-Aug-04 10:36
mveDave Kreskowiak31-Aug-04 10:36 
GeneralRe: Directory.Delete Pin
KreativeKai1-Sep-04 1:56
professionalKreativeKai1-Sep-04 1:56 
GeneralRe: Directory.Delete Pin
KreativeKai20-Sep-04 3:58
professionalKreativeKai20-Sep-04 3:58 
GeneralFind Functionality Pin
Dicescuz31-Aug-04 7:55
Dicescuz31-Aug-04 7:55 
GeneralRe: Find Functionality Pin
Dave Kreskowiak31-Aug-04 10:32
mveDave Kreskowiak31-Aug-04 10:32 
GeneralRe: Find Functionality Pin
Dicescuz31-Aug-04 13:07
Dicescuz31-Aug-04 13:07 
Questionhow to get a project forms name Pin
shayperi31-Aug-04 3:52
shayperi31-Aug-04 3:52 
QuestionHow to enable the both vertical/horizontal scroll bars? Pin
sha_noodle31-Aug-04 3:36
sha_noodle31-Aug-04 3:36 
AnswerRe: How to enable the both vertical/horizontal scroll bars? Pin
Dave Kreskowiak31-Aug-04 5:19
mveDave Kreskowiak31-Aug-04 5:19 
AnswerRe: How to enable the both vertical/horizontal scroll bars? Pin
Mekong River31-Aug-04 5:19
Mekong River31-Aug-04 5:19 
GeneralRe: How to enable the both vertical/horizontal scroll bars? Pin
Dave Kreskowiak31-Aug-04 6:18
mveDave Kreskowiak31-Aug-04 6:18 
GeneralRe: How to enable the both vertical/horizontal scroll bars? Pin
Mekong River31-Aug-04 6:54
Mekong River31-Aug-04 6:54 
GeneralRe: How to enable the both vertical/horizontal scroll bars? Pin
Dave Kreskowiak31-Aug-04 7:33
mveDave Kreskowiak31-Aug-04 7:33 
GeneralChoosing a file Pin
Mega131-Aug-04 2:58
Mega131-Aug-04 2:58 
GeneralRe: Choosing a file Pin
Purple Monk31-Aug-04 3:05
Purple Monk31-Aug-04 3:05 
GeneralRe: Choosing a file Pin
Mega131-Aug-04 3:17
Mega131-Aug-04 3:17 
GeneralRe: Choosing a file Pin
Mekong River31-Aug-04 15:16
Mekong River31-Aug-04 15:16 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.