Solved

Operator '&&' cannot be applied to operands of type 'bool' and 'method group'

Posted on 2006-11-28
3
2,381 Views
Last Modified: 2011-04-14
Not sure what I'm doing wrong here and is there a better way to code the method?  (FYI: I used sss to hide the real names here for privacy purposes)

                if (chkSubmit.Checked && CheckRequiredSSS)
                {
                     ...do something
                 }

    protected bool CheckRequiredSSS()
    {
        if (sss.DataTier.sss.ContentItemType.Values.ssss != null)
        {
            return true;
        }
        else
        {
            return false;
        }
    }

Error: Operator '&&' cannot be applied to operands of type 'bool' and 'method group'
0
Comment
Question by:dba123
  • 2
3 Comments
 
LVL 142

Accepted Solution

by:
Guy Hengel [angelIII / a3] earned 500 total points
ID: 18031064
               if (chkSubmit.Checked == true && CheckRequiredSSS == true)
0
 
LVL 1

Author Comment

by:dba123
ID: 18031083
whoops, here's the resolution, duh

if (chkSubmit.Checked && CheckRequiredSSS())
0
 
LVL 1

Author Comment

by:dba123
ID: 18031087
or yours works also...
0

Featured Post

Maximize Your Threat Intelligence Reporting

Reporting is one of the most important and least talked about aspects of a world-class threat intelligence program. Here’s how to do it right.

Join & Write a Comment

IntroductionWhile developing web applications, a single page might contain many regions and each region might contain many number of controls with the capability to perform  postback. Many times you might need to perform some action on an ASP.NET po…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…
You have products, that come in variants and want to set different prices for them? Watch this micro tutorial that describes how to configure prices for Magento super attributes. Assigning simple products to configurable: We assigned simple products…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now