Browse Source

initial repo setup

Todd Boyd 7 years ago
parent
commit
20979de97e

+ 5 - 0
.gitignore

@@ -0,0 +1,5 @@
+*.suo
+*.pfx
+bin/
+obj/
+HelpfulHighlighter.csproj.user

+ 233 - 0
HelpfulHighlighter.csproj

@@ -0,0 +1,233 @@
+<Project ToolsVersion="3.5" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <!--
+    This section defines project-level properties.
+
+    AssemblyName
+      Name of the output assembly.
+    Configuration
+      Specifies a default value for debug.
+    OutputType
+      Must be "Library" for VSTO.
+    Platform
+      Specifies what CPU the output of this project can run on.
+    NoStandardLibraries
+      Set to "false" for VSTO.
+    RootNamespace
+      In C#, this specifies the namespace given to new files. In VB, all objects are
+      wrapped in this namespace at runtime.
+  -->
+  <PropertyGroup>
+    <ProjectTypeGuids>{BAA0C2D2-18E2-41B9-852F-F413020CAA33};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
+    <Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
+    <Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
+    <ProjectGuid>{454AA970-3BB8-4DFE-9AC5-4E9A55D4DAF3}</ProjectGuid>
+    <OutputType>Library</OutputType>
+    <NoStandardLibraries>false</NoStandardLibraries>
+    <RootNamespace>HelpfulHighlighter</RootNamespace>
+    <AssemblyName>HelpfulHighlighter</AssemblyName>
+    <TargetFrameworkVersion>v3.5</TargetFrameworkVersion>
+    <BootstrapperEnabled>true</BootstrapperEnabled>
+    <BootstrapperComponentsLocation>HomeSite</BootstrapperComponentsLocation>
+    <ManifestCertificateThumbprint>014C6871CAF2B26FA396EC32E6F1509D896F0A57</ManifestCertificateThumbprint>
+    <ManifestKeyFile>HelpfulHighlighter_TemporaryKey.pfx</ManifestKeyFile>
+    <SignManifests>true</SignManifests>
+  </PropertyGroup>
+  <ItemGroup>
+    <BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
+      <Visible>False</Visible>
+      <ProductName>.NET Framework 3.5 SP1</ProductName>
+      <Install>true</Install>
+    </BootstrapperPackage>
+    <BootstrapperPackage Include="Microsoft.VSTORuntime.3.0">
+      <Visible>false</Visible>
+      <ProductName>Visual Studio Tools for the Office system 3.0 Runtime Service Pack 1</ProductName>
+      <Install>true</Install>
+    </BootstrapperPackage>
+    <BootstrapperPackage Include="Microsoft.Windows.Installer.3.1">
+      <Visible>False</Visible>
+      <ProductName>Windows Installer 3.1</ProductName>
+      <Install>true</Install>
+    </BootstrapperPackage>
+    <BootstrapperPackage Include="Microsoft.Office.PIARedist.2007">
+      <Visible>false</Visible>
+      <ProductName>2007 Microsoft Office system Primary Interop Assemblies</ProductName>
+      <Install>true</Install>
+    </BootstrapperPackage>
+  </ItemGroup>
+  <PropertyGroup>
+    <!--
+      OfficeApplication
+        Add-in host application
+    -->
+    <OfficeApplication>Excel</OfficeApplication>
+  </PropertyGroup>
+  <!--
+    This section defines properties that are set when the "Debug" configuration is selected.
+
+    DebugSymbols
+      If "true", create symbols (.pdb). If "false", do not create symbols.
+    DefineConstants
+      Constants defined for the preprocessor.
+    EnableUnmanagedDebugging
+      If "true", starting the debugger will attach both managed and unmanaged debuggers.
+    Optimize
+      If "true", optimize the build output. If "false", do not optimize.
+    OutputPath
+      Output path of project relative to the project file.
+    WarningLevel
+      Warning level for the compiler.
+  -->
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
+    <DebugSymbols>true</DebugSymbols>
+    <DebugType>full</DebugType>
+    <Optimize>false</Optimize>
+    <OutputPath>bin\Debug\</OutputPath>
+    <EnableUnmanagedDebugging>false</EnableUnmanagedDebugging>
+    <DefineConstants>DEBUG;TRACE</DefineConstants>
+    <WarningLevel>4</WarningLevel>
+  </PropertyGroup>
+  <!--
+    This section defines properties that are set when the "Release" configuration is selected.
+
+    DebugSymbols
+      If "true", create symbols (.pdb). If "false", do not create symbols.
+    DefineConstants
+      Constants defined for the preprocessor.
+    EnableUnmanagedDebugging
+      If "true", starting the debugger will attach both managed and unmanaged debuggers.
+    Optimize
+      If "true", optimize the build output. If "false", do not optimize.
+    OutputPath
+      Output path of project relative to the project file.
+    WarningLevel
+      Warning level for the compiler.
+  -->
+  <PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
+    <DebugType>pdbonly</DebugType>
+    <Optimize>true</Optimize>
+    <OutputPath>bin\Release\</OutputPath>
+    <EnableUnmanagedDebugging>false</EnableUnmanagedDebugging>
+    <DefineConstants>TRACE</DefineConstants>
+    <WarningLevel>4</WarningLevel>
+  </PropertyGroup>
+  <!--
+    This section enables pre- and post-build steps. However, in VSTO use
+    MSBuild tasks instead of these properties.       
+  -->
+  <PropertyGroup>
+    <PreBuildEvent>
+    </PreBuildEvent>
+    <PostBuildEvent>
+    </PostBuildEvent>
+  </PropertyGroup>
+  <!--
+    This section specifies references for the project.
+  -->
+  <ItemGroup>
+    <Reference Include="Accessibility" />
+    <Reference Include="System" />
+    <Reference Include="System.AddIn, Version=3.5.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089, processorArchitecture=MSIL" />
+    <Reference Include="System.Data" />
+    <Reference Include="System.Drawing" />
+    <Reference Include="System.Windows.Forms" />
+    <Reference Include="System.Xml" />
+    <Reference Include="System.Core">
+      <RequiredTargetFramework>3.5</RequiredTargetFramework>
+    </Reference>
+    <Reference Include="System.Xml.Linq">
+      <RequiredTargetFramework>3.5</RequiredTargetFramework>
+    </Reference>
+    <Reference Include="System.Data.DataSetExtensions">
+      <RequiredTargetFramework>3.5</RequiredTargetFramework>
+    </Reference>
+    <Reference Include="Microsoft.Office.Tools.v9.0, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL" />
+    <Reference Include="Microsoft.Office.Tools.Common.v9.0, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL" />
+    <Reference Include="Microsoft.Office.Tools.Excel.v9.0, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL" />
+    <Reference Include="Microsoft.VisualStudio.Tools.Applications.Runtime.v9.0, Version=9.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL" />
+  </ItemGroup>
+  <ItemGroup>
+    <Reference Include="Office, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c">
+      <Private>False</Private>
+    </Reference>
+    <Reference Include="Microsoft.Office.Interop.Excel, Version=12.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c">
+      <Private>False</Private>
+    </Reference>
+    <Reference Include="stdole, Version=7.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
+      <Private>False</Private>
+    </Reference>
+  </ItemGroup>
+  <!--
+    This section defines the user source files that are part of the project.
+     
+    A "Compile" element specifies a source file to compile.
+    An "EmbeddedResource" element specifies an .resx file for embedded resources.
+    A "None" element specifies a file that is not to be passed to the compiler (for instance, 
+    a text file or XML file).
+    The "AppDesigner" element specifies the directory where the application properties files
+    can be found.
+  -->
+  <ItemGroup>
+    <Compile Include="HelpfulHighlighterRibbon.cs">
+      <SubType>Component</SubType>
+    </Compile>
+    <Compile Include="HelpfulHighlighterRibbon.Designer.cs">
+      <DependentUpon>HelpfulHighlighterRibbon.cs</DependentUpon>
+    </Compile>
+    <Compile Include="Properties\AssemblyInfo.cs">
+      <SubType>Code</SubType>
+    </Compile>
+    <EmbeddedResource Include="HelpfulHighlighterRibbon.resx">
+      <DependentUpon>HelpfulHighlighterRibbon.cs</DependentUpon>
+    </EmbeddedResource>
+    <EmbeddedResource Include="Properties\Resources.resx">
+      <Generator>ResXFileCodeGenerator</Generator>
+      <LastGenOutput>Resources.Designer.cs</LastGenOutput>
+      <SubType>Designer</SubType>
+    </EmbeddedResource>
+    <Compile Include="Properties\Resources.Designer.cs">
+      <AutoGen>True</AutoGen>
+      <DependentUpon>Resources.resx</DependentUpon>
+    </Compile>
+    <None Include="app.config" />
+    <None Include="HelpfulHighlighter_TemporaryKey.pfx" />
+    <None Include="Properties\Settings.settings">
+      <Generator>SettingsSingleFileGenerator</Generator>
+      <LastGenOutput>Settings.Designer.cs</LastGenOutput>
+    </None>
+    <Compile Include="Properties\Settings.Designer.cs">
+      <AutoGen>True</AutoGen>
+      <DependentUpon>Settings.settings</DependentUpon>
+      <DesignTimeSharedInput>True</DesignTimeSharedInput>
+    </Compile>
+    <Compile Include="ThisAddIn.cs">
+      <SubType>Code</SubType>
+    </Compile>
+    <None Include="ThisAddIn.Designer.xml">
+      <DependentUpon>ThisAddIn.cs</DependentUpon>
+    </None>
+    <Compile Include="ThisAddIn.Designer.cs">
+      <DependentUpon>ThisAddIn.Designer.xml</DependentUpon>
+    </Compile>
+    <AppDesigner Include="Properties\" />
+  </ItemGroup>
+  <!-- Include the build rules for a C# project. -->
+  <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
+  <!-- Include additional build rules for an Office application add-in. -->
+  <Import Project="$(MSBuildExtensionsPath)\Microsoft\VisualStudio\v9.0\OfficeTools\Microsoft.VisualStudio.Tools.Office.Office2007.targets" />
+  <!-- This section defines VSTO properties that describe the host-changeable project properties. -->
+  <ProjectExtensions>
+    <VisualStudio>
+      <FlavorProperties GUID="{BAA0C2D2-18E2-41B9-852F-F413020CAA33}">
+        <ProjectProperties HostName="Excel" HostPackage="{D2B20FF5-A6E5-47E1-90E8-463C6860CB05}" OfficeVersion="12.0" VstxVersion="3.0" ApplicationType="Excel" Language="cs" TemplatesPath="" DebugInfoExeName="#Software\Microsoft\Office\12.0\Excel\InstallRoot\Path#excel.exe" AddItemTemplatesGuid="{147FB6A7-F239-4523-AE65-B6A4E49B361F}" />
+        <Host Name="Excel" GeneratedCodeNamespace="HelpfulHighlighter" IconIndex="0">
+          <HostItem Name="ThisAddIn" Code="ThisAddIn.cs" CanonicalName="AddIn" CanActivate="false" IconIndex="1" Blueprint="ThisAddIn.Designer.xml" GeneratedCode="ThisAddIn.Designer.cs" />
+        </Host>
+        <ProjectClient>
+          <VSTO_CompatibleProducts ErrorProduct="This project requires Microsoft Office Excel 2007 and the registered primary interop assemblies, but these are not installed." ErrorPIA="This project references the primary interop assembly for Microsoft Office Excel 2007, but this primary interop assembly is not installed.">
+            <Product Code="{XX12XXXX-XXXX-XXXX-X000-X000000FF1CE}" Feature="EXCELFiles" PIAFeature="EXCEL_PIA" />
+          </VSTO_CompatibleProducts>
+        </ProjectClient>
+      </FlavorProperties>
+    </VisualStudio>
+  </ProjectExtensions>
+</Project>

+ 20 - 0
HelpfulHighlighter.sln

@@ -0,0 +1,20 @@
+
+Microsoft Visual Studio Solution File, Format Version 10.00
+# Visual Studio 2008
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HelpfulHighlighter", "HelpfulHighlighter.csproj", "{454AA970-3BB8-4DFE-9AC5-4E9A55D4DAF3}"
+EndProject
+Global
+	GlobalSection(SolutionConfigurationPlatforms) = preSolution
+		Debug|Any CPU = Debug|Any CPU
+		Release|Any CPU = Release|Any CPU
+	EndGlobalSection
+	GlobalSection(ProjectConfigurationPlatforms) = postSolution
+		{454AA970-3BB8-4DFE-9AC5-4E9A55D4DAF3}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+		{454AA970-3BB8-4DFE-9AC5-4E9A55D4DAF3}.Debug|Any CPU.Build.0 = Debug|Any CPU
+		{454AA970-3BB8-4DFE-9AC5-4E9A55D4DAF3}.Release|Any CPU.ActiveCfg = Release|Any CPU
+		{454AA970-3BB8-4DFE-9AC5-4E9A55D4DAF3}.Release|Any CPU.Build.0 = Release|Any CPU
+	EndGlobalSection
+	GlobalSection(SolutionProperties) = preSolution
+		HideSolutionNode = FALSE
+	EndGlobalSection
+EndGlobal

+ 111 - 0
HelpfulHighlighterRibbon.Designer.cs

@@ -0,0 +1,111 @@
+namespace HelpfulHighlighter
+{
+	partial class HelpfulHighlighterRibbon
+	{
+		/// <summary>
+		/// Required designer variable.
+		/// </summary>
+		private System.ComponentModel.IContainer components = null;
+
+		/// <summary> 
+		/// Clean up any resources being used.
+		/// </summary>
+		/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
+		protected override void Dispose(bool disposing)
+		{
+			if (disposing && (components != null))
+			{
+				components.Dispose();
+			}
+			base.Dispose(disposing);
+		}
+
+		#region Component Designer generated code
+
+		/// <summary>
+		/// Required method for Designer support - do not modify
+		/// the contents of this method with the code editor.
+		/// </summary>
+		private void InitializeComponent()
+		{
+			this.tab1 = new Microsoft.Office.Tools.Ribbon.RibbonTab();
+			this.grpHelpfulHighlighter = new Microsoft.Office.Tools.Ribbon.RibbonGroup();
+			this.chkEnabled = new Microsoft.Office.Tools.Ribbon.RibbonCheckBox();
+			this.chkPreserve = new Microsoft.Office.Tools.Ribbon.RibbonCheckBox();
+			this.btnColor = new Microsoft.Office.Tools.Ribbon.RibbonButton();
+			this.clrHighlight = new System.Windows.Forms.ColorDialog();
+			this.tab1.SuspendLayout();
+			this.grpHelpfulHighlighter.SuspendLayout();
+			this.SuspendLayout();
+			// 
+			// tab1
+			// 
+			this.tab1.ControlId.ControlIdType = Microsoft.Office.Tools.Ribbon.RibbonControlIdType.Office;
+			this.tab1.Groups.Add(this.grpHelpfulHighlighter);
+			this.tab1.Label = "TabAddIns";
+			this.tab1.Name = "tab1";
+			// 
+			// grpHelpfulHighlighter
+			// 
+			this.grpHelpfulHighlighter.Items.Add(this.chkEnabled);
+			this.grpHelpfulHighlighter.Items.Add(this.chkPreserve);
+			this.grpHelpfulHighlighter.Items.Add(this.btnColor);
+			this.grpHelpfulHighlighter.Label = "Helpful Highlighter";
+			this.grpHelpfulHighlighter.Name = "grpHelpfulHighlighter";
+			// 
+			// chkEnabled
+			// 
+			this.chkEnabled.Checked = true;
+			this.chkEnabled.Label = "Enabled";
+			this.chkEnabled.Name = "chkEnabled";
+			this.chkEnabled.Click += new System.EventHandler<Microsoft.Office.Tools.Ribbon.RibbonControlEventArgs>(this.chkEnabled_Click);
+			// 
+			// chkPreserve
+			// 
+			this.chkPreserve.Checked = true;
+			this.chkPreserve.Label = "Preserve colors";
+			this.chkPreserve.Name = "chkPreserve";
+			this.chkPreserve.Click += new System.EventHandler<Microsoft.Office.Tools.Ribbon.RibbonControlEventArgs>(this.chkPreserve_Click);
+			// 
+			// btnColor
+			// 
+			this.btnColor.Label = "Choose Color";
+			this.btnColor.Name = "btnColor";
+			this.btnColor.Click += new System.EventHandler<Microsoft.Office.Tools.Ribbon.RibbonControlEventArgs>(this.btnColor_Click);
+			// 
+			// clrHighlight
+			// 
+			this.clrHighlight.Color = System.Drawing.Color.FromArgb(((int)(((byte)(0)))), ((int)(((byte)(192)))), ((int)(((byte)(192)))));
+			// 
+			// HelpfulHighlighterRibbon
+			// 
+			this.Name = "HelpfulHighlighterRibbon";
+			this.RibbonType = "Microsoft.Excel.Workbook";
+			this.Tabs.Add(this.tab1);
+			this.Load += new System.EventHandler<Microsoft.Office.Tools.Ribbon.RibbonUIEventArgs>(this.HelpfulHighlighterRibbon_Load);
+			this.tab1.ResumeLayout(false);
+			this.tab1.PerformLayout();
+			this.grpHelpfulHighlighter.ResumeLayout(false);
+			this.grpHelpfulHighlighter.PerformLayout();
+			this.ResumeLayout(false);
+
+		}
+
+		#endregion
+
+		internal Microsoft.Office.Tools.Ribbon.RibbonTab tab1;
+		public Microsoft.Office.Tools.Ribbon.RibbonCheckBox chkEnabled;
+		public Microsoft.Office.Tools.Ribbon.RibbonGroup grpHelpfulHighlighter;
+		internal Microsoft.Office.Tools.Ribbon.RibbonButton btnColor;
+		private System.Windows.Forms.ColorDialog clrHighlight;
+		internal Microsoft.Office.Tools.Ribbon.RibbonCheckBox chkPreserve;
+	}
+
+	partial class ThisRibbonCollection : Microsoft.Office.Tools.Ribbon.RibbonReadOnlyCollection
+	{
+		internal HelpfulHighlighterRibbon HelpfulHighlighterRibbon
+		{
+			get { return this.GetRibbon<HelpfulHighlighterRibbon>(); }
+		}
+	}
+}

+ 91 - 0
HelpfulHighlighterRibbon.cs

@@ -0,0 +1,91 @@
+/***
+ * Project:		Helpful Highlighter Excel Add-In
+ * Component:	Options ribbon menu group
+ * Author:		Todd Boyd
+ * Date:		2010/10/26
+ * Description:
+ * 
+ * The options for Helpful Highlighter are found in the Helpful Highlighter group on the Add-Ins ribbon tab.
+ * Helpful Highlighter saves its options so that they will persist between Excel sessions.
+ * 
+ *		Enable:
+ *			If this unchecked, the Add-In will not highlight/cache anything. When it is unchecked, any current
+ *			highlighting will be removed.
+ *		Preserve color:
+ *			If this is unchecked, the background color of the highlighted cells will not be preserved, and
+ *			will be reset to XlColor.XlNothing when a new area is selected. Even if Preserve Color is unchecked,
+ *			the color buffer will be restored on the next selection change if it is not already empty.
+ *		Choose color:
+ *			Opens a color dialog to allow the user to choose the color that will be used when highlighting
+ *			cells.
+ ***/
+
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using Microsoft.Office.Tools.Ribbon;
+
+namespace HelpfulHighlighter
+{
+	public partial class HelpfulHighlighterRibbon : OfficeRibbon
+	{
+		public HelpfulHighlighter.ThisAddIn addin = null;
+		
+		public HelpfulHighlighterRibbon()
+		{
+			InitializeComponent();
+		}
+
+		// get currently-selected highlighting color		
+		public int GetColor()
+		{
+			return System.Drawing.ColorTranslator.ToOle(clrHighlight.Color);
+		}
+
+		// startup process
+		private void HelpfulHighlighterRibbon_Load(object sender, RibbonUIEventArgs e)
+		{
+			// load settings and affect ribbon
+			clrHighlight.Color = System.Drawing.ColorTranslator.FromOle((int)HelpfulHighlighter.Properties.Settings.Default.color);
+			this.chkPreserve.Checked = (bool)HelpfulHighlighter.Properties.Settings.Default.preserve;
+			this.chkEnabled.Checked = (bool)HelpfulHighlighter.Properties.Settings.Default.enabled;
+		}
+		
+		private void chkEnabled_Click(object sender, RibbonControlEventArgs e)
+		{
+			// set value and clear highlighting
+			if(! this.chkEnabled.Checked)
+			{
+				HelpfulHighlighter.Properties.Settings.Default.enabled = false;
+				this.addin.CleanUp();
+			}
+			// set value
+			else
+				HelpfulHighlighter.Properties.Settings.Default.enabled = true;
+
+			HelpfulHighlighter.Properties.Settings.Default.Save();
+		}
+
+		private void btnColor_Click(object sender, RibbonControlEventArgs e)
+		{
+			// use color dialog to determine selection
+			System.Windows.Forms.DialogResult result = clrHighlight.ShowDialog();
+			if(result != System.Windows.Forms.DialogResult.OK)
+				return;
+			// set value
+			HelpfulHighlighter.Properties.Settings.Default.color = System.Drawing.ColorTranslator.ToOle(clrHighlight.Color);
+			HelpfulHighlighter.Properties.Settings.Default.Save();
+		}
+
+		private void chkPreserve_Click(object sender, RibbonControlEventArgs e)
+		{
+			// clear highlighting if preserve disabled
+			if (! this.chkPreserve.Checked)
+				this.addin.CleanUp();
+			// set value
+			HelpfulHighlighter.Properties.Settings.Default.preserve = this.chkPreserve.Checked;			
+			HelpfulHighlighter.Properties.Settings.Default.Save();
+		}
+	}
+}

+ 123 - 0
HelpfulHighlighterRibbon.resx

@@ -0,0 +1,123 @@
+<?xml version="1.0" encoding="utf-8"?>
+<root>
+  <!-- 
+    Microsoft ResX Schema 
+    
+    Version 2.0
+    
+    The primary goals of this format is to allow a simple XML format 
+    that is mostly human readable. The generation and parsing of the 
+    various data types are done through the TypeConverter classes 
+    associated with the data types.
+    
+    Example:
+    
+    ... ado.net/XML headers & schema ...
+    <resheader name="resmimetype">text/microsoft-resx</resheader>
+    <resheader name="version">2.0</resheader>
+    <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
+    <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+    <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
+    <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
+    <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
+        <value>[base64 mime encoded serialized .NET Framework object]</value>
+    </data>
+    <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+        <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
+        <comment>This is a comment</comment>
+    </data>
+                
+    There are any number of "resheader" rows that contain simple 
+    name/value pairs.
+    
+    Each data row contains a name, and value. The row also contains a 
+    type or mimetype. Type corresponds to a .NET class that support 
+    text/value conversion through the TypeConverter architecture. 
+    Classes that don't support this are serialized and stored with the 
+    mimetype set.
+    
+    The mimetype is used for serialized objects, and tells the 
+    ResXResourceReader how to depersist the object. This is currently not 
+    extensible. For a given mimetype the value must be set accordingly:
+    
+    Note - application/x-microsoft.net.object.binary.base64 is the format 
+    that the ResXResourceWriter will generate, however the reader can 
+    read any of the formats listed below.
+    
+    mimetype: application/x-microsoft.net.object.binary.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
+            : and then encoded with base64 encoding.
+    
+    mimetype: application/x-microsoft.net.object.soap.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
+            : and then encoded with base64 encoding.
+
+    mimetype: application/x-microsoft.net.object.bytearray.base64
+    value   : The object must be serialized into a byte array 
+            : using a System.ComponentModel.TypeConverter
+            : and then encoded with base64 encoding.
+    -->
+  <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
+    <xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
+    <xsd:element name="root" msdata:IsDataSet="true">
+      <xsd:complexType>
+        <xsd:choice maxOccurs="unbounded">
+          <xsd:element name="metadata">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" />
+              </xsd:sequence>
+              <xsd:attribute name="name" use="required" type="xsd:string" />
+              <xsd:attribute name="type" type="xsd:string" />
+              <xsd:attribute name="mimetype" type="xsd:string" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="assembly">
+            <xsd:complexType>
+              <xsd:attribute name="alias" type="xsd:string" />
+              <xsd:attribute name="name" type="xsd:string" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="data">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+                <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
+              <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
+              <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
+              <xsd:attribute ref="xml:space" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="resheader">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" />
+            </xsd:complexType>
+          </xsd:element>
+        </xsd:choice>
+      </xsd:complexType>
+    </xsd:element>
+  </xsd:schema>
+  <resheader name="resmimetype">
+    <value>text/microsoft-resx</value>
+  </resheader>
+  <resheader name="version">
+    <value>2.0</value>
+  </resheader>
+  <resheader name="reader">
+    <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+  <resheader name="writer">
+    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+  <metadata name="clrHighlight.TrayLocation" type="System.Drawing.Point, System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
+    <value>17, 17</value>
+  </metadata>
+</root>

+ 51 - 0
Properties/AssemblyInfo.cs

@@ -0,0 +1,51 @@
+using System.Reflection;
+using System.Runtime.CompilerServices;
+using System.Runtime.InteropServices;
+using System.Security;
+using Microsoft.Office.Tools.Excel;
+
+// General Information about an assembly is controlled through the following 
+// set of attributes. Change these attribute values to modify the information
+// associated with an assembly.
+[assembly: AssemblyTitle("Helpful Highlighter")]
+[assembly: AssemblyDescription("VSTO Excel Add-In for highlighting the current row and column")]
+[assembly: AssemblyConfiguration("")]
+[assembly: AssemblyCompany("")]
+[assembly: AssemblyProduct("Helpful Highlighter")]
+[assembly: AssemblyCopyright("Todd Boyd")]
+[assembly: AssemblyTrademark("")]
+[assembly: AssemblyCulture("")]
+
+// Setting ComVisible to false makes the types in this assembly not visible 
+// to COM components.  If you need to access a type in this assembly from 
+// COM, set the ComVisible attribute to true on that type.
+[assembly: ComVisible(false)]
+
+// The following GUID is for the ID of the typelib if this project is exposed to COM
+[assembly: Guid("5cd40cc9-f498-43cc-979b-05269fdd2776")]
+
+// Version information for an assembly consists of the following four values:
+//
+//      Major Version
+//      Minor Version 
+//      Build Number
+//      Revision
+//
+// You can specify all the values or you can default the Build and Revision Numbers 
+// by using the '*' as shown below:
+// [assembly: AssemblyVersion("1.0.*")]
+[assembly: AssemblyVersion("1.0.0.0")]
+[assembly: AssemblyFileVersion("1.0.0.0")]
+
+// 
+// The ExcelLocale1033 attribute controls the locale that is passed to the Excel
+// object model. Setting ExcelLocale1033 to true causes the Excel object model to 
+// act the same in all locales, which matches the behavior of Visual Basic for 
+// Applications. Setting ExcelLocale1033 to false causes the Excel object model to
+// act differently when users have different locale settings, which matches the 
+// behavior of Visual Studio Tools for Office, Version 2003. This can cause unexpected 
+// results in locale-sensitive information such as formula names and date formats.
+// 
+[assembly: ExcelLocale1033(true)]
+
+[assembly: SecurityTransparent()]

+ 62 - 0
Properties/Resources.Designer.cs

@@ -0,0 +1,62 @@
+//------------------------------------------------------------------------------
+// <auto-generated>
+//     This code was generated by a tool.
+//     Runtime Version:2.0.50727.5448
+//
+//     Changes to this file may cause incorrect behavior and will be lost if
+//     the code is regenerated.
+// </auto-generated>
+//------------------------------------------------------------------------------
+
+namespace HelpfulHighlighter.Properties {
+    
+    
+    /// <summary>
+    ///   A strongly-typed resource class, for looking up localized strings, etc.
+    /// </summary>
+    // This class was auto-generated by the StronglyTypedResourceBuilder
+    // class via a tool like ResGen or Visual Studio.
+    // To add or remove a member, edit your .ResX file then rerun ResGen
+    // with the /str option, or rebuild your VS project.
+    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "2.0.0.0")]
+    [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+    [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
+    internal class Resources {
+        
+        private static global::System.Resources.ResourceManager resourceMan;
+        
+        private static global::System.Globalization.CultureInfo resourceCulture;
+        
+        [global::System.Diagnostics.CodeAnalysis.SuppressMessageAttribute("Microsoft.Performance", "CA1811:AvoidUncalledPrivateCode")]
+        internal Resources() {
+        }
+        
+        /// <summary>
+        ///   Returns the cached ResourceManager instance used by this class.
+        /// </summary>
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+        internal static global::System.Resources.ResourceManager ResourceManager {
+            get {
+                if (object.ReferenceEquals(resourceMan, null)) {
+                    global::System.Resources.ResourceManager temp = new global::System.Resources.ResourceManager("HelpfulHighlighter.Properties.Resources", typeof(Resources).Assembly);
+                    resourceMan = temp;
+                }
+                return resourceMan;
+            }
+        }
+        
+        /// <summary>
+        ///   Overrides the current thread's CurrentUICulture property for all
+        ///   resource lookups using this strongly typed resource class.
+        /// </summary>
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+        internal static global::System.Globalization.CultureInfo Culture {
+            get {
+                return resourceCulture;
+            }
+            set {
+                resourceCulture = value;
+            }
+        }
+    }
+}

+ 117 - 0
Properties/Resources.resx

@@ -0,0 +1,117 @@
+<?xml version="1.0" encoding="utf-8"?>
+<root>
+  <!-- 
+    Microsoft ResX Schema 
+    
+    Version 2.0
+    
+    The primary goals of this format is to allow a simple XML format 
+    that is mostly human readable. The generation and parsing of the 
+    various data types are done through the TypeConverter classes 
+    associated with the data types.
+    
+    Example:
+    
+    ... ado.net/XML headers & schema ...
+    <resheader name="resmimetype">text/microsoft-resx</resheader>
+    <resheader name="version">2.0</resheader>
+    <resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
+    <resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
+    <data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
+    <data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
+    <data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
+        <value>[base64 mime encoded serialized .NET Framework object]</value>
+    </data>
+    <data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
+        <value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
+        <comment>This is a comment</comment>
+    </data>
+                
+    There are any number of "resheader" rows that contain simple 
+    name/value pairs.
+    
+    Each data row contains a name, and value. The row also contains a 
+    type or mimetype. Type corresponds to a .NET class that support 
+    text/value conversion through the TypeConverter architecture. 
+    Classes that don't support this are serialized and stored with the 
+    mimetype set.
+    
+    The mimetype is used for serialized objects, and tells the 
+    ResXResourceReader how to depersist the object. This is currently not 
+    extensible. For a given mimetype the value must be set accordingly:
+    
+    Note - application/x-microsoft.net.object.binary.base64 is the format 
+    that the ResXResourceWriter will generate, however the reader can 
+    read any of the formats listed below.
+    
+    mimetype: application/x-microsoft.net.object.binary.base64
+    value   : The object must be serialized with 
+            : System.Serialization.Formatters.Binary.BinaryFormatter
+            : and then encoded with base64 encoding.
+    
+    mimetype: application/x-microsoft.net.object.soap.base64
+    value   : The object must be serialized with 
+            : System.Runtime.Serialization.Formatters.Soap.SoapFormatter
+            : and then encoded with base64 encoding.
+
+    mimetype: application/x-microsoft.net.object.bytearray.base64
+    value   : The object must be serialized into a byte array 
+            : using a System.ComponentModel.TypeConverter
+            : and then encoded with base64 encoding.
+    -->
+  <xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
+    <xsd:element name="root" msdata:IsDataSet="true">
+      <xsd:complexType>
+        <xsd:choice maxOccurs="unbounded">
+          <xsd:element name="metadata">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" />
+              <xsd:attribute name="type" type="xsd:string" />
+              <xsd:attribute name="mimetype" type="xsd:string" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="assembly">
+            <xsd:complexType>
+              <xsd:attribute name="alias" type="xsd:string" />
+              <xsd:attribute name="name" type="xsd:string" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="data">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+                <xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" msdata:Ordinal="1" />
+              <xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
+              <xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
+            </xsd:complexType>
+          </xsd:element>
+          <xsd:element name="resheader">
+            <xsd:complexType>
+              <xsd:sequence>
+                <xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
+              </xsd:sequence>
+              <xsd:attribute name="name" type="xsd:string" use="required" />
+            </xsd:complexType>
+          </xsd:element>
+        </xsd:choice>
+      </xsd:complexType>
+    </xsd:element>
+  </xsd:schema>
+  <resheader name="resmimetype">
+    <value>text/microsoft-resx</value>
+  </resheader>
+  <resheader name="version">
+    <value>2.0</value>
+  </resheader>
+  <resheader name="reader">
+    <value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+  <resheader name="writer">
+    <value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
+  </resheader>
+</root>

+ 62 - 0
Properties/Settings.Designer.cs

@@ -0,0 +1,62 @@
+//------------------------------------------------------------------------------
+// <auto-generated>
+//     This code was generated by a tool.
+//     Runtime Version:2.0.50727.5448
+//
+//     Changes to this file may cause incorrect behavior and will be lost if
+//     the code is regenerated.
+// </auto-generated>
+//------------------------------------------------------------------------------
+
+namespace HelpfulHighlighter.Properties {
+    
+    
+    [global::System.Runtime.CompilerServices.CompilerGeneratedAttribute()]
+    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "9.0.0.0")]
+    internal sealed partial class Settings : global::System.Configuration.ApplicationSettingsBase {
+        
+        private static Settings defaultInstance = ((Settings)(global::System.Configuration.ApplicationSettingsBase.Synchronized(new Settings())));
+        
+        public static Settings Default {
+            get {
+                return defaultInstance;
+            }
+        }
+        
+        [global::System.Configuration.UserScopedSettingAttribute()]
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.Configuration.DefaultSettingValueAttribute("True")]
+        public bool enabled {
+            get {
+                return ((bool)(this["enabled"]));
+            }
+            set {
+                this["enabled"] = value;
+            }
+        }
+        
+        [global::System.Configuration.UserScopedSettingAttribute()]
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.Configuration.DefaultSettingValueAttribute("65408")]
+        public int color {
+            get {
+                return ((int)(this["color"]));
+            }
+            set {
+                this["color"] = value;
+            }
+        }
+        
+        [global::System.Configuration.UserScopedSettingAttribute()]
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.Configuration.DefaultSettingValueAttribute("True")]
+        public bool preserve {
+            get {
+                return ((bool)(this["preserve"]));
+            }
+            set {
+                this["preserve"] = value;
+            }
+        }
+    }
+}

+ 15 - 0
Properties/Settings.settings

@@ -0,0 +1,15 @@
+<?xml version='1.0' encoding='utf-8'?>
+<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)" GeneratedClassNamespace="HelpfulHighlighter.Properties" GeneratedClassName="Settings">
+  <Profiles />
+  <Settings>
+    <Setting Name="enabled" Type="System.Boolean" Scope="User">
+      <Value Profile="(Default)">True</Value>
+    </Setting>
+    <Setting Name="color" Type="System.Int32" Scope="User">
+      <Value Profile="(Default)">65408</Value>
+    </Setting>
+    <Setting Name="preserve" Type="System.Boolean" Scope="User">
+      <Value Profile="(Default)">True</Value>
+    </Setting>
+  </Settings>
+</SettingsFile>

+ 3 - 3
README.md

@@ -1,4 +1,4 @@
-helpful-highlighter
-===================
+Helpful Highlighter
+===
 
-Adaptive Excel 2007/2010 AddIn for visually/mentally imparied users that will highlight the current row and column
+Adaptive Excel 2007/2010 AddIn for visually/mentally imparied users that will highlight the current row and column

+ 220 - 0
ThisAddIn.Designer.cs

@@ -0,0 +1,220 @@
+//------------------------------------------------------------------------------
+// <auto-generated>
+//     This code was generated by a tool.
+//     Runtime Version:2.0.50727.5448
+//
+//     Changes to this file may cause incorrect behavior and will be lost if
+//     the code is regenerated.
+// </auto-generated>
+//------------------------------------------------------------------------------
+
+#pragma warning disable 414
+namespace HelpfulHighlighter {
+    
+    
+    /// 
+    [Microsoft.VisualStudio.Tools.Applications.Runtime.StartupObjectAttribute(0)]
+    [global::System.Security.Permissions.PermissionSetAttribute(global::System.Security.Permissions.SecurityAction.Demand, Name="FullTrust")]
+    public sealed partial class ThisAddIn : Microsoft.Office.Tools.AddIn, Microsoft.VisualStudio.Tools.Office.IOfficeEntryPoint {
+        
+        internal Microsoft.Office.Tools.CustomTaskPaneCollection CustomTaskPanes;
+        
+        internal Microsoft.Office.Tools.SmartTagCollection VstoSmartTags;
+
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        private global::System.Object missing = global::System.Type.Missing;
+        
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        internal Microsoft.Office.Interop.Excel.Application Application;
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Never)]
+        public ThisAddIn() : 
+                base("AddIn", "ThisAddIn") {
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Never)]
+        protected override void Initialize() {
+            base.Initialize();
+            this.Application = this.GetHostItem<Microsoft.Office.Interop.Excel.Application>(typeof(Microsoft.Office.Interop.Excel.Application), "Application");
+            Globals.ThisAddIn = this;
+            global::System.Windows.Forms.Application.EnableVisualStyles();
+            this.InitializeCachedData();
+            this.InitializeControls();
+            this.InitializeComponents();
+            this.InitializeData();
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Never)]
+        protected override void FinishInitialization() {
+            this.InternalStartup();
+            this.OnStartup();
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Never)]
+        protected override void InitializeDataBindings() {
+            this.BeginInitialization();
+            this.BindToData();
+            this.EndInitialization();
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Never)]
+        private void InitializeCachedData() {
+            if ((this.DataHost == null)) {
+                return;
+            }
+            if (this.DataHost.IsCacheInitialized) {
+                this.DataHost.FillCachedData(this);
+            }
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Never)]
+        private void InitializeData() {
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Never)]
+        private void BindToData() {
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+        private void StartCaching(string MemberName) {
+            this.DataHost.StartCaching(this, MemberName);
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+        private void StopCaching(string MemberName) {
+            this.DataHost.StopCaching(this, MemberName);
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+        private bool IsCached(string MemberName) {
+            return this.DataHost.IsCached(this, MemberName);
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Never)]
+        private void BeginInitialization() {
+            this.BeginInit();
+            this.CustomTaskPanes.BeginInit();
+            this.VstoSmartTags.BeginInit();
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Never)]
+        private void EndInitialization() {
+            this.VstoSmartTags.EndInit();
+            this.CustomTaskPanes.EndInit();
+            this.EndInit();
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Never)]
+        private void InitializeControls() {
+            this.CustomTaskPanes = new Microsoft.Office.Tools.CustomTaskPaneCollection(this.ItemProvider, this.HostContext, "CustomTaskPanes", this, "CustomTaskPanes");
+            this.VstoSmartTags = new Microsoft.Office.Tools.SmartTagCollection(this.ItemProvider, this.HostContext, "VstoSmartTags", this, "VstoSmartTags");
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Never)]
+        private void InitializeComponents() {
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Advanced)]
+        private bool NeedsFill(string MemberName) {
+            return this.DataHost.NeedsFill(this, MemberName);
+        }
+        
+        /// 
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+        [global::System.ComponentModel.EditorBrowsableAttribute(global::System.ComponentModel.EditorBrowsableState.Never)]
+        protected override void OnShutdown() {
+            this.VstoSmartTags.Dispose();
+            this.CustomTaskPanes.Dispose();
+            base.OnShutdown();
+        }
+    }
+    
+    /// 
+    [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+    internal sealed partial class Globals {
+        
+        /// 
+        private Globals()
+        {
+        }
+
+        private static ThisAddIn _ThisAddIn;
+
+        private static ThisRibbonCollection _ThisRibbonCollection;
+        
+        internal static ThisAddIn ThisAddIn {
+            get {
+                return _ThisAddIn;
+            }
+            set {
+                if ((_ThisAddIn == null)) {
+                    _ThisAddIn = value;
+                }
+                else {
+                    throw new System.NotSupportedException();
+                }
+            }
+        }
+        
+        internal static ThisRibbonCollection Ribbons {
+            get {
+                if ((_ThisRibbonCollection == null)) {
+                    _ThisRibbonCollection = new ThisRibbonCollection();
+                }
+                return _ThisRibbonCollection;
+            }
+        }
+    }
+    
+    /// 
+    [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+    [global::System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "9.0.0.0")]
+    internal sealed partial class ThisRibbonCollection : Microsoft.Office.Tools.Ribbon.RibbonReadOnlyCollection {
+    }
+}

+ 5 - 0
ThisAddIn.Designer.xml

@@ -0,0 +1,5 @@
+<hostitem:hostItem hostitem:baseType="Microsoft.Office.Tools.AddIn" hostitem:interfaceType="Microsoft.VisualStudio.Tools.Office.IOfficeEntryPoint" hostitem:namespace="HelpfulHighlighter" hostitem:className="ThisAddIn" hostitem:identifier="ThisAddIn" hostitem:primaryCookie="AddIn" hostitem:master="true" hostitem:startupIndex="0" xmlns:hostitem="http://schemas.microsoft.com/2004/VisualStudio/Tools/Applications/HostItem.xsd">
+  <hostitem:hostObject hostitem:name="Application" hostitem:identifier="Application" hostitem:type="Microsoft.Office.Interop.Excel.Application" hostitem:cookie="Application" hostitem:modifier="Internal" />
+  <hostitem:hostControl hostitem:name="CustomTaskPanes" hostitem:identifier="CustomTaskPanes" hostitem:type="Microsoft.Office.Tools.CustomTaskPaneCollection" hostitem:primaryCookie="CustomTaskPanes" hostitem:modifier="Internal" />
+  <hostitem:hostControl hostitem:name="VstoSmartTags" hostitem:identifier="VstoSmartTags" hostitem:type="Microsoft.Office.Tools.SmartTagCollection" hostitem:primaryCookie="VstoSmartTags" hostitem:modifier="Internal" />
+</hostitem:hostItem>

+ 219 - 0
ThisAddIn.cs

@@ -0,0 +1,219 @@
+/***
+ * Project:		Helpful Highlighter Excel Add-In
+ * Component:	Core Add-In class
+ * Author:		Todd Boyd
+ * Date:		2010/10/26
+ * Description:
+ * 
+ * This Excel Add-In highlights the current row and column (but not the currently selected area) to assist
+ * users with cognitive and/or visual impairments in maintaining focus through the use of visual cues. The
+ * background color of the cells is actually changed on-the-fly in order to facilitate this functionality.
+ * 
+ * The highlighting will be removed prior to printing or saving the worksheet in order to prevent the Add-In
+ * interfering with the spreadsheets it is highlighting for the user.
+ ***/
+ 
+using System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Text;
+using System.Xml.Linq;
+using Excel = Microsoft.Office.Interop.Excel;
+using Office = Microsoft.Office.Core;
+using Microsoft.Office.Tools.Excel;
+using Microsoft.Office.Tools.Excel.Extensions;
+using Microsoft.Office.Interop.Excel;
+using System.Collections;
+
+namespace HelpfulHighlighter
+{
+    public partial class ThisAddIn
+    {
+		private Range hlRange = null; // row and column ranges for highlighting
+		private HelpfulHighlighterRibbon ribbon = null; // ribbon object (options)
+		private List<object[]> old = null;
+		private Microsoft.Office.Interop.Excel.Worksheet oldSheet = null;
+		
+		// startup process
+        private void ThisAddIn_Startup(object sender, System.EventArgs e)
+        {
+			// intialize
+			{
+				// cache for color and colorindex properties
+				this.old = new List<object[]>();
+			}
+			
+			// bind events
+			{
+				// selection changed
+				this.Application.SheetSelectionChange += new AppEvents_SheetSelectionChangeEventHandler(this.Sheet_Selection_Changed);
+				// before save
+				this.Application.WorkbookBeforeSave += new AppEvents_WorkbookBeforeSaveEventHandler(this.Workbook_Before_Save);
+				// before print
+				this.Application.WorkbookBeforePrint += new AppEvents_WorkbookBeforePrintEventHandler(this.Workbook_Before_Print);
+			}
+		}
+
+		// shutdown process
+        private void ThisAddIn_Shutdown(object sender, System.EventArgs e) { /* nothing to do */ }
+        
+        // remove highlighting
+        public void CleanUp(params object[] p)
+        {
+			// pull parameter
+			bool closeBuffer = true;
+			if(p.Count() > 0)
+				closeBuffer = (bool)p[0];
+			// nothing to do?
+			if(this.hlRange == null)
+				return;
+			// buffer on
+			this.Application.ScreenUpdating = false;
+			XlCalculation calc = this.Application.Calculation;
+			this.Application.Calculation = XlCalculation.xlCalculationManual;
+			
+			// only restore colors if preserve is set and there are colors to restore in the first place
+			if(this.old.Count > 0)
+			{
+				// cycle through "remembered" colors
+				IEnumerator enu = this.old.GetEnumerator();
+			
+				while(enu.MoveNext())
+				{
+					object[] curr = (object[])enu.Current;
+					Interior intr;
+					// get old sheet's interior
+					if (this.oldSheet != null)
+						intr = ((Range)oldSheet.Cells[curr[0], curr[1]]).Interior;
+					// get current sheet's interior
+					else
+						intr = ((Range)this.Application.Cells[curr[0], curr[1]]).Interior;
+					// restore colors					
+					intr.Color = curr[2];
+					intr.ColorIndex = curr[3];
+				}
+			
+				this.old.Clear();
+			}
+			// set colors to "nothing" -- preserve is disabled
+			else if(this.hlRange != null)
+				this.hlRange.Interior.ColorIndex = XlColorIndex.xlColorIndexNone;
+				
+			// buffer off
+			if(closeBuffer)
+				this.Application.ScreenUpdating = true;
+			this.Application.Calculation = calc;
+		}
+        
+        // highlight selection's entire row/column (excluding selected area)
+        private void HighLight()
+        {
+			// nothing to do?
+			if(this.hlRange == null)
+				return;
+			// buffer on
+			this.Application.ScreenUpdating = false;
+			XlCalculation calc = this.Application.Calculation;
+			this.Application.Calculation = XlCalculation.xlCalculationManual;
+			Range sel = (Range)this.Application.Selection;
+			
+			// preserve colors?
+			if(HelpfulHighlighter.Properties.Settings.Default.preserve)
+			{
+				// iterate through highlight range and save color/colorindex to cache
+				IEnumerator enu = this.hlRange.GetEnumerator();
+				
+				while(enu.MoveNext())
+				{
+					Range curr = (Range)enu.Current;
+					this.old.Add(new object[] { curr.Row, curr.Column, curr.Interior.Color, curr.Interior.ColorIndex });
+				}
+			}
+			
+			// highlight row and column ranges
+			this.hlRange.Interior.Color = this.ribbon.GetColor();
+			// buffer off
+			this.Application.ScreenUpdating = true;
+			this.Application.Calculation = calc;
+			// remember last sheet highlighted
+			this.oldSheet = (Microsoft.Office.Interop.Excel.Worksheet)this.Application.ActiveSheet;
+		}
+        
+        // selection changed; re-highlight
+		private void Sheet_Selection_Changed(object sh, Range target)
+        {
+			// do nothing if addin disabled
+			if (! HelpfulHighlighter.Properties.Settings.Default.enabled)
+				return;
+			// clean up old highlighting, but keep buffer on
+			if(this.hlRange != null)
+				this.CleanUp(new object[] { false });
+			Range sel = (Range)this.Application.Selection;
+			
+			// if we have an entire row, and entire column, or just a ton of cells selected, don't highlight
+			if(sel.Rows.Cells.Count > this.Application.ActiveWindow.VisibleRange.Rows.Cells.Count
+				|| sel.Columns.Cells.Count > this.Application.ActiveWindow.VisibleRange.Columns.Cells.Count)
+			{
+				this.Application.ScreenUpdating = true;
+				return;
+			}
+			
+			// get cell ranges for areas to highlight
+			Range colsAhead = this.Application.get_Range(this.Application.Cells[target.Row, sel.Column + sel.Columns.Count], this.Application.Cells[target.Row, target.Application.ActiveWindow.VisibleRange.Column + target.Application.ActiveWindow.VisibleRange.Columns.Count]);
+			// substitute first cell to the right of selection if on column 1
+			Range colsBehind = (
+				sel.Column <= 1
+					? (Range)this.Application.Cells[sel.Row, sel.Column + sel.Columns.Count]
+					: this.Application.get_Range(this.Application.Cells[target.Row, 1], this.Application.Cells[target.Row, sel.Column - 1]));
+			Range rowsBelow = this.Application.get_Range(this.Application.Cells[sel.Row + sel.Rows.Count, target.Column], this.Application.Cells[target.Application.ActiveWindow.VisibleRange.Row + target.Application.ActiveWindow.VisibleRange.Rows.Count, target.Column]);
+			// substitute first cell above selection if on row 1
+			Range rowsAbove = (
+				sel.Row <= 1
+					? (Range)this.Application.Cells[sel.Row + sel.Rows.Count, sel.Column]
+					: this.Application.get_Range(this.Application.Cells[1, target.Column], this.Application.Cells[sel.Row - 1, target.Column]));
+			
+			this.hlRange = this.Application.Union(rowsAbove, rowsBelow, colsBehind, colsAhead,
+				missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing, missing);
+			// highlight row/column
+			this.HighLight();
+        }
+
+		// clear highlighting before save
+		private void Workbook_Before_Save(Microsoft.Office.Interop.Excel.Workbook wb, bool SaveAsUI, ref bool Cancel)
+        {
+			this.CleanUp();
+		}
+
+		// clear highlighting before print
+		private void Workbook_Before_Print(Microsoft.Office.Interop.Excel.Workbook wb, ref bool Cancel)
+		{
+			this.CleanUp();
+		}
+
+		// load ribbon
+		protected override Microsoft.Office.Tools.Ribbon.OfficeRibbon[] CreateRibbonObjects()
+		{
+			if (this.ribbon == null)
+			{
+				this.ribbon = new HelpfulHighlighterRibbon();
+				this.ribbon.addin = this;
+			}
+
+			return new Microsoft.Office.Tools.Ribbon.OfficeRibbon[] { this.ribbon };
+		}
+
+		#region VSTO generated code
+
+        /// <summary>
+        /// Required method for Designer support - do not modify
+        /// the contents of this method with the code editor.
+        /// </summary>
+        private void InternalStartup()
+        {
+            this.Startup += new System.EventHandler(ThisAddIn_Startup);
+            this.Shutdown += new System.EventHandler(ThisAddIn_Shutdown);
+        }
+        
+        #endregion
+    }
+}

+ 21 - 0
app.config

@@ -0,0 +1,21 @@
+<?xml version="1.0" encoding="utf-8" ?>
+<configuration>
+    <configSections>
+        <sectionGroup name="userSettings" type="System.Configuration.UserSettingsGroup, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" >
+            <section name="HelpfulHighlighter.Properties.Settings" type="System.Configuration.ClientSettingsSection, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" allowExeDefinition="MachineToLocalUser" requirePermission="false" />
+        </sectionGroup>
+    </configSections>
+    <userSettings>
+        <HelpfulHighlighter.Properties.Settings>
+            <setting name="enabled" serializeAs="String">
+                <value>True</value>
+            </setting>
+            <setting name="color" serializeAs="String">
+                <value>65408</value>
+            </setting>
+            <setting name="preserve" serializeAs="String">
+                <value>True</value>
+            </setting>
+        </HelpfulHighlighter.Properties.Settings>
+    </userSettings>
+</configuration>