Wrox Programmer Forums
|
BOOK: Beginning ASP.NET 1.1
This is the forum to discuss the Wrox book Beginning ASP.NET 1.1 with Visual C#.NET 2003 by Chris Ullman, John Kauffman, Chris Hart, Dave Sussman, Daniel Maharry; ISBN: 9780764557088
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning ASP.NET 1.1 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old July 11th, 2005, 05:25 AM
Registered User
 
Join Date: Jul 2005
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default ASP.net / database connectivity error

Hello,

I'm very new to asp.net and web programming in general but I've made some progress in the last few days but am currently struggling with an error I cant get past.

I'm using Windows XP and Dreamweaver. I've got an MS Access database and I've created the connection to it in Dreamweaver successfully. I'm using the ASP.net VB option.

In Dreamweaver I've made a couple of pages and in one of them I've added a dataview object (sorry if my terminology isnt correct). I've opened the page in IE and it's worked fine (displayed all the records from the database table).

However, when I added a 'insert record' object it prompts me to enter the new record but then I get this error...

System.Data.OleDb.OleDbException: Operation must use an updateable query.
at System.Data.OleDb.OleDbCommand.ExecuteCommandTextE rrorHandling(Int32 hr)
at System.Data.OleDb.OleDbCommand.ExecuteCommandTextF orSingleResult(tagDBPARAMS dbParams, Object& executeResult)
at System.Data.OleDb.OleDbCommand.ExecuteCommandText( Object& executeResult)
at System.Data.OleDb.OleDbCommand.ExecuteCommand(Comm andBehavior behavior, Object& executeResult)
at System.Data.OleDb.OleDbCommand.ExecuteReaderIntern al(CommandBehavior behavior, String method)
at System.Data.OleDb.OleDbCommand.ExecuteNonQuery()
at DreamweaverCtrls.DataSet.DoInit()


I've trawled the forums and mostly they mention read/write privileges. I'm not exactly sure how to add these (or if indeed this is the problem) but this is what I've done;

control panel - administrative tools - Internet Information Services

added ticks in read and write to all the folders. it was set to 'scripts only' which i've heard is correct.

I've also tried to make the database not read only and the folder it's in. I've noticed that the read only 'tick' has a habit of returning though.

I tried for a few hours yesterday to get past this prob, any help would be appreciated!

thanks

rich

 
Old July 12th, 2005, 03:37 AM
Friend of Wrox
 
Join Date: Apr 2005
Posts: 186
Thanks: 0
Thanked 0 Times in 0 Posts
Default

hi,

Your ASP.Net Process user does not has privilage to modify Access DB. SO you have grand write privilage to the folder in which you Access DB resides. You can use the security tab on properties of the folder and add the IUSR_<MachineName> to the list with write permission.

Prashant


 
Old July 12th, 2005, 01:09 PM
Imar's Avatar
Wrox Author
 
Join Date: Jun 2003
Posts: 17,089
Thanks: 80
Thanked 1,576 Times in 1,552 Posts
Default

Hi Rich,

What Prashant said is true in that you need to change the permissions for the account the web server is running under. However, the IUSR_MachineName he suggested won't do you any good (most likely) because you're running ASP.NET.

Check out this FAQ to find out the account IIS is using (most likely ASPNET) and then use this FAQ to find how to to set the security settings.

HtH

Imar
---------------------------------------
Imar Spaanjaars
Everyone is unique, except for me.
While typing this post, I was listening to: You Think I Ain't Worth A Dollar, But I Feel Like A Millionaire by Queens of the Stone Age (Track 2 from the album: Songs For The Deaf) What's This?
 
Old July 21st, 2005, 06:48 AM
Registered User
 
Join Date: Jul 2005
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
Default

thanks Chaps,

sorted!






Similar Threads
Thread Thread Starter Forum Replies Last Post
connectivity in asp.net 2005 suneet.pant Pro VB.NET 2002/2003 2 March 19th, 2008 09:13 AM
sql connectivity using stored procedure in asp.net krishna kumari Classic ASP Databases 2 January 17th, 2007 02:45 PM
ASP.NET connectivity with SQL server shupi Classic ASP Databases 0 September 19th, 2005 07:09 AM
DLL based database connectivity in VB.NET omkar_ghaisas ADO.NET 2 October 7th, 2004 12:59 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.