Cannot explicitly call operator or accessor

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Gav

    Cannot explicitly call operator or accessor

    What is this error message all about?

    I cannot find anything about it on the net... it is giving me this error
    from code i have found on the net that should work but for me i get a load
    of these errors. If anyone could help it would be great?

    Thanks
    Gav


  • Bruce Wood

    #2
    Re: Cannot explicitly call operator or accessor

    Could you post the code, or a link to where you got the code, and
    indicate the exact text of the error message and indicate which line(s)
    of code are causing it?

    Comment

    • Gav

      #3
      Re: Cannot explicitly call operator or accessor

      Thanks for replying but I have had an answer from a different newsgroup.

      I was trying to set the IsNullable value to true for a parameter.

      I was trying to use:

      parameter1.set_ IsNullable(true );

      when I should have been using:

      parameter1.IsNu llable = true;

      //This one doesn't come up in VS as an option.

      Thanks again
      Gav

      "Bruce Wood" <brucewood@cana da.com> wrote in message
      news:1117214350 .515860.304580@ f14g2000cwb.goo glegroups.com.. .[color=blue]
      > Could you post the code, or a link to where you got the code, and
      > indicate the exact text of the error message and indicate which line(s)
      > of code are causing it?
      >[/color]


      Comment

      • cody

        #4
        Re: Cannot explicitly call operator or accessor

        you are not allowed to call accessors like set_Color(newCo lor); but instead
        you have to write Color = newColor; because it is a property.


        "Gav" <spam@spam.co m> schrieb im Newsbeitrag
        news:ugy36EqYFH A.584@TK2MSFTNG P15.phx.gbl...[color=blue]
        > What is this error message all about?
        >
        > I cannot find anything about it on the net... it is giving me this error
        > from code i have found on the net that should work but for me i get a load
        > of these errors. If anyone could help it would be great?
        >
        > Thanks
        > Gav
        >
        >[/color]


        Comment

        Working...