<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Powertips &#187; Enum</title>
	<atom:link href="http://scripting.chaindb.com/category/dotnet/enum-dotnet/feed/" rel="self" type="application/rss+xml" />
	<link>http://scripting.chaindb.com</link>
	<description>Programmer tips</description>
	<lastBuildDate>Tue, 15 May 2012 23:56:52 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>How to use Bitwise in Vb.Net</title>
		<link>http://scripting.chaindb.com/2011/08/08/how-to-use-bitwise-in-vb-net/</link>
		<comments>http://scripting.chaindb.com/2011/08/08/how-to-use-bitwise-in-vb-net/#comments</comments>
		<pubDate>Mon, 08 Aug 2011 07:11:31 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[Enum]]></category>
		<category><![CDATA[VB.Net]]></category>
		<category><![CDATA[bitwise or]]></category>
		<category><![CDATA[enum]]></category>
		<category><![CDATA[vb.net]]></category>

		<guid isPermaLink="false">http://scripting.chaindb.com/?p=1016</guid>
		<description><![CDATA[Enum eStatusNumber One = 1 Two = 2 Three = 4 Four = 16 Five = 32 End Enum Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Test(eStatusNumber.Five Or eStatusNumber.Three) End Sub Private Sub Test(ByVal com As eStatusNumber) If (com And eStatusNumber.One) = eStatusNumber.One Then MsgBox("One") End If If (com And [...]]]></description>
			<content:encoded><![CDATA[<pre>    Enum eStatusNumber
        One = 1
        Two = 2
        Three = 4
        Four = 16
        Five = 32
    End Enum

    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Test(eStatusNumber.Five Or eStatusNumber.Three)
    End Sub

    Private Sub Test(ByVal com As eStatusNumber)
        If (com And eStatusNumber.One) = eStatusNumber.One Then
            MsgBox("One")
        End If
        If (com And eStatusNumber.Two) = eStatusNumber.Two Then
            MsgBox("Two")
        End If

        If (com And eStatusNumber.Three) = eStatusNumber.Three Then
            MsgBox("Three")
        End If
        If (com And eStatusNumber.Four) = eStatusNumber.Four Then
            MsgBox("Four")
        End If

        If (com And eStatusNumber.Five) = eStatusNumber.Five Then
            MsgBox("Five")
        End If

    End Sub</pre>
<pre></pre>
<pre>VB.Net code can be downloaded here "<a href="http://scripting.chaindb.com/wp-content/uploads/2011/08/EnumBitWise.zip">EnumBitWise Sample</a>".</pre>
<pre><a href="http://weblogs.asp.net/wim/archive/2004/04/07/109095.aspx" target="_blank">Reference 1</a></pre>
<pre><a href="http://weblogs.asp.net/cumpsd/archive/2004/06/28/168112.aspx" target="_blank">Reference 2</a></pre>
<pre></pre>
]]></content:encoded>
			<wfw:commentRss>http://scripting.chaindb.com/2011/08/08/how-to-use-bitwise-in-vb-net/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

