DWS - Problem with WCF End Points Service Generation in VB

2 posts, 0 answers
  1. Timothy
    Timothy avatar
    2 posts
    Member since:
    Jun 2012

    Posted 15 Jul 2010 Link to this post

    I've found the following problem when trying to compile after creating a WCF EndPoints Service using the DSW in Visual Studio 2008 using VB.  The DataManager class has a problem.  First it creates a reference to System.Linq.Dynamic.  We're not using a reference to that assembly, but rather are using the code directly from the DynamicLinq.vb class created by the DSW.  So OK fine, let's comment that one out.

    Imports System.Collections
    Imports System.Collections.Generic
    Imports System.Globalization
    Imports System.Linq
    'Imports System.Linq.Dynamic
    Imports System.Reflection
    Imports System.Text
    Imports Telerik.OpenAccess

    Next, there's a problem win the Search Entities Function

    This statement, produces a compile error with Option Strict on.
    Dim results = scope.Extent(Of T)().Where(paramString.ToString(), paramValues.ToArray())

    The error is as follows:
    Error 1 Overload resolution failed because no accessible 'Where' is most specific for these arguments:
        Extension method 'Public Function Where(predicate As String, ParamArray values() As Object) As System.Linq.IQueryable(Of T)' defined in 'WVMSwcfService.DynamicQueryable': Not most specific.
        Extension method 'Public Function Where(predicate As String, ParamArray values() As Object) As System.Linq.IQueryable(Of T)' defined in 'WVMSwcfService.DynamicQueryable': Not most specific. C:\Users\Tim.HOME\Documents\@WVenture\Development\Matter Subscription\trunk\code\WVMSwcfService\DataManager.vb 233 27 WVMSwcfService


    So, because this is an implementation of the DynamicQueryable class as far as I can tell, I thought what you might actually mean is:

    'Dim results = scope.Extent(Of T)().Where(paramString.ToString(), paramValues.ToArray())
    Dim results = DynamicQueryable.Where(scope.Extent(Of T)(), paramString.ToString, paramValues.ToArray())

    I'll definitely admit that I'm in over my head here, but this should provide the search criteria you're looking for correct?  If it's right, please modify the creation of the DataManager.vb from the DSW to include these changes.
  2. Missing user
    Missing user avatar

    Posted 15 Jul 2010 Link to this post

    Hi Timothy,

    First I would like to thank you about your notification on this problem, you are right about excluding the import statement and modifying the call to the Where function.
    We will include your suggestions in the upcoming release.
    Your feedback is always welcome, please feel free to share any other suggestions and sorry for the inconvenience caused.

    Greetings,
    Rizk Sobhi
    the Telerik team
    Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
  3. DevCraft banner
Back to Top