473,394 Members | 2,168 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,394 software developers and data experts.

Visual Studio non-generic method bug

I have just spent a very frustrating morning reading postings on this problem
and nothing seems to work. I am trying to write a demo project in VB/ASP.net
2.0 and I am unable to get any sort of edit page to work. This is extremely
simple stuff, straight out of one of Microsoft's training videos. Drag a
table on to the xsd, create queries, then create a page with a bound
DetailsView (bound to a tableadapter). Then set the DetailsView to permit
edits. (The initial display of data works fine.) No code whatsoever.

No matter what I try, when I try to update the data I wind up with the
error:ObjectDataSource 'ObjectDataSource1' could not find a non-generic
method 'Update' that has parameters: ItemName, ItemDesc, ProjectLeadID,
StartDate, FinishDate, GatesId, Resources, original_ProjectId,
original_ItemID.

Is there any way to get this to work?
Nov 14 '07 #1
3 1178
ObjectDataSource expects its underlying type to have a method named Update.
Does yours have one? That's what the exception is saying. if you need sample
code, visit the ASP.NET Quickstarts tutorial at the asp.net website.

--Peter
http://www.eggheadcafe.com
unBlog: http://petesbloggerama.blogspot.com
BlogMetaFinder: http://www.blogmetafinder.com

"B. Chernick" wrote:
I have just spent a very frustrating morning reading postings on this problem
and nothing seems to work. I am trying to write a demo project in VB/ASP.net
2.0 and I am unable to get any sort of edit page to work. This is extremely
simple stuff, straight out of one of Microsoft's training videos. Drag a
table on to the xsd, create queries, then create a page with a bound
DetailsView (bound to a tableadapter). Then set the DetailsView to permit
edits. (The initial display of data works fine.) No code whatsoever.

No matter what I try, when I try to update the data I wind up with the
error:ObjectDataSource 'ObjectDataSource1' could not find a non-generic
method 'Update' that has parameters: ItemName, ItemDesc, ProjectLeadID,
StartDate, FinishDate, GatesId, Resources, original_ProjectId,
original_ItemID.

Is there any way to get this to work?
Nov 14 '07 #2
Ignore previous 'expression of opinion'. Finally found enough to get it to
work, at least in this example.

Basically:
1. Go into the update command string, eliminate all references to key fields
in the SET section, and get rid of anything that ISN"T a key field in the
WHERE clause.
2. Then setup the gridview in the usual fashion, but then go into the html
and set OldValuesParameterFormatString="{0}"

When are they going to fix this?

"B. Chernick" wrote:
I have just spent a very frustrating morning reading postings on this problem
and nothing seems to work. I am trying to write a demo project in VB/ASP.net
2.0 and I am unable to get any sort of edit page to work. This is extremely
simple stuff, straight out of one of Microsoft's training videos. Drag a
table on to the xsd, create queries, then create a page with a bound
DetailsView (bound to a tableadapter). Then set the DetailsView to permit
edits. (The initial display of data works fine.) No code whatsoever.

No matter what I try, when I try to update the data I wind up with the
error:ObjectDataSource 'ObjectDataSource1' could not find a non-generic
method 'Update' that has parameters: ItemName, ItemDesc, ProjectLeadID,
StartDate, FinishDate, GatesId, Resources, original_ProjectId,
original_ItemID.

Is there any way to get this to work?
Nov 14 '07 #3
Thanks. The PDFs may be of some use, but what are those people at ASP.net
thinking? They've forgotten to put the solution files in with the sample
code.

"Peter Bromberg [C# MVP]" wrote:
ObjectDataSource expects its underlying type to have a method named Update.
Does yours have one? That's what the exception is saying. if you need sample
code, visit the ASP.NET Quickstarts tutorial at the asp.net website.

--Peter
http://www.eggheadcafe.com
unBlog: http://petesbloggerama.blogspot.com
BlogMetaFinder: http://www.blogmetafinder.com

"B. Chernick" wrote:
I have just spent a very frustrating morning reading postings on this problem
and nothing seems to work. I am trying to write a demo project in VB/ASP.net
2.0 and I am unable to get any sort of edit page to work. This is extremely
simple stuff, straight out of one of Microsoft's training videos. Drag a
table on to the xsd, create queries, then create a page with a bound
DetailsView (bound to a tableadapter). Then set the DetailsView to permit
edits. (The initial display of data works fine.) No code whatsoever.

No matter what I try, when I try to update the data I wind up with the
error:ObjectDataSource 'ObjectDataSource1' could not find a non-generic
method 'Update' that has parameters: ItemName, ItemDesc, ProjectLeadID,
StartDate, FinishDate, GatesId, Resources, original_ProjectId,
original_ItemID.

Is there any way to get this to work?
Nov 14 '07 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

33
by: John Timbers | last post by:
I'd like to purchase Visual C# .Net for learning purposes only since it's a lot cheaper than Visual Studio (note that I'm a very experienced C++ developer). Can someone simply clarify the basic...
34
by: John Timbers | last post by:
I'd like to purchase Visual C# .Net for learning purposes only since it's a lot cheaper than Visual Studio (note that I'm a very experienced C++ developer). Can someone simply clarify the basic...
1
by: bharathreddy | last post by:
This Article gives an introduction to VSTS Team Foundation & fundamental difference between Visual Source Safe (VSS) and VSTS Team Foundation. Team Foundation is a set of tools and technologies...
1
by: cnixuser | last post by:
Hello, I am having a problem that I believe is related to the way a stream reader object looks for a text file by default. What I am doing is using a StreamReader object to read the text of a text...
2
by: Cramer | last post by:
So, what is the relationship between Visual Studio and Visual Web Developer. I find a lot of documentation on MSDN that presents Visual Web Developer as it's own stand-alone product (which I'd...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.