.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
 
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
Sharon Maxwell

Home >> Forum >> Windows Application >> Post New QuestionBookmark and Share Subscribe to Forum

database is read-only.

Posted By: Ram     Posted Date: September 05, 2015    Points:5   Category :Windows Application
Hi,

I had developed windows application with C# and converted to EXE file.When i install that exe to windows 7 i got this error when i run that project.

"Failed to update database "c:\Program Files\Test\Test.mdf" because that database is read-only."

but if we install with windows xp it is working good.

Can any one please help me it is very urgent?



thanks and regards

Ram.

Responses
Author: Santhakumar Munuswamy             
Posted Date: September 06, 2015     Points: 20   

Hi Ram,

Kindly change your database access rights to normal mode as following steps

1. Open SQL Server Query window from the SSMS
2. Write a query and execute it

Example:

Use [DatabaseName]
Go
Alter Database [DatabaseName] set Read_Write with No_Wait


After, executing the above query your database will change normal mode.




Regards,
Santhakumar Munuswamy
http://www.san2debug.net/


Post Reply

You must Sign In To post reply
 
 
Find more Forum Questions on C#, ASP.Net, Vb.Net, SQL Server and more Here
Quick Links For Forum Categories:
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  OOPs  SilverlightIISJQuery
JavaScript/VBScriptBiztalkWPFPatten/PracticesWCFOthers
www.DotNetSpark.comUnAnsweredAll

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend