<?xml version="1.0"?>
<CodeSnippets xmlns="http://schemas.microsoft.com/VisualStudio/2005/CodeSnippet">
  <CodeSnippet Format="1.0.0">
    <Header>
      <Title>Resize a Button Dynamically by using AutoSize</Title>
      <Author>Microsoft Corporation</Author>
      <Description>Uses AutoSize to dynamically resize a button to the length of its text.</Description>
      <Shortcut>butAutoSize</Shortcut>
    </Header>
    <Snippet>
		<References>
			<Reference>
				<Assembly>System.Drawing.dll</Assembly>
				<Url />
			</Reference>
			<Reference>
				<Assembly>System.Windows.Forms.dll</Assembly>
				<Url />
			</Reference>
		</References>
		<Imports>
			<Import>
				<Namespace>System</Namespace>
			</Import>
			<Import>
				<Namespace>System.Drawing</Namespace>
			</Import>
			<Import>
				<Namespace>Microsoft.VisualBasic</Namespace>
			</Import>
		</Imports>
		<Declarations>
        <Object>
          <ID>buttonName</ID>
          <Type>Button</Type>
          <ToolTip>Replace with a button on your form.</ToolTip>
          <Default>Button1</Default>
        </Object>
      </Declarations>
      <Code Language="VB" Kind="method body"><![CDATA[$buttonName$.AutoSize = True
]]></Code>
    </Snippet>
  </CodeSnippet>
</CodeSnippets>