Check user permission on your directory or change your virtual directory
security permission.
By default, the anonymous ASPNET user had no write access on the virtual
directory.
Lionel.
"siaj" <> a écrit dans le message de news:
33549D33-FCF7-43A1-BDBC-...
> Hi..
> I m just trying to learn using XML file as a datastore.
>
> I am reading a dataset from a XML file and then trying to update the XML
> file with some changes in the dataset.
> My code is as follwoing.
>
> Private Sub ReadUpdateData()
> Dim dsUser As New DataSet
> dsUser.ReadXml(Server.MapPath("Datafiles\Users.xml "))
> DataGrid1.DataSource = dsUser
> DataGrid1.DataBind() 'Read data
>
> dsUser.Tables(0).Rows(0).Item(1) = "xyz" 'changed value
> dsUser.WriteXml(Server.MapPath("Datafiles\Users.xm l"))
> End Sub
>
> The Above code gives me error as Access to the path
> "C:\...\Datafiles\Users.xml" is denied
>
>
> any help will be highly aprreciated.
>
> Cheers,
> siaj