<?xml version="1.0" encoding="iso-8859-1"?>
<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/">
	<channel>
		<title>Code Vault</title>
		<link>http://programmingstuff.forumotion.com/code-vault-f6/-t1.htm</link>
		<description>Post scripts that you've written.</description>
		<lastBuildDate>Mon, 01 Sep 2008 16:20:30 GMT</lastBuildDate>
		<ttl>10</ttl>
		<image>
			<title>Code Vault</title>
			<url>http://illiweb.com/fa/prosilver_grey/site_logo.gif</url>
			<link>http://programmingstuff.forumotion.com/code-vault-f6/-t1.htm</link>
		</image>
		<item>
			<title>Gamble: Higher or Lower?</title>
			<link>http://programmingstuff.forumotion.com/code-vault-f6/gamble-higher-or-lower-t10.htm</link>
			<dc:creator>Robin</dc:creator>
			<description>I guess some people know this little game...



Code:Public Class Form1



    Private Sub Button1_Click&#40;ByVal sender As System.Object, ByVal e As System.EventArgs&#41; Handles Button1.Click

        

        Dim spin As String = Int&#40;Rnd&#40;&#41; * 12&#41;

        Label9.Text = Label1.Text

        Label1.Text = spin



        If Label9.Text &gt; Label1.Text Then

   ...</description>
			<category>Code Vault</category>
			<pubDate>Mon, 01 Sep 2008 16:20:30 GMT</pubDate>
			<comments>http://programmingstuff.forumotion.com/code-vault-f6/gamble-higher-or-lower-t10.htm#10</comments>
			<guid>http://programmingstuff.forumotion.com/code-vault-f6/gamble-higher-or-lower-t10.htm</guid>
		</item>
		<item>
			<title>Save a (.txt) File On Form Closing</title>
			<link>http://programmingstuff.forumotion.com/code-vault-f6/save-a-txt-file-on-form-closing-t4.htm</link>
			<dc:creator>conorsteel</dc:creator>
			<description>Things You'll Need

1 RichTextBox [RichTextBox1]



Select The Form_Closing Event



Type The Following Code:



Code:Dim reply

        reply = MsgBox&#40;&quot;Do you want to Save before you Exit?&quot;, 52&#41;

        If reply = 6 Then

            Dim SFD As New SaveFileDialog

            With SFD

                .Filter = &quot;Text Files  ...</description>
			<category>Code Vault</category>
			<pubDate>Sun, 31 Aug 2008 16:31:00 GMT</pubDate>
			<comments>http://programmingstuff.forumotion.com/code-vault-f6/save-a-txt-file-on-form-closing-t4.htm#4</comments>
			<guid>http://programmingstuff.forumotion.com/code-vault-f6/save-a-txt-file-on-form-closing-t4.htm</guid>
		</item>
		<item>
			<title>List All User Accounts</title>
			<link>http://programmingstuff.forumotion.com/code-vault-f6/list-all-user-accounts-t2.htm</link>
			<dc:creator>conorsteel</dc:creator>
			<description>This will return a list of all users in a computer.



Make sure to have &quot;Imports System.Management&quot; at the beginning of any code file this is in.

If you need to, add a reference to System.Management.dll



WARNING: Hidden users such as Guest and Administrator and other miscellaneous accounts my be in your computer.



CODE

    Private Function AllUsers() As String()

        Dim R As New List(Of String)



        Dim query As New SelectQuery(&quot;Win32_UserAccount&quot;)

  ...</description>
			<category>Code Vault</category>
			<pubDate>Sun, 31 Aug 2008 14:07:29 GMT</pubDate>
			<comments>http://programmingstuff.forumotion.com/code-vault-f6/list-all-user-accounts-t2.htm#2</comments>
			<guid>http://programmingstuff.forumotion.com/code-vault-f6/list-all-user-accounts-t2.htm</guid>
		</item>
	</channel>
</rss>