Click here to Skip to main content
15,881,424 members
Articles / Web Development / ASP.NET

Notes: An MSDN Websites Style Custom Notes Control in ASP.NET and C#

Rate me:
Please Sign up or sign in to vote.
4.76/5 (22 votes)
25 Jan 2008CPOL2 min read 47.7K   35  
A Microsoft website style notes control using a web usercontrol in ASP.NET and C#.
using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Drawing;

public partial class _Default : System.Web.UI.Page 
{
    protected void Page_Load(object sender, EventArgs e)
    {


        Notes1.NotesSize = "Short";
        Notes1.HeaderText = "Notes:";

        Notes1.imagePath = "Notes.gif";
        Notes1.Description = "Your Notes";

        Notes1.BackColor = Color.LightSalmon;






        # region Notes1
        //Creating one Notes
        // Specify the Size of Notes
        Notes1.NotesSize = "Short";
        // Image and it should be 16*16 
        Notes1.imagePath = "Notes.gif";
        //Give the Title of Notes
        Notes1.HeaderText = "Visit CodeProject";
        //Write Your Description
        Notes1.Description = " You can Visit us at <a href=http://www.Codeproject.com/>CodeProject</a>";
        // Set the Color 
        Notes1.BackColor = System.Drawing.Color.LightSalmon;
        #endregion

        #region Notes2
        Notes2.NotesSize = "Medium";
        Notes2.imagePath = "Security.gif";
        Notes2.HeaderText = "Security:";
        Notes2.Description = "This is another type of Notes, and It's Medium Size.";
        Notes2.BackColor = System.Drawing.Color.LightGray;
        #endregion

        #region Notes3
        Notes3.NotesSize = "Short";
        Notes3.imagePath = "Notes.gif";
        Notes3.HeaderText = "Importants:";
        Notes3.Description = "This is one Short notes.MSDN Style. ";
        Notes3.BackColor = System.Drawing.Color.LightPink;
        #endregion

        #region Notes4
        Notes4.NotesSize = "Long";
        Notes4.imagePath = "Notes.gif";
        Notes4.HeaderText = "Notes:";
        Notes4.Description = "But, Here is something more. You can You custom color and custom icon, Very Easy to use. Just Drag and Drop";
        Notes4.BackColor = System.Drawing.Color.LightSeaGreen;
        #endregion

    }
   
}

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Technical Lead
India India
.NET Consultant | Former Microsoft MVP - ASP.NET | CodeProject MVP, Mentor, Insiders| Technology Evangelist | Author | Speaker | Geek | Blogger | Husband

Blog : http://abhijitjana.net
Web Site : http://dailydotnettips.com
Twitter : @AbhijitJana
My Kinect Book : Kinect for Windows SDK Programming Guide

Comments and Discussions