Click here to Skip to main content
12,397,059 members (67,540 online)
Rate this:
 
Please Sign up or sign in to vote.
i used this link http://msdn.microsoft.com/en-us/library/bb386921[^] to use the copytodatatable method .I am getting an error at the copytodatatable method inside the CustomLINQtoDataSetMethods.it is saying that:
Extension method must be defined inside the top level static class
Posted 17-May-12 22:35pm
Updated 18-May-12 10:16am
v2

1 solution

Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 1

As explained here http://msdn.microsoft.com/en-us/library/bb384228(v=vs.90).aspx[^] the above error is generated when the class in which extension methods are defined is a nested class. So please check your class and make it top level static class.
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month


Advertise | Privacy | Mobile
Web02 | 2.8.160721.1 | Last Updated 18 May 2012
Copyright © CodeProject, 1999-2016
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100