I try delete a image when i use RadGrid1_DeleteCommand
I get the delete id using:
But i dont get the name of the file: item("filnamn").Text
Whot do i wrong?
I get the delete id using:
Dim item As GridDataItem = DirectCast(e.Item, GridDataItem)Dim DeleteId As Integer = item("id").TextDim DeleteImage As String = item("filnamn").TextBut i dont get the name of the file: item("filnamn").Text
If File.Exists(Server.MapPath("~/bulletinboard/images/") & DeleteImage) = True Then File.Delete(Server.MapPath("~/bulletinboard/images/") & DeleteImage)End IfWhot do i wrong?