Search the web
Sign In
New User? Sign Up
StrongTypes · Free .NET Generics Help
? Already a member? Sign in to Yahoo!

Yahoo! Groups Tips

Did you know...
Real people. Real stories. See how Yahoo! Groups impacts members worldwide.

Best of Y! Groups

   Check them out and nominate your group.
Having problems with message search? Fill out this form to ensure your group is one of the first to be migrated to the new message search system.

Messages

  Messages Help
Advanced
Generics: ObjectDataSource, GridView, and BLL   Message List  
Reply | Forward Message #16 of 44 |
RE: [StrongTypes] Generics: ObjectDataSource, GridView, and BLL

Hi Dave,

This most likely has to do with the primary key. Make sure that the primary
key is included in the DataKeyNames property for the GridView.

HTH

Thank you,
Ryan Olshan
Website - http://www.StrongTypes.com <http://www.strongtypes.com/>
Group - http://groups.yahoo.com/group/StrongTypes
Blog - http://blogs.dirteam.com/blogs/ryan/


_____

From: StrongTypes@yahoogroups.com [mailto:StrongTypes@yahoogroups.com] On
Behalf Of preludeandave
Sent: Wednesday, February 15, 2006 10:18 PM
To: StrongTypes@yahoogroups.com
Subject: [StrongTypes] Generics: ObjectDataSource, GridView, and BLL


Hi everyone,

I love the idea of generics and am trying to put it to use,
following the samples given on www.asp.net tutorials, specifically:
http://www.asp.net/QuickStart/util/srcview.aspx?
path=~/aspnet/samples/data/GridViewObject.src&file=GridViewObject_vb\
GridViewObject_vb.aspx&lang=VB+Source

I've set up my GridView to access the ObjectDataSource, and my ODS
is set up as:
<asp:ObjectDataSource ID="AllergyODS" Runat="server"
TypeName="AllergiesComponent"

SelectMethod="GetAllergies" UpdateMethod="UpdateAllergy"
DataObjectTypeName="Allergy" SortParameterName="SortExpression">

</asp:ObjectDataSource>

However, whenever I hit Update, I get the dreaded:
ObjectDataSource 'AllergyODS' could not find a non-generic
method 'UpdateAllergy' that takes parameters of type 'Allergy'.

Does anybody have a clue:
a) why this doesn't work as per the examples supplied on asp.net?
b) how I can find the signature of the function that it is trying to
call?

Thanks,
Dave








_____

YAHOO! GROUPS LINKS



* Visit your group "StrongTypes
<http://groups.yahoo.com/group/StrongTypes> " on the web.


* To unsubscribe from this group, send an email to:
StrongTypes-unsubscribe@yahoogroups.com
<mailto:StrongTypes-unsubscribe@yahoogroups.com?subject=Unsubscribe>


* Your use of Yahoo! Groups is subject to the Yahoo! Terms of Service
<http://docs.yahoo.com/info/terms/> .


_____




[Non-text portions of this message have been removed]




Thu Feb 16, 2006 6:28 am

teranetlists
Offline Offline
Send Email Send Email

Forward
Message #16 of 44 |
Expand Messages Author Sort by Date

Hi everyone, I love the idea of generics and am trying to put it to use, following the samples given on www.asp.net tutorials, specifically: ...
preludeandave
Offline Send Email
Feb 16, 2006
6:21 am

Hi Dave, This most likely has to do with the primary key. Make sure that the primary key is included in the DataKeyNames property for the GridView. HTH Thank...
Ryan Olshan
teranetlists
Offline Send Email
Feb 16, 2006
6:30 am

Thanks Ryan, Ok, that wasn't the problem. I had that specified in the GridView already. The problem was my function UpdateAllergy, this is what it should be: ...
preludeandave
Offline Send Email
Feb 17, 2006
3:49 am
Advanced

Copyright © 2009 Yahoo! Inc. All rights reserved.
Privacy Policy - Terms of Service - Guidelines - Help