Wrox Programmer Forums
|
BOOK: ASP.NET 3.5 Enterprise Application Development with Visual Studio 2008: Problem Design Solutio
This is the forum to discuss the Wrox book ASP.NET 3.5 Enterprise Application Development with Visual Studio 2008: Problem Design Solution by Vincent Varallo; ISBN: 9780470396865
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: ASP.NET 3.5 Enterprise Application Development with Visual Studio 2008: Problem Design Solutio 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 October 11th, 2010, 10:41 AM
Registered User
 
Join Date: Dec 2009
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Default CutomGridView , BindGridView

I am having some problems with the BindGridView method of CustomGridView Control. Following are the error details. If anyone could help me I 'll be really thankful .......
System.MissingMethodException was unhandled by user code
Message=Method 'MFERIS.SPS.SPSCategoryEOList.SortByPropertyName' not found.
Source=mscorlib
StackTrace:
at System.RuntimeType.InvokeMember(String name, BindingFlags bindingFlags, Binder binder, Object target, Object[] providedArgs, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParams)
at System.Type.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args)
at MFERIS.CustomGridView.BindGridView(String sortExpression, SortDirection sortDirection) in C:\Users\MUSA\Documents\VS2008\Projects\MFERIS\MFE RIS\Controls\CustomGridView.cs:line 138
at MFERIS.CustomGridView.DataBind() in C:\Users\MUSA\Documents\VS2008\Projects\MFERIS\MFE RIS\Controls\CustomGridView.cs:line 124
at MFERIS.SpareParts.Categories.Page_Load(Object sender, EventArgs e) in C:\Users\MUSA\Documents\VS2008\Projects\MFERIS\MFE RIS\SpareParts\Categories.aspx.cs:line 37
at System.Web.Util.CalliHelper.EventArgFunctionCaller (IntPtr fp, Object o, Object t, EventArgs e)
at System.Web.Util.CalliEventHandlerDelegateProxy.Cal lback(Object sender, EventArgs e)
at System.Web.UI.Control.OnLoad(EventArgs e)
at System.Web.UI.Control.LoadRecursive()
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
InnerException:


I may be wrong but in my view the problem is in the following line of code
with sortExpression
base.DataSource = objectType.InvokeMember("SortByPropertyName", BindingFlags.InvokeMethod, null, ListObject, new object[] { sortExpression, sortDirection = SortDirection.Ascending });

regards
Zia Ul Hassan
 
Old November 25th, 2010, 02:17 PM
Registered User
 
Join Date: Nov 2010
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default

I am also having the same problem and this has stalled my learning process for the last two weeks. I have tried all I could to no avail. Pls pls anybody out there who can help?????
 
Old November 26th, 2010, 08:50 AM
Registered User
 
Join Date: Dec 2009
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Dear Goodshow,
could you please send me your code. In my case there was a typing error.
I was using small case instead of upper case.
So please check your code carefully.
I hope this will help
Best Regards
Zia
 
Old November 26th, 2010, 08:59 AM
Registered User
 
Join Date: Dec 2009
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Dear GoodShow
I was using this
sortDirection = SortDirection.Ascending
while it should be this
sortDirection == SortDirection.Ascending
Please note the difference of =.
I hope this will help
Best regards
Zia
 
Old December 15th, 2010, 10:02 AM
Registered User
 
Join Date: Nov 2010
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default CutomGridView , BindGridView

When I run the program in Chap 4 and click on the Users link under Security, this part of the code is highlighted:

base.DataSource = objectType.InvokeMember("SortByPropertyName", BindingFlags.InvokeMethod, null, listObject, new object[] { sortExpression, sortDirection == SortDirection.Ascending });


followed by this message in the error messagebox:

Method 'V2.PaidTimeOffBLL.Framework.ENTUserAccountEOList. SortByPropertyName' not found.

Please help! What am I doing wrong? Thanx for any help in solving this.









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