What you want to see on DotNetFunda.com ?
DotNetFunda.Com Logo
Twitter TwitterLinkedIn
YouTubeGoogle
 Online : 252 |  Welcome, Guest!   Register  Login
 Home > Forums > C# > How to read a wordfile in multiple reader ...
Kirubakaranb.Tech

How to read a wordfile in multiple reader

Replies: 1 | Posted by: Kirubakaranb.Tech on 10/17/2012 | Category: C# Forums | Views: 250 | Status: [Member] | Points: 10  


how to read a single wordfile into multiple reader withour read and write lock to that read file.
In my program i browse one wordfile and open that wordfile into richtextbox. In that same file read a another person to open that file and read that file into richtextbox.
If suppose multiple reader to read that file means we have readonly problem that is for deadlock condtion occure. How to read without read and write lock condion by using threading concept.
give me solution for that pbm.....


Reply | Reply with attachment | Alert Moderator

 Responses below this adGet hundreds of .NET Tips and Tricks videos

 Replies

Sheonarayan
Sheonarayan  
Posted on: 10/17/2012 10:18:21 AM
Level: HonoraryPlatinum | Status: [Microsoft_MVP] [Administrator] | Points: 25

Not sure how you are reading the file, if you are using FileStream, you can use FileShare mode something like below.

FileStream fs = new FileStream("your file name", FileMode.Open, FileAccess.Read, System.IO.FileShare.Read)


Thanks

Regards,
Sheo Narayan, Microsoft MVP
The Founder
http://www.dotnetfunda.com

Kirubakaranb.Tech, if this helps please login to Mark As Answer. | Reply | Alert Moderator 

Reply - Please login to reply


Click here to login & reply

Found interesting? Add this to:


 Latest Posts

Write New Post | More ...

About Us | Contact Us | The Team | Advertise | Software Development | Write for us | Testimonials | Privacy Policy | Terms of Use | Link Exchange | Members | Go Top
General Notice: If you find plagiarised (copied) contents on this page, please let us know the original source along with your correct email id (to communicate) for further action.
Copyright © DotNetFunda.Com. All Rights Reserved. Copying or mimicking the site design and layout is prohibited. Logos, company names used here if any are only for reference purposes and they may be respective owner's right or trademarks. | 5/24/2013 4:25:57 PM