Welcome to Dream.In.Code
Become a C# Expert!

Join 150,403 C# Programmers for FREE! Get instant access to thousands of C# experts, tutorials, code snippets, and more! There are 933 people online right now. Registration is fast and FREE... Join Now!




bool != DialogResult

 
Reply to this topicStart new topic

bool != DialogResult

gilbert
26 Mar, 2008 - 06:49 PM
Post #1

D.I.C Head
**

Joined: 18 Mar, 2008
Posts: 81


My Contributions
I get this error message about bool != dialogresult
CODE
DialogResult dr = MessageBox.Show("Would you like unlimited access?", "Access",MessageBoxButtons.YesNo);
        if (dr = DialogResult.Yes)

FIX IT!

Edit: Please?

This post has been edited by gilbert: 26 Mar, 2008 - 06:50 PM
User is offlineProfile CardPM
+Quote Post

killnine
RE: Bool != DialogResult
26 Mar, 2008 - 07:30 PM
Post #2

D.I.C Head
**

Joined: 12 Feb, 2007
Posts: 114



Thanked: 5 times
My Contributions
QUOTE(gilbert @ 26 Mar, 2008 - 07:49 PM) *

I get this error message about bool != dialogresult
CODE
DialogResult dr = MessageBox.Show("Would you like unlimited access?", "Access",MessageBoxButtons.YesNo);
        if (dr = DialogResult.Yes)

FIX IT!

Edit: Please?



dr == DiaglogResult.Yes


otherwise you are trying to set dr TO the value of Yes.
User is offlineProfile CardPM
+Quote Post

gilbert
RE: Bool != DialogResult
26 Mar, 2008 - 07:45 PM
Post #3

D.I.C Head
**

Joined: 18 Mar, 2008
Posts: 81


My Contributions
THANK YOU ugh stupid typos in my book teachin me wrong
User is offlineProfile CardPM
+Quote Post

Fast ReplyReply to this topicStart new topic
Time is now: 1/9/09 07:19PM

Be Social

Dream.In.Code RSS Feed Dream.In.Code LinkedIn Group Follow Us On Twitter

Live C# Help!

C# Tutorials

Reference Sheets

C# Snippets

DIC Chatroom

Bye Bye Ads

Monthly Drawing

Thumb Drive

Top Contributors

Top 10 Kudos This Month