Click here to Skip to main content
15,886,518 members
Articles / Desktop Programming / Win32

Programming for Microsoft Windows Vista and Server 2008 (Windows 7)

Rate me:
Please Sign up or sign in to vote.
4.46/5 (30 votes)
19 Apr 2009CPOL8 min read 63.3K   670   69  
This article exposes the Microsoft Vista and Server 2008 (and Windows 7) exclusive features that can be programmed using .NET languages like C#. It includes UAC, the Vista Bridge control library, and the Windows Search Provider.
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
using Microsoft.SDK.Samples.VistaBridge.Dialogs;
using Microsoft.SDK.Samples.VistaBridge.Controls;

namespace VistaCommandLink
{
    public partial class GUIVistaCommandLink : GlassForm
    {
        private CommandLinkWinForms commandLinkDemo = new CommandLinkWinForms();

        public GUIVistaCommandLink()
        {
            InitializeComponent();
            commandLinkDemo.NoteText = "This is the Note Text on the Windows Vista type Button";
            commandLinkDemo.ShieldIcon = true;
            commandLinkDemo.Text = "This Command Link control is a part of Vista Library";
            commandLinkDemo.UseVisualStyleBackColor = true;
            commandLinkDemo.Location = new Point(20, 20);
            commandLinkDemo.Size = new Size(300,100);
            commandLinkDemo.Click += new EventHandler(this.OnCommandBtnClicked);
            this.Controls.Add(commandLinkDemo);
        }

        protected void OnCommandBtnClicked(object src, EventArgs ev)
        {
            MessageBox.Show("Command Link button clicked.", "Vista command Link Demo", MessageBoxButtons.OK, MessageBoxIcon.Information);
        }
        private void Form1_Load(object sender, EventArgs e)
        {
            this.IsGlassEnabled = true;
        }
    }
}

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
Student Institute of RadioPhysics & Electronics
India India
......

Comments and Discussions