+ Reply to Thread
Results 1 to 2 of 2

Thread: using XmlWriter

  1. #1
    Junior Member
    Join Date
    Jan 2012
    Posts
    13

    using XmlWriter

    Hi , i am using XmlWriter to to write an XML data , but the issue is when using XmlWriter on some file , the file is being blocked from being accessed by other applications , so is there anyway to share the file between processes ?

  2. #2
    Yes indeed there is a way to share the file between processes , maybe you used a code like the one below , but forgot to add enable sharing :
    Code:
    FileStream file = new FileStream(filepath, FileMode.OpenOrCreate, FileAccess.Write, FileShare.Read);
    var xmlWriter = XmlWriter.Create(file);

+ Reply to Thread

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts