Mega Code Archive

 
Categories / VB.Net Tutorial / WPF
 

Windows Transparent Background

<Window x: Class="Windows.TransparentBackground"     xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"     xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"     Title="Windows" Height="300" Width="300"     WindowStyle="None" AllowsTransparency="true">   <Window.Background>         <ImageBrush ImageSource="c:\image.png"></ImageBrush>   </Window.Background>     <Grid>       <Grid.RowDefinitions>         <RowDefinition></RowDefinition>       </Grid.RowDefinitions>       <Button Margin="20" Grid.Row="2">Close</Button>        </Grid> </Window> //File:Window.xaml.vb Imports System Imports System.Collections.Generic Imports System.Text Imports System.Windows Imports System.Windows.Controls Imports System.Windows.Data Imports System.Windows.Documents Imports System.Windows.Input Imports System.Windows.Media Imports System.Windows.Media.Imaging Imports System.Windows.Shapes Namespace Windows   Public Partial Class TransparentBackground     Inherits System.Windows.Window     Public Sub New()       InitializeComponent()     End Sub   End Class End Namespace