Footer.vb

 'Programmed by    :   Rey Sean Adorio Cañeso
'Address          :   28 I.B. Upper Calarian, Zamboanga City, Philippines
'Cell No          :   +639154684127
'
'Footer.cs
'No. of Lines     :   109
'Date Modified    :   03-11-2011

Imports System
Imports System.ComponentModel
Imports System.Collections.Generic
Imports System.Diagnostics
Imports System.Text
Imports System.Windows.Forms
Imports System.Drawing

Public Class Footer
    Inherits System.Windows.Forms.Panel

#Region "Variables/Objects"

    Dim _showLine As Boolean = True
    Dim _showBorder As Boolean = False

#End Region

#Region "Properties"

    Public Property ShowLine() As Boolean
        Get
            Return Me._showLine
        End Get
        Set(ByVal value As Boolean)
            Me._showLine = value
        End Set
    End Property

    Public Property ShowBorder() As Boolean
        Get
            Return Me._showBorder
        End Get
        Set(ByVal value As Boolean)
            Me._showBorder = value
        End Set
    End Property

#End Region

#Region "Events"

    Private Sub Footer_Resize(ByVal sender As Object, ByVal e As EventArgs) Handles Me.Resize
        Me.Size = New System.Drawing.Size(Me.Width, 46)
    End Sub

    Private Sub Footer_Paint(ByVal sender As Object, ByVal e As PaintEventArgs) Handles Me.Paint
        If _showLine Then
            e.Graphics.DrawLine(New System.Drawing.Pen(Color.LightGray), 0, 1, Me.Width, 1)
            e.Graphics.DrawLine(New System.Drawing.Pen(Color.GhostWhite), 0, 2, Me.Width, 2)
        End If

        If _showBorder Then
            e.Graphics.DrawLine(New System.Drawing.Pen(Color.DodgerBlue), 0, Me.Height - 1, Me.Width, Me.Height - 1)
            e.Graphics.DrawLine(New System.Drawing.Pen(Color.DodgerBlue), 0, 0, 0, Me.Height)
            e.Graphics.DrawLine(New System.Drawing.Pen(Color.DodgerBlue), Me.Width - 1, 0, Me.Width - 1, Me.Height)
        End If
    End Sub

#End Region

End Class

Project Homepage: