This commit is contained in:
2023-01-05 16:32:28 +00:00
parent 9f6e3c7407
commit d3c015d382
163 changed files with 0 additions and 0 deletions

View File

@@ -0,0 +1,25 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio Version 16
VisualStudioVersion = 16.0.31112.23
MinimumVisualStudioVersion = 10.0.40219.1
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "W2PAddIn", "W2PAddIn\W2PAddIn.vbproj", "{8116F31D-7220-4519-8648-93546FA7259C}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{8116F31D-7220-4519-8648-93546FA7259C}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{8116F31D-7220-4519-8648-93546FA7259C}.Debug|Any CPU.Build.0 = Debug|Any CPU
{8116F31D-7220-4519-8648-93546FA7259C}.Release|Any CPU.ActiveCfg = Release|Any CPU
{8116F31D-7220-4519-8648-93546FA7259C}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {387B559D-1A71-41FD-B380-D16FD3A5DB6B}
EndGlobalSection
EndGlobal

View File

@@ -0,0 +1,392 @@
Option Explicit On
Module Cmt
'Private App As Word.Application
Public Function AddColor(sType As String) As Boolean
'Highlight the current selection in a manner which identifies what the selection is
Dim bReturn As Boolean
bReturn = True 'default return value
With App.Selection.Range
App.Selection.Font.Color = Word.WdColor.wdColorBlack
If UCase(sType) Like "STEP*" Then
.HighlightColorIndex = Word.WdColorIndex.wdBrightGreen
ElseIf UCase(sType) Like "NOTES*" Then
.HighlightColorIndex = Word.WdColorIndex.wdAuto
ElseIf UCase(sType) Like "NOTE*" Then
.HighlightColorIndex = Word.WdColorIndex.wdBrightGreen
ElseIf UCase(sType) Like "CAUTIONS*" Then
.HighlightColorIndex = Word.WdColorIndex.wdAuto
ElseIf UCase(sType) Like "CAUTION*" Then
.HighlightColorIndex = Word.WdColorIndex.wdBrightGreen
ElseIf UCase(sType) Like "IGNORE" Then
.HighlightColorIndex = Word.WdColorIndex.wdGray50
ElseIf UCase(sType) Like "SECTION*" Then
.HighlightColorIndex = Word.WdColorIndex.wdRed
ElseIf UCase(sType) Like "FIGURE*" Then
.HighlightColorIndex = Word.WdColorIndex.wdYellow
ElseIf UCase(sType) Like "EQUATION*" Then
.HighlightColorIndex = Word.WdColorIndex.wdYellow
ElseIf UCase(sType) Like "TABLE*" Then
.HighlightColorIndex = Word.WdColorIndex.wdYellow
Else
'don't know what this is so return false
bReturn = False
End If
End With
AddColor = bReturn
End Function
Public Function GetCmtValue(Cmt As Word.Comment, sParam As String) As String
Dim sReturn As String
sReturn = ""
If Not Cmt Is Nothing Then
With Cmt.Range
If UCase(Cmt.Author) Like "STEP*" Then
Select Case LCase(sParam)
Case "level"
sReturn = Right(Cmt.Author, 1)
Case "style"
sReturn = .Paragraphs(2).Range.Text & " " & .Paragraphs(1).Range.Text
Case "checkoff"
sReturn = Replace(.Paragraphs(4).Range.Text, Chr(13), "")
End Select
Else
Select Case UCase(Cmt.Author)
Case "SECTION"
Select Case LCase(sParam)
Case "style"
sReturn = Replace(.Paragraphs(2).Range.Text, Chr(13), "")
Case "type"
sReturn = Replace(.Paragraphs(3).Range.Text, Chr(13), "")
Case "number"
sReturn = Replace(.Paragraphs(4).Range.Text, Chr(13), "")
Case "title"
sReturn = Replace(.Paragraphs(5).Range.Text, Chr(13), "")
Case "id"
sReturn = Replace(.Paragraphs(6).Range.Text, Chr(13), "")
End Select
Case "CAUTION"
Select Case LCase(sParam)
Case "style"
sReturn = .Paragraphs(2).Range.Text & " " & .Paragraphs(1).Range.Text
End Select
Case "NOTE"
Select Case LCase(sParam)
Case "style"
sReturn = .Paragraphs(2).Range.Text & " " & .Paragraphs(1).Range.Text
End Select
Case "TABLE"
Select Case LCase(sParam)
Case "style"
sReturn = .Paragraphs(2).Range.Text & " " & .Paragraphs(1).Range.Text
End Select
Case "FIGURE"
Select Case LCase(sParam)
Case "style"
sReturn = .Paragraphs(2).Range.Text & " " & .Paragraphs(1).Range.Text
End Select
Case "EQUATION"
Select Case LCase(sParam)
Case "style"
sReturn = .Paragraphs(2).Range.Text & " " & .Paragraphs(1).Range.Text
End Select
End Select
End If
End With
End If
GetCmtValue = sReturn
End Function
Public Sub ModifyComment(ByRef Cmt As Word.Comment, ByVal sMsg As String)
Dim rng As Word.Range
Dim sAuthor As String
sAuthor = Cmt.Author
Cmt.Scope.Select()
Cmt.Delete()
With App.Selection
rng = .Range
Cmt = App.ActiveDocument.Comments.Add(Range:= .Range, Text:=sMsg)
Cmt.Author = sAuthor
rng.Select()
End With
End Sub
Public Sub MoveComment(ByVal CmtType As String, ByVal Direction As String)
Dim bMoved As Boolean
Dim sAuthor As String
Dim sMsg As String
Dim sScope As String
Dim Cmt As Word.Comment
Dim rng As Word.Range
Dim lColor As Long
Dim lHighlight As Long
If App.Selection.Comments.Count > 0 Then
Cmt = App.Selection.Comments(1)
sAuthor = Cmt.Author
If InStr(sAuthor, CmtType) > 0 Then
sMsg = Cmt.Range.Text
rng = Cmt.Scope
lColor = rng.Font.Color
lHighlight = rng.HighlightColorIndex
If Not rng.Font.Italic = False Then
'make sure to capture the entire paragraph
sScope = rng.Text
rng.Expand(Unit:=Word.WdUnits.wdParagraph)
'delete original comment
Cmt.Delete()
rng.Delete()
'position range to new location and add paragraph
If LCase(Direction) = "up" Then
rng.Move(Unit:=Word.WdUnits.wdParagraph, Count:=-1)
rng.InsertParagraphBefore()
rng = rng.Paragraphs.First.Range
Else
rng.Move(Unit:=Word.WdUnits.wdParagraph, Count:=1)
rng.InsertParagraphAfter()
rng = rng.Paragraphs.Last.Range
End If
'fill new paraagraph with original comment scope
rng.ParagraphFormat.Style = App.ActiveDocument.Styles("Normal").NameLocal
rng.InsertBefore(sScope)
rng.Font.Italic = True
'attach comment to new paragraph
Cmt = App.ActiveDocument.Comments.Add(Range:=rng, Text:=sMsg)
Cmt.Author = sAuthor
rng.Font.Color = lColor
rng.HighlightColorIndex = lHighlight
rng.Select()
Else
If LCase(Direction) = "up" Then
bMoved = MovePrevious
Else
bMoved = MoveNext
End If
If bMoved = True Then
rng.Font.Color = Word.WdColor.wdColorAutomatic
rng.HighlightColorIndex = Word.WdColorIndex.wdAuto
rng = App.Selection.Range
Cmt.Delete()
Cmt = App.ActiveDocument.Comments.Add(Range:=rng, Text:=sMsg)
Cmt.Author = sAuthor
rng.Font.Color = lColor
rng.HighlightColorIndex = lHighlight
rng.Select()
End If
End If
End If
End If
End Sub
Public Function GetComment(rng As Word.Range) As Word.Range
'returns the content of the first comment
'associated with the range provided
Dim rReturn As Word.Range
Dim r As Word.Range
Dim Cmt As Word.Comment
rReturn = Nothing
If rng.Information(Word.WdInformation.wdInCommentPane) = True Then
rReturn = rng.Comments(1).Range
Else
r = App.ActiveDocument.Range(rng.Start, rng.Start)
For Each Cmt In App.ActiveDocument.Comments
If r.InRange(Cmt.Scope) Then
rReturn = Cmt.Range
Exit For
End If
Next Cmt
End If
GetComment = rReturn
End Function
Public Function GoToComment(Optional LimitToPara As Boolean = True) As Boolean
'move selection to comment associated with current selection
'return true if selection is in comment
Dim rng As Word.Range
Dim bReturn As Boolean
If App.Selection.Information(Word.WdInformation.wdInCommentPane) = False Then
bReturn = False
rng = GetComment(App.Selection.Range)
If Not rng Is Nothing Then
rng.Select()
bReturn = True
End If
Else
bReturn = True
End If
GoToComment = bReturn
End Function
Public Function MoveToNextComment(Optional sAuthor As String = "") As Word.Comment
Dim rng As Word.Range
Dim Cmt As Word.Comment
Dim cReturn As Word.Comment
Dim bSelectCmt As Boolean
Dim I As Integer
cReturn = Nothing
If sAuthor <> "" Then
If App.Selection.Comments.Count > 0 Then
Cmt = App.Selection.Comments(1)
sAuthor = Cmt.Author
End If
End If
If App.Selection.Information(Word.WdInformation.wdInCommentPane) Then
bSelectCmt = True
App.Selection.Comments(1).Scope.Select()
Else
bSelectCmt = False
End If
If App.Selection.End < App.ActiveDocument.Content.End Then
rng = App.ActiveDocument.Range(App.Selection.End, App.ActiveDocument.Content.End)
With rng.Paragraphs
For I = 1 To .Count
If .Item(I).Range.Comments.Count > 0 Then
Cmt = .Item(I).Range.Comments(1)
If (sAuthor = Cmt.Author) Or (sAuthor = "") Then
If bSelectCmt = True Then
Cmt.Range.Select()
Else
Cmt.Scope.Select()
End If
cReturn = Cmt
Exit For
End If
End If
Next I
End With
End If
MoveToNextComment = cReturn
End Function
Public Sub InsertComment(ByVal sAuthor As String, Optional sMsg As String = "")
Dim Cmt As Word.Comment
Dim rng As Word.Range
On Error GoTo Err_InsertComment
RemoveComments()
sAuthor = Trim(sAuthor)
If AddColor(sAuthor) = True Then
With App.Selection
rng = .Range
Cmt = App.ActiveDocument.Comments.Add(Range:= .Range, Text:=sMsg)
Cmt.Author = sAuthor
End With
rng.Select
End If
Bye_InsertComment:
Exit Sub
Err_InsertComment:
Err.Clear()
Resume Bye_InsertComment
End Sub
Public Sub RemoveComments(Optional ByVal AskFirst As Boolean = False, Optional CmtType As String = "")
Dim rng As Word.Range
Dim rStart As Word.Range
Dim rEnd As Word.Range
Dim Cmt As Word.Comment
Dim sMsg As String
Dim I As Integer
If App.Selection.Information(Word.WdInformation.wdInCommentPane) = True Then
Cmt = App.Selection.Comments(1)
If CmtType <> "" Then
If Cmt.Author Like CmtType & "*" Then
Cmt.Scope.Select()
DeleteComment(Cmt)
End If
Else
Cmt.Scope.Select()
DeleteComment(Cmt)
End If
Else
If AskFirst = True Then
If App.Selection.Range.Paragraphs.Count > 1 Then
sMsg = "Do you wish to delete all Comments within the current selection?"
If MsgBox(sMsg, vbYesNo + vbQuestion + vbDefaultButton1, "Remove Comments") = vbYes Then
AskFirst = False
End If
Else
AskFirst = False
End If
End If
If AskFirst = False Then
With App.Selection
rng = .Range
.MoveEndWhile(Cset:=Chr(13), Count:=Word.WdConstants.wdBackward)
If .Information(Word.WdInformation.wdWithInTable) Then
.End = .End - 1
End If
'locate start and end points of the selection
rStart = App.ActiveDocument.Range(.Start, .Start)
rEnd = App.ActiveDocument.Range(.End, .End)
End With
For I = App.ActiveDocument.Comments.Count To 1 Step -1
Cmt = App.ActiveDocument.Comments(I)
If Cmt.Scope.InRange(rng) Or rng.InRange(Cmt.Scope) Or rStart.InRange(Cmt.Scope) Or rEnd.InRange(Cmt.Scope) Then
If CmtType <> "" Then
If Cmt.Author Like CmtType & "*" Then
DeleteComment(Cmt)
End If
Else
DeleteComment(Cmt)
End If
End If
Next I
rng.Select
End If
End If
End Sub
Public Sub DeleteComment(ByRef Cmt As Word.Comment)
Dim rng As Word.Range
Dim I As Integer
rng = Cmt.Scope
Cmt.Delete()
With rng
If Not .Font.Italic = False Then
For I = .Paragraphs.Count To 1 Step -1
.Paragraphs(I).Range.Delete
Next I
Else
For I = .Paragraphs.Count To 1 Step -1
.Paragraphs(I).Range.Font.ColorIndex = Word.WdColorIndex.wdAuto
.Paragraphs(I).Range.HighlightColorIndex = Word.WdColorIndex.wdAuto
Next I
End If
End With
End Sub
End Module

View File

@@ -0,0 +1,45 @@
Imports System
Imports System.Reflection
Imports System.Runtime.InteropServices
Imports System.Security
' 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.
' Review the values of the assembly attributes
<Assembly: AssemblyTitle("W2PAddIn")>
<Assembly: AssemblyDescription("")>
<Assembly: AssemblyCompany("Windows User")>
<Assembly: AssemblyProduct("W2PAddIn")>
<Assembly: AssemblyCopyright("Copyright © Windows User 2021")>
<Assembly: AssemblyTrademark("")>
' 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("ab88852b-8a89-4cb1-ae68-eb17749bc233")>
' 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")>
Friend Module DesignTimeConstants
Public Const RibbonTypeSerializer As String = "Microsoft.VisualStudio.Tools.Office.Ribbon.Serialization.RibbonTypeCodeDomSerializer, Microsoft.VisualStudio.Tools.Office.Designer, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
Public Const RibbonBaseTypeSerializer As String = "System.ComponentModel.Design.Serialization.TypeCodeDomSerializer, System.Design"
Public Const RibbonDesigner As String = "Microsoft.VisualStudio.Tools.Office.Ribbon.Design.RibbonDesigner, Microsoft.VisualStudio.Tools.Office.Designer, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
End Module

View File

@@ -0,0 +1,63 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
' Runtime Version:4.0.30319.42000
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
Imports System
Namespace My.Resources
'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.
'''<summary>
''' A strongly-typed resource class, for looking up localized strings, etc.
'''</summary>
<Global.System.CodeDom.Compiler.GeneratedCodeAttribute("System.Resources.Tools.StronglyTypedResourceBuilder", "4.0.0.0"), _
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute(), _
Global.Microsoft.VisualBasic.HideModuleNameAttribute()> _
Friend Module Resources
Private resourceMan As Global.System.Resources.ResourceManager
Private resourceCulture As Global.System.Globalization.CultureInfo
'''<summary>
''' Returns the cached ResourceManager instance used by this class.
'''</summary>
<Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
Friend ReadOnly Property ResourceManager() As Global.System.Resources.ResourceManager
Get
If Object.ReferenceEquals(resourceMan, Nothing) Then
Dim temp As Global.System.Resources.ResourceManager = New Global.System.Resources.ResourceManager("W2PAddIn.Resources", GetType(Resources).Assembly)
resourceMan = temp
End If
Return resourceMan
End Get
End Property
'''<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)> _
Friend Property Culture() As Global.System.Globalization.CultureInfo
Get
Return resourceCulture
End Get
Set
resourceCulture = value
End Set
End Property
End Module
End Namespace

View File

@@ -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>

View File

@@ -0,0 +1,71 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
' Runtime Version:4.0.30319.42000
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict On
Option Explicit On
<Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Editors.SettingsDesigner.SettingsSingleFileGenerator", "16.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
Partial Friend NotInheritable Class MySettings
Inherits Global.System.Configuration.ApplicationSettingsBase
Private Shared defaultInstance As MySettings = CType(Global.System.Configuration.ApplicationSettingsBase.Synchronized(New MySettings()), MySettings)
#Region "My.Settings Auto-Save Functionality"
#If _MyType = "WindowsForms" Then
Private Shared addedHandler As Boolean
Private Shared addedHandlerLockObject As New Object
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
Private Shared Sub AutoSaveSettings(ByVal sender As Global.System.Object, ByVal e As Global.System.EventArgs)
If My.Application.SaveMySettingsOnExit Then
My.Settings.Save()
End If
End Sub
#End If
#End Region
Public Shared ReadOnly Property [Default]() As MySettings
Get
#If _MyType = "WindowsForms" Then
If Not addedHandler Then
SyncLock addedHandlerLockObject
If Not addedHandler Then
AddHandler My.Application.Shutdown, AddressOf AutoSaveSettings
addedHandler = True
End If
End SyncLock
End If
#End If
Return defaultInstance
End Get
End Property
End Class
Namespace My
<Global.Microsoft.VisualBasic.HideModuleNameAttribute(), _
Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.Runtime.CompilerServices.CompilerGeneratedAttribute()> _
Friend Module MySettingsProperty
<Global.System.ComponentModel.Design.HelpKeywordAttribute("My.Settings")> _
Friend ReadOnly Property Settings() As Global.W2PAddIn.MySettings
Get
Return Global.W2PAddIn.MySettings.Default
End Get
End Property
End Module
End Namespace

View File

@@ -0,0 +1,7 @@
<?xml version='1.0' encoding='utf-8'?>
<SettingsFile xmlns="http://schemas.microsoft.com/VisualStudio/2004/01/settings" CurrentProfile="(Default)" UseMySettingsClassName="true">
<Profiles>
<Profile Name="(Default)" />
</Profiles>
<Settings />
</SettingsFile>

View File

@@ -0,0 +1,941 @@
'TODO: Follow these steps to enable the Ribbon (XML) item:
'1: Copy the following code block into the ThisAddin, ThisWorkbook, or ThisDocument class.
'Protected Overrides Function CreateRibbonExtensibilityObject() As Microsoft.Office.Core.IRibbonExtensibility
' Return New Ribbon1()
'End Function
'2. Create callback methods in the "Ribbon Callbacks" region of this class to handle user
' actions, such as clicking a button. Note: if you have exported this Ribbon from the
' Ribbon designer, move your code from the event handlers to the callback methods and
' modify the code to work with the Ribbon extensibility (RibbonX) programming model.
'3. Assign attributes to the control tags in the Ribbon XML file to identify the appropriate callback methods in your code.
'For more information, see the Ribbon XML documentation in the Visual Studio Tools for Office Help.
Imports Microsoft.Office.Core
Imports Word = Microsoft.Office.Interop.Word
<Runtime.InteropServices.ComVisible(True)>
Public Class Ribbon1
Implements Office.IRibbonExtensibility
Private ribbon As Office.IRibbonUI
'Private App As Word.Application
'Public Path2Setup As String
Private MyFormat As String
Public Sub New()
End Sub
Public Function GetCustomUI(ByVal ribbonID As String) As String Implements Office.IRibbonExtensibility.GetCustomUI
Return GetResourceText("W2PAddIn.Ribbon1.xml")
End Function
#Region "Ribbon Callbacks"
'Create callback methods here. For more information about adding callback methods, visit https://go.microsoft.com/fwlink/?LinkID=271226
Public Sub Ribbon_Load(ByVal ribbonUI As Office.IRibbonUI)
Me.ribbon = ribbonUI
End Sub
Public Sub BtnSearch(ByVal ctl As IRibbonControl)
'perform initial search for document elements
Dim sMsg As String
sMsg = "This action will search for procedure elements and mark them with Comments. This may take some time."
sMsg = sMsg & vbCrLf & "Do you wish to continue?"
If MsgBox(sMsg, vbOKCancel + vbQuestion + vbDefaultButton1, "Search For Procedure Elements") = vbOK Then
'FindItems
PreSearchCleanup
FindShapes
FindSteps
FindStuff
'FindShapes
'FindSections
App.ActiveDocument.Paragraphs(1).Range.Select()
App.StatusBar = "Seach - Done"
MsgBox("Search Complete", vbOKOnly, "Search For Procedure Elements")
End If
End Sub
Public Sub BtnDecrease(ByVal ctl As IRibbonControl)
Dim rng As Word.Range
Dim rCmt As Word.Range
Dim para As Word.Paragraph
Dim sAuthor As String
Dim vLevel As Object
rng = App.Selection.Range
For Each para In rng.Paragraphs
rCmt = GetComment(para.Range)
If Not rCmt Is Nothing Then
sAuthor = rCmt.Comments(1).Author
If sAuthor Like "STEP*" Then
vLevel = Mid(sAuthor, 6, 1)
If vLevel > 2 Then
ThisLevel = vLevel - 1
Else
ThisLevel = 2
End If
rCmt.Comments(1).Author = "STEP " & ThisLevel
End If
End If
Next para
rng.Select()
End Sub
Public Sub BtnIgnore(ByVal ctl As IRibbonControl)
'RemoveComments
InsertComment("IGNORE")
End Sub
Public Sub BtnIncrease(ByVal ctl As IRibbonControl)
Dim rng As Word.Range
Dim rCmt As Word.Range
Dim para As Word.Paragraph
Dim sAuthor As String
Dim vLevel As Object
rng = App.Selection.Range
For Each para In rng.Paragraphs
rCmt = GetComment(para.Range)
If Not rCmt Is Nothing Then
sAuthor = rCmt.Comments(1).Author
If sAuthor Like "STEP*" Then
vLevel = Mid(sAuthor, 6, 1)
If vLevel < 9 Then
ThisLevel = vLevel + 1
Else
ThisLevel = 9
End If
rCmt.Comments(1).Author = "STEP " & ThisLevel
End If
End If
Next para
rng.Select()
End Sub
Public Sub BtnNote(ByVal ctl As IRibbonControl)
'mark selected text as a note
'RemoveComments
InsertComment("NOTE")
End Sub
Public Sub BtnNext(ByVal ctl As IRibbonControl)
If MoveNext = True Then
GetSection
If InStr(LCase(ThisSection.Type), "word") + App.Selection.Comments.Count = 0 Then
WhatIsThis
End If
End If
End Sub
Public Sub BtnPrevious(ByVal ctl As IRibbonControl)
If MovePrevious = True Then
GetSection
If InStr(LCase(ThisSection.Type), "word") + App.Selection.Comments.Count = 0 Then
WhatIsThis
End If
End If
End Sub
Public Sub BtnCaution(ByVal ctl As IRibbonControl)
'mark selected text as a note
'RemoveComments
InsertComment("CAUTION")
End Sub
Public Sub BtnTable(ByVal ctl As IRibbonControl)
'mark selected table as a table
App.Selection.Tables(1).Select()
'RemoveComments
InsertComment("TABLE")
End Sub
Public Sub BtnTitle(ByVal ctl As IRibbonControl)
'mark selected text as a section title
'RemoveComments
InsertComment("SECTION TITLE")
End Sub
Public Sub BtnFigure(ByVal ctl As IRibbonControl)
'mark selected shape as a figure
App.Selection.InlineShapes(1).Select()
'RemoveComments
InsertComment("FIGURE")
End Sub
Public Sub BtnDelete(ByVal ctl As IRibbonControl)
'remove all comments from the current selection
RemoveComments(True)
End Sub
Public Sub BtnFindSections(ByVal ctl As IRibbonControl)
FindSections
App.StatusBar = "Find Sections - Done"
If Not Me.ribbon Is Nothing Then
Me.ribbon.Invalidate()
End If
End Sub
Public Sub btnMergeSections(ByVal ctl As IRibbonControl)
MergeSections
App.StatusBar = "Merge Sections - Done"
If Not Me.ribbon Is Nothing Then
Me.ribbon.Invalidate()
End If
End Sub
Public Sub BtnSection(ByVal ctl As IRibbonControl)
'RemoveComments
'InsertComment "SECTION", ThisSection.Name & vbCrLf & ThisSection.Description & vbCrLf & ThisSection.Type
If Len(App.Selection.Text) < 2 Then
App.Selection.InsertBefore("SECTION")
End If
FlagSection(ThisSection)
If Not Me.ribbon Is Nothing Then
Me.ribbon.Invalidate()
End If
End Sub
Public Sub BtnSecMoveUp(ByVal ctl As IRibbonControl)
MoveComment("SECTION", "Up")
End Sub
Public Sub BtnSecMoveDown(ByVal ctl As IRibbonControl)
MoveComment("SECTION", "Down")
End Sub
Public Sub BtnSecGoNext(ByVal ctl As IRibbonControl)
App.Selection.GoTo(What:=Word.WdGoToItem.wdGoToComment, Which:=Word.WdGoToDirection.wdGoToNext, Name:="SECTION")
End Sub
Public Sub BtnSecGoPrevious(ByVal ctl As IRibbonControl)
App.Selection.GoTo(What:=Word.WdGoToItem.wdGoToComment, Which:=Word.WdGoToDirection.wdGoToPrevious, Name:="SECTION")
End Sub
Public Sub BtnXMLMake(ByVal ctl As IRibbonControl)
MakePromsXML
End Sub
Public Sub BtnXMLView(ByVal ctl As IRibbonControl)
frmXML.Show
End Sub
Public Sub BtnPXML(ByVal ctl As IRibbonControl)
MakeImportFile
End Sub
Public Sub BtnPSI(ByVal ctl As IRibbonControl)
frmProperties.Show
End Sub
Public Sub OnGetScreentip(ByVal ctl As IRibbonControl, ByRef text As Object)
Dim sText As String
Select Case ctl.Id
Case "btnReset"
sText = "Remove all comments and markups in this document"
Case "btnSearch"
sText = "Locate and markup the elements of this document"
Case "boxTitle"
sText = "Enter title for this section of the document"
Case "btnSection"
sText = "Mark selected location in the document as a Section"
Case "btnDelete"
sText = "Remove all comments and markups from the selected portion of this document"
Case "cbIdent"
sText = "Step identifier such as number or bullet"
Case "cbSeparator"
sText = "Separator between steps at this level"
Case "cbLevel"
sText = "Indentation level for the selected step"
Case "btnDecrease"
sText = "Move this step's indentation level to the left"
Case "btnIncrease"
sText = "Move this step's indentation level to the right"
Case "btnMakeXML"
sText = "Create PROMS Import File"
Case "btnImport2PROMS"
sText = "Under Development"
Case "cbSetup"
sText = "File containing setup parameters"
Case "cbSection"
sText = "Mark the selected text as the start of a Section"
Case "btnTitle"
sText = "Mark the selected text as the Title of this procedure section"
Case "mnuCaution"
sText = "Mark the selected text as a Caution"
Case "mnuEquation"
sText = "Mark the selected text as an Equation"
Case "mnuFigure"
sText = "Mark the selected shape as a Figure"
Case "mnuNote"
sText = "Mark the selected text as a Note"
Case "mnuStep"
sText = "Mark the selected text as a Step"
Case "mnuTable"
sText = "Mark the selected table as a Table"
Case Else
sText = ""
End Select
text = sText
End Sub
Public Sub OnGetItemCount(ByVal ctl As IRibbonControl, ByRef Count As Object)
Select Case ctl.Id
Case "cbLevel"
Count = 9
Case "cbIdent"
GetIdents
Count = UBound(Idents) + 1
Case "cbSeparator"
GetSeparators
Count = UBound(Separators) + 1
Case "cbSetup"
SetupFiles = GetSetupFiles
Count = UBound(SetupFiles) + 1
Case "cbSection"
GetSections
Count = UBound(VESections) + 1
End Select
End Sub
Public Sub OnGetItemLabel(ByVal ctl As IRibbonControl, ByVal Index As Integer, ByRef Label As Object)
Select Case ctl.Id
Case "cbLevel"
Label = CStr(Index + 1)
Case "cbIdent"
Label = Idents(Index)
Case "cbSeparator"
Label = Separators(Index)
Case "cbSetup"
Label = SetupFiles(Index)
Case "cbSection"
Label = VESections(Index).name
End Select
End Sub
Public Sub OnGetContent(ByVal ctl As IRibbonControl, ByRef content As Object)
Dim sXML As String
Dim sName As String
Dim I As Integer
Dim J As Integer
sXML = ""
Select Case ctl.Id
Case "mnuReset"
sXML = MakeMenuReset()
Case "mnuSection", "CTmnuSection"
GetSections
sXML = MakeMenuSection()
Case "mnuStep", "CTmnuStep"
GetSteps(ThisSection.FmtFile)
sXML = MakeMenuStep()
Case "mnuNote", "CTmnuNote"
GetSteps(ThisSection.FmtFile)
sXML = MakeMenuNCTF("Note")
Case "mnuCaution", "CTmnuCaution"
GetSteps(ThisSection.FmtFile)
sXML = MakeMenuNCTF("Caution")
Case "mnuTable", "CTmnuTable"
GetSteps(ThisSection.FmtFile)
sXML = MakeMenuNCTF("Table")
Case "mnuFigure", "CTmnuFigure"
GetSteps(ThisSection.FmtFile)
sXML = MakeMenuNCTF("Figure")
Case "mnuEquation", "CTmnuEquation"
sXML = MakeMenuEquation()
Case "mnuCheckoff", "CTmnuCheckoff"
GetCheckoffs(ThisSection.FmtFile)
sXML = MakeMenuCheckoff()
End Select
content = sXML
End Sub
Private Function MakeMenuSection() As String
Dim Cmt As Word.Comment
Dim sID As String
Dim sNumber As String
Dim sTitle As String
Dim sLabel As String
Dim sNew As String
Dim sXML As String
Dim bAttUseNumbers As Boolean
Dim bSecFound() As Boolean
Dim I As Integer
Dim iAtt As Integer
Dim iSec As Integer
iSec = 1
iAtt = 1
ReDim bSecFound(UBound(VESections))
bAttUseNumbers = False
If GetNodeValue("//AttUseNumbers") = "True" Then
bAttUseNumbers = True
End If
sXML = "<menu xmlns='http://schemas.microsoft.com/office/2006/01/customui' >"
For Each Cmt In App.ActiveDocument.Comments
If Cmt.Author = "SECTION" Then
'existing section found
With Cmt.Range
If .Paragraphs.Count > 5 Then
sNumber = Replace(.Paragraphs(4).Range.Text, Chr(13), "")
sTitle = Replace(.Paragraphs(5).Range.Text, Chr(13), "")
sID = Replace(.Paragraphs(6).Range.Text, Chr(13), "")
If IsNumeric(sID) Then
I = CInt(sID)
bSecFound(I) = Not VESections(I).IsMultiple
'If VESections(I).IsMultiple And (VESections(I).MergeStyle = "") Then
If InStr(1, LCase(sNumber), "attachment") + InStr(1, LCase(sNumber), "appendix") > 0 Then
If bAttUseNumbers Then
sNumber = sNumber & " " & iAtt
Else
sNumber = sNumber & " " & Chr(64 + iAtt)
End If
iAtt = iAtt + 1
End If
sLabel = Trim(sNumber & " " & sTitle)
sXML = sXML & "<menu id='mnuSec" & CStr(iSec) & "' label='" & sLabel & "' >"
sXML = sXML & "<button id='btnSecGoTo" & Cmt.Index & "' label='Go To' onAction='OnAction_SectionGoTo' />"
If sTitle = "" Then
sLabel = "Add Title"
Else
sLabel = Trim("Edit Title: " & sTitle)
End If
sXML = sXML & "<button id='btnSecTitle" & Cmt.Index & "' label='" & sLabel & "' onAction='OnAction_SectionTitle' />"
sXML = sXML & "</menu>"
Else
sXML = sXML & "<button id='btnUnknown" & CStr(iSec) & "' label='Unknown Section Type' />"
End If
End If
End With
iSec = iSec + 1
End If
Next Cmt
sNew = ""
For I = LBound(bSecFound) To UBound(bSecFound)
If bSecFound(I) = False Then
sNew = sNew & "<button id='btnSecNew" & I & "' label='" & VESections(I).name & "' onAction='OnAction_SectionNew' />"
End If
Next I
If sNew <> "" Then
If iSec > 1 Then
sXML = sXML & "<menuSeparator id='mnuSepNew' />"
End If
sXML = sXML & "<menu id='mnuSecNew' label='New' >"
sXML = sXML & sNew
sXML = sXML & "</menu>"
End If
sXML = sXML & "</menu>"
MakeMenuSection = sXML
End Function
Private Function MakeMenuStep() As String
Dim sXML As String
Dim I As Integer
Dim J As Integer
sXML = "<menu xmlns='http://schemas.microsoft.com/office/2006/01/customui' >"
sXML = sXML & "<menu id='mnuHLS' label='HLS' >"
For I = 0 To UBound(VESteps)
With VESteps(I)
If .Type = "HLS" Then
sXML = sXML & "<button id='btnStep1" & I & "' label='" & .Menu & "' onAction='OnAction_Step' />"
End If
End With
Next I
sXML = sXML & "</menu>"
sXML = sXML & "<menuSeparator id='mnuSepHLS' />"
sXML = sXML & "<menu id='mnuSub' label='Substep' >"
For I = 0 To UBound(VESteps)
With VESteps(I)
If .Type = "Substep" Then
sXML = sXML & "<menu id='mnuSub" & I & "' label='" & .Menu & "' >"
For J = 2 To 9
sXML = sXML & "<button id='btnStep" & J & I & "' label='Level " & J & "' onAction='OnAction_Step' />"
Next J
sXML = sXML & "</menu>"
End If
End With
Next I
sXML = sXML & "</menu>"
sXML = sXML & "</menu>"
MakeMenuStep = sXML
End Function
Private Function MakeMenuNCTF(ByVal sType As String) As String
Dim sXML As String
Dim I As Integer
sXML = "<menu xmlns='http://schemas.microsoft.com/office/2006/01/customui' >"
For I = 0 To UBound(VESteps)
With VESteps(I)
If InStr(LCase(.Type), LCase(sType)) > 0 Then
sXML = sXML & "<button id='btnStep" & Left(sType, 1) & I & "' label='" & .Menu & "' onAction='OnAction_" & sType & "' />"
End If
End With
Next I
sXML = sXML & "</menu>"
MakeMenuNCTF = sXML
End Function
Private Function MakeMenuTable() As String
Dim sXML As String
sXML = "<menu xmlns='http://schemas.microsoft.com/office/2006/01/customui' >"
sXML = sXML & "<button id='btnTCTT' label='Text Table' onAction='OnAction_Table' />"
sXML = sXML & "<button id='btnTATT' label='AER Table' onAction='OnAction_Table' />"
sXML = sXML & "</menu>"
MakeMenuTable = sXML
End Function
Private Function MakeMenuFigure() As String
Dim sXML As String
sXML = "<menu xmlns='http://schemas.microsoft.com/office/2006/01/customui' >"
sXML = sXML & "<menu id='mnuFC' label='Centered' >"
sXML = sXML & "<button id='btnFCWB' label='With Border' onAction='OnAction_Figure' />"
sXML = sXML & "<button id='btnFCWOB' label='Without Border' onAction='OnAction_Figure' />"
sXML = sXML & "</menu>"
sXML = sXML & "<menuSeparator id='mnuSepFC' />"
sXML = sXML & "<menu id='mnuFL' label='Left' >"
sXML = sXML & "<button id='btnFLWB' label='With Border' onAction='OnAction_Figure' />"
sXML = sXML & "<button id='btnFLWOB' label='Without Border' onAction='OnAction_Figure' />"
sXML = sXML & "</menu>"
sXML = sXML & "</menu>"
MakeMenuFigure = sXML
End Function
Private Function MakeMenuEquation() As String
Dim sXML As String
sXML = "<menu xmlns='http://schemas.microsoft.com/office/2006/01/customui' >"
sXML = sXML & "<menu id='mnuEC' label='Centered' >"
sXML = sXML & "<button id='btnECWB' label='With Border' onAction='OnAction_Equation' />"
sXML = sXML & "<button id='btnECWOB' label='Without Border' onAction='OnAction_Equation' />"
sXML = sXML & "</menu>"
sXML = sXML & "<menuSeparator id='mnuSepEC' />"
sXML = sXML & "<menu id='mnuEL' label='Left' >"
sXML = sXML & "<button id='btnELWB' label='With Border' onAction='OnAction_Equation' />"
sXML = sXML & "<button id='btnELWOB' label='Without Border' onAction='OnAction_Equation' />"
sXML = sXML & "</menu>"
sXML = sXML & "</menu>"
MakeMenuEquation = sXML
End Function
Private Function MakeMenuReset() As String
Dim sXML As String
sXML = "<menu xmlns='http://schemas.microsoft.com/office/2006/01/customui' >"
sXML = sXML & "<button id='ResetSections' label='Sections' onAction='OnAction_Reset' />"
sXML = sXML & "<button id='ResetSteps' label='Steps' onAction='OnAction_Reset' />"
sXML = sXML & "<button id='ResetNotes' label='Notes' onAction='OnAction_Reset' />"
sXML = sXML & "<button id='ResetCautions' label='Cautions' onAction='OnAction_Reset' />"
sXML = sXML & "<button id='ResetTables' label='Tables' onAction='OnAction_Reset' />"
sXML = sXML & "<button id='ResetFigures' label='Figures' onAction='OnAction_Reset' />"
sXML = sXML & "<button id='ResetEquations' label='Equations' onAction='OnAction_Reset' />"
sXML = sXML & "<button id='ResetIgnored' label='Ignored' onAction='OnAction_Reset' />"
sXML = sXML & "<menuSeparator id='mnuSepEC' />"
sXML = sXML & "<button id='ResetAll' label='All' onAction='OnAction_Reset' />"
sXML = sXML & "</menu>"
MakeMenuReset = sXML
End Function
Private Function MakeMenuCheckoff() As String
Dim sXML As String
Dim sName As String
Dim I As Integer
sXML = "<menu xmlns='http://schemas.microsoft.com/office/2006/01/customui' >"
For I = 0 To UBound(VECheckoffs)
With VECheckoffs(I)
If .Menu <> "" Then
sName = "CO_" & .FmtFile & "(" & .ID & ")"
sXML = sXML & "<menu id='mnuCO" & I & "' label='" & .Menu & "' >"
sXML = sXML & "<button id='btnMarkCO" & I & "' label='Mark As " & sName & "' onAction='OnAction_Checkoff' />"
sXML = sXML & "<button id='btnReplaceCO" & I & "' label='Find And Replace All' onAction='OnAction_Checkoff' />"
sXML = sXML & "</menu>"
End If
End With
Next I
sXML = sXML & "</menu>"
MakeMenuCheckoff = sXML
End Function
Public Sub OnChange(ByVal ctl As IRibbonControl, ByRef text As Object)
Dim I As Integer
Select Case ctl.Id
Case "cbLevel"
ThisLevel = text
Case "cbIdent"
ThisIdent = text
Case "cbSeparator"
ThisSeparator = text
Case "cbSetup"
ClearDocProperties
ThisSetup = text
DocPropertySave(App.ActiveDocument, "SetupFile", ThisSetup)
LoadSetup
ChangeSetup
ThisSection = VESections(0)
UpdateRibbon
Case "cbSection"
For I = 0 To UBound(VESections)
If VESections(I).name = text Then
ThisSection = VESections(I)
ThisSectionID = I
Exit For
End If
Next I
End Select
End Sub
Public Sub OnAction_Step(ByVal ctl As IRibbonControl)
Dim rng As Word.Range
Dim sID As String
Dim I As Integer
Dim iCount As Integer
sID = Replace(ctl.Id, "btnStep", "")
If IsNumeric(Left(sID, 1)) Then
ThisLevel = Left(sID, 1)
End If
sID = Mid(sID, 2)
'RemoveComments False
With App.Selection
If .Information(Word.WdInformation.wdInCommentPane) Then
.Comments(1).Scope.Select()
End If
rng = .Range
iCount = .Paragraphs.Count
For I = 1 To iCount
.Paragraphs(I).Range.Select()
.End = .End - 1
FlagStep(sID)
Next I
rng.Select()
End With
End Sub
Public Sub OnAction_SectionNew(ByVal ctl As IRibbonControl)
Dim sSecNum As String
'strip off common button text to reveal section number
sSecNum = Replace(ctl.Id, "btnSecNew", "")
If IsNumeric(sSecNum) Then
'RemoveComments
With App.Selection
If Len(App.Selection.Text) < 2 Then
.InsertParagraphBefore()
.Paragraphs(1).Range.Select()
.InsertBefore("SECTION")
.Font.Italic = True
End If
End With
ThisSection = VESections(CInt(sSecNum))
FlagSection ThisSection
End If
End Sub
Public Sub OnAction_SectionGoTo(ByVal ctl As IRibbonControl)
Dim sCmtIndex As String
'strip off common button text to reveal section number
sCmtIndex = Replace(ctl.Id, "btnSecGoTo", "")
If IsNumeric(sCmtIndex) Then
App.ActiveDocument.Comments(CInt(sCmtIndex)).Scope.Select()
End If
End Sub
Public Sub OnAction_SectionTitle(ByVal ctl As IRibbonControl)
Dim Cmt As Word.Comment
Dim rng As Word.Range
Dim sCmtIndex As String
Dim sOld As String
Dim sNew As String
'strip off common button text to reveal section number
sCmtIndex = Replace(ctl.Id, "btnSecTitle", "")
If IsNumeric(sCmtIndex) Then
Cmt = App.ActiveDocument.Comments(CInt(sCmtIndex))
With Cmt.Range
sOld = Replace(.Paragraphs(5).Range.Text, Chr(13), "")
If sOld = "" Then
sOld = Replace(App.Selection.Text, Chr(13), "")
End If
sNew = InputBox("Title", "Change Title", sOld)
If sNew <> "" Then
rng = .Paragraphs(5).Range
rng.End = rng.End - 1
rng.Text = sNew
Cmt.Scope.Select()
End If
End With
End If
Me.ribbon.Invalidate()
End Sub
Public Sub OnAction_Caution(ByVal ctl As IRibbonControl)
Dim sID As String
Dim I As Integer
I = Len(ctl.Id)
While I > 0 And IsNumeric(Mid(ctl.Id, I, 1))
sID = Mid(ctl.Id, I)
I = I - 1
End While
ThisIdent = "CAUTION"
FlagStep(sID)
End Sub
Public Sub OnAction_Note(ByVal ctl As IRibbonControl)
Dim sID As String
Dim I As Integer
I = Len(ctl.Id)
While I > 0 And IsNumeric(Mid(ctl.Id, I, 1))
sID = Mid(ctl.Id, I)
I = I - 1
End While
ThisIdent = "NOTE"
FlagStep(sID)
End Sub
Public Sub OnAction_Table(ByVal ctl As IRibbonControl)
Dim sID As String
Dim I As Integer
I = Len(ctl.Id)
While I > 0 And IsNumeric(Mid(ctl.Id, I, 1))
sID = Mid(ctl.Id, I)
I = I - 1
End While
FlagTable(sID)
End Sub
Public Sub OnAction_Figure(ByVal ctl As IRibbonControl)
Dim sID As String
Dim I As Integer
I = Len(ctl.Id)
While I > 0 And IsNumeric(Mid(ctl.Id, I, 1))
sID = Mid(ctl.Id, I)
I = I - 1
End While
FlagFigure(sID)
End Sub
Public Sub OnAction_Equation(ByVal ctl As IRibbonControl)
Dim sMsg As String
Select Case ctl.Id
Case "ECWB"
sMsg = "Centered With Border"
Case "ECWOB"
sMsg = "Centered Without Border"
Case "ELWB"
sMsg = "Left With Border"
Case "ELWOB"
sMsg = "Left Without Border"
End Select
'RemoveComments False
InsertComment("EQUATION", sMsg)
End Sub
Public Sub OnAction_Reset(ByVal ctl As IRibbonControl)
Dim rng As Word.Range
Dim I As Integer
rng = App.Selection.Range
App.ActiveDocument.Content.Select()
Select Case ctl.Id
Case "ResetSections"
RemoveComments(False, "SECTION")
Case "ResetSteps"
For I = 9 To 1 Step -1
RemoveComments(False, "STEP " & I)
Next I
Case "ResetNotes"
RemoveComments(False, "NOTE")
Case "ResetCautions"
RemoveComments(False, "CAUTION")
Case "ResetTables"
RemoveComments(False, "TABLE")
Case "ResetFigures"
RemoveComments(False, "FIGURE")
Case "ResetEquations"
RemoveComments(False, "EQUATION")
Case "ResetIgnored"
RemoveComments(False, "IGNORE")
Case "ResetAll"
RemoveComments(True)
End Select
rng.Select()
End Sub
Public Sub OnAction_Checkoff(ByVal ctl As IRibbonControl)
Dim rng As Word.Range
Dim Cmt As Word.Comment
Dim sID As String
Dim sFmtFile As String
Dim sTag As String
Dim I As Integer
Dim J As Integer
'ensure VECheckoffs have been loaded
On Error Resume Next
I = UBound(VECheckoffs)
If Err.Number <> 0 Then
GetCheckoffs(ThisSection.FmtFile)
Err.Clear()
End If
On Error GoTo 0
If ctl.Id Like "btnMark*" Then
sID = Replace(ctl.Id, "btnMarkCO", "")
sFmtFile = VECheckoffs(CInt(sID)).FmtFile
sTag = "CO_" & sFmtFile & "(" & sID & ")"
If App.Selection.Information(Word.WdInformation.wdInCommentPane) = True Then
Set Cmt = App.Selection.Comments(1)
AddCheckoff(Cmt, sTag)
Else
Set rng = App.Selection.Range
For I = 1 To rng.Paragraphs.Count
For J = rng.Paragraphs(I).Range.Comments.Count To 1 Step -1
Set Cmt = rng.Paragraphs(I).Range.Comments(J)
AddCheckoff(Cmt, sTag)
Next J
Next I
rng.Select()
End If
End If
End Sub
Public Sub OnGetText(ByVal ctl As IRibbonControl, ByRef text As Object)
Select Case ctl.Id
Case "cbLevel"
If ThisLevel = "" Then
ThisLevel = 1
End If
text = ThisLevel
Case "cbIdent"
If ThisIdent = "" Then
GetIdents
ThisIdent = Idents(0)
End If
text = ThisIdent
Case "cbSeparator"
If ThisSeparator = "" Then
GetSeparators
ThisSeparator = Separators(0)
End If
text = ThisSeparator
Case "cbSetup"
If ThisSetup = "" Then
ThisSetup = DocPropertyGet(App.ActiveDocument, "SetupFile")
If ThisSetup = "" Then
SetupFiles = GetSetupFiles()
ThisSetup = SetupFiles(0)
DocPropertySave(App.ActiveDocument, "SetupFile", ThisSetup)
End If
LoadSetup
ChangeSetup
ThisSection = VESections(0)
UpdateRibbon
End If
text = ThisSetup
Case "cbSection"
If ThisSection.name = "" Then
GetSections
ThisSection = VESections(0)
End If
text = ThisSection.name
End Select
End Sub
Public Sub OnGetItemID(ByVal ctl As IRibbonControl, ByRef Index As Integer, ByRef value)
Select Case ctl.Id
Case "cbLevel"
Case "cbIdent"
Case "cbSeparator"
Case "cbSetup"
Case "cbSection"
value = ThisSection.ID
End Select
End Sub
#End Region
#Region "Helpers"
Private Shared Function GetResourceText(ByVal resourceName As String) As String
Dim asm As Reflection.Assembly = Reflection.Assembly.GetExecutingAssembly()
Dim resourceNames() As String = asm.GetManifestResourceNames()
For i As Integer = 0 To resourceNames.Length - 1
If String.Compare(resourceName, resourceNames(i), StringComparison.OrdinalIgnoreCase) = 0 Then
Using resourceReader As IO.StreamReader = New IO.StreamReader(asm.GetManifestResourceStream(resourceNames(i)))
If resourceReader IsNot Nothing Then
Return resourceReader.ReadToEnd()
End If
End Using
End If
Next
Return Nothing
End Function
#End Region
End Class

View File

@@ -0,0 +1,130 @@
<?xml version="1.0" encoding="UTF-8"?>
<customUI xmlns="http://schemas.microsoft.com/office/2009/07/customui" onLoad="Ribbon_Load">
<ribbon>
<tabs>
<tab id="VEImportTab" label="VE Import" insertBeforeMso="TabHome" >
<group id="VEGrp1" label="Setup">
<comboBox id="cbSetup"
label="Setup"
getScreentip="UI.OnGetScreentip"
getItemCount="UI.OnGetItemCount"
getItemLabel="UI.OnGetItemLabel"
onChange="UI.OnChange"
getText="UI.OnGetText">
</comboBox>
<button id="btnPSI"
label="PSI"
imageMso="EditForm"
onAction="UI.BtnPSI"
getScreentip="UI.OnGetScreentip" />
<dynamicMenu id="mnuReset" label="Reset" imageMso="RecurrenceEdit" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip"/>
</group>
<group id="VEGrp2" label="Sections">
<box id="G2Bx1" boxStyle="vertical">
<button id="btnFindSections"
label="Find"
imageMso="PanAndZoomWindow"
onAction="UI.BtnFindSections"
getScreentip="UI.OnGetScreentip" />
<button id="btnMergeSections"
label="Merge"
imageMso="MergeForms"
onAction="UI.BtnMergeSections"
getScreentip="UI.OnGetScreentip" />
</box >
<dynamicMenu id="mnuSection"
label="Edit"
size="large"
imageMso="OutlineSubtotals"
getContent="UI.OnGetContent"
getScreentip="UI.OnGetScreentip" />
<box id="G2Bx2" boxStyle="vertical">
<button id="btnMoveUp"
label="Move Up"
imageMso="FillUp"
onAction="UI.BtnSecMoveUp"
getScreentip="UI.OnGetScreentip" />
<button id="btnMoveDown"
label="Move Down"
imageMso="FillDown"
onAction="UI.BtnSecMoveDown"
getScreentip="UI.OnGetScreentip" />
</box >
</group>
<group id="VEGrp3" label="Mark As">
<button id="btnSearch" label="Search" size="large" imageMso="PanAndZoomWindow" onAction="UI.BtnSearch" getScreentip="UI.OnGetScreentip" />
<box id="G3Bx1" boxStyle="vertical">
<button id="btnPrevious"
label="Go To Previous"
imageMso="FillUp"
onAction="UI.BtnPrevious"
getScreentip="UI.OnGetScreentip" />
<button id="btnNext"
label="Go To Next"
imageMso="FillDown"
onAction="UI.BtnNext"
getScreentip="UI.OnGetScreentip" />
</box >
<dynamicMenu id="mnuStep" label="Step" size="large" imageMso="NumberingGallery" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
<box id="G3Bx2" boxStyle="vertical">
<button id="btnDecrease" label="Decrease" imageMso="IndentDecrease" onAction="UI.BtnDecrease" getScreentip="UI.OnGetScreentip" />
<button id="btnIncrease" label="Increase" imageMso="IndentIncrease" onAction="UI.BtnIncrease" getScreentip="UI.OnGetScreentip" />
</box >
<dynamicMenu id="mnuNote" label="Note" size="large" imageMso="Info" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
<dynamicMenu id="mnuCaution" label="Caution" size="large" imageMso="CancelRequest" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
<dynamicMenu id="mnuTable" label="Table" size="large" imageMso="ChangesDiscardAndRefresh" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
<dynamicMenu id="mnuFigure" label="Figure" size="large" imageMso="ControlUnboundObjectFrame" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
<dynamicMenu id="mnuEquation" label="Equation" size="large" imageMso="EquationLargeOperatorGallery" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
<button id="btnIgnore" label="Ignore" size="large" imageMso="IgnoreThisIssue" onAction="UI.BtnIgnore" getScreentip="UI.OnGetScreentip" />
<button id="btnDelete" label="Delete" size="large" imageMso="DeleteSite" onAction="UI.BtnDelete" getScreentip="UI.OnGetScreentip" />
</group>
<group id="VEGrp4" label="Checkoff">
<dynamicMenu id="mnuCheckoff" label="Checkoff" size="large" imageMso="Info" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
</group>
<group id="VEGrp5" label="XML">
<button id="btnMakeXML" label="Make XML" size="large" imageMso="XmlSource" onAction="UI.BtnXMLMake" getScreentip="UI.OnGetScreentip" />
<button id="btnViewXML" label="View" size="large" imageMso="ViewCode" onAction="UI.BtnXMLView" getScreentip="UI.OnGetScreentip" />
<button id="btnMakeImport" label="Make Import" size="large" imageMso="Export" onAction="UI.BtnPXML" getScreentip="UI.OnGetScreentip" />
</group >
</tab>
</tabs>
</ribbon>
<contextMenus>
<contextMenu idMso="ContextMenuText">
<control idMso="Cut"
visible="false" />
<control idMso="Copy"
visible="false" />
<control idMso="PasteGalleryMini"
visible="false" />
<control idMso="FontDialog"
visible="false" />
<control idMso="ParagraphDialog"
visible="false" />
<control idMso="Insights"
visible="false" />
<control idMso="FixSynonymChangeMenu"
visible="false" />
<control idMso="Translate"
visible="false" />
<control idMso="HyperlinkInsert"
visible="false" />
<control idMso="ReviewNewComment"
visible="false" />
<dynamicMenu id="CTmnuSection" label="Sections" imageMso="OutlineSubtotals" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
<menuSeparator id="CTmnuSepSection" />
<dynamicMenu id="CTmnuStep" label="Step Style" imageMso="NumberingGallery" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
<menuSeparator id="CTmnuSepStep" />
<dynamicMenu id="CTmnuNote" label="Note" imageMso="Info" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
<dynamicMenu id="CTmnuCaution" label="Caution" imageMso="CancelRequest" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
<dynamicMenu id="CTmnuTable" label="Table" imageMso="ChangesDiscardAndRefresh" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
<dynamicMenu id="CTmnuFigure" label="Figure" imageMso="ControlUnboundObjectFrame" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
<dynamicMenu id="CTmnuEquation" label="Equation" imageMso="EquationLargeOperatorGallery" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
<button id="CTbtnIgnore" label="Ignore" imageMso="IgnoreThisIssue" onAction="UI.BtnIgnore" getScreentip="UI.OnGetScreentip" />
<button id="CTbtnDelete" label="Delete" imageMso="DeleteSite" onAction="UI.BtnDelete" getScreentip="UI.OnGetScreentip" />
<menuSeparator id='CTmnuSepCheckoff' />
<dynamicMenu id="CTmnuCheckoff" label="Checkoff" imageMso="Info" getContent="UI.OnGetContent" getScreentip="UI.OnGetScreentip" />
</contextMenu>
</contextMenus>
</customUI>

View File

@@ -0,0 +1,115 @@
Option Explicit On
Imports MSXML2
Module Setup
Public App As Word.Application
Public Structure LevelDef
Public Def As String
Public Level As Integer
End Structure
Public Structure StepStyle
Public ID As String
Public LevelDefs() As LevelDef
End Structure
Public Structure VESection
Public ID As String
Public Pattern As String
Public number As String
Public Title As String
Public Style As String
Public StyleID As String
Public StyleName As String
Public name As String
Public IsSub As Boolean
Public StepStyle As StepStyle
Public StepOffset As Integer
Public IsMultiple As Boolean
Public FmtFile As String
Public Type As String
Public Library As String
Public TableStyle As String
Public ColumnMode As String
Public MergeStyle As String
Public HeaderTag As String
Public Config As String
Public ChangeNumber As Boolean
Public FindTitle As String
Public Level As String
End Structure
Public Structure VEStep
Public ID As String
Public FmtFile As String
Public Description As String
Public Ident As String
Public Type As String
Public Parent As String
Public Menu As String
Public NumStyle As String
Public Deflt As String
End Structure
Public Structure VEFormat
Public name As String
Public dom As DOMDocument60
End Structure
Public Structure VECheckoff
Public ID As String
Public FmtFile As String
Public Menu As String
End Structure
Public Structure VEProperty
Public name As String
Public Type As String
Public text As String
Public value As String
End Structure
Public Structure VEPSI
Public Style As String
Public name As String
Public Type As String
Public text As String
Public value As String
Public Justify As String
Public x As String
Public y As String
Public Width As String
Public Height As String
Public Length As String
End Structure
Public Structure VEPSIFrame
'X As String
'Y As String
Public Width As String
Public Height As String
Public Caption As String
End Structure
Public Idents As Object
Public IgnoreMe() As String
Public Separators As Object
Public SetupFiles As Object
Public VECheckoffs() As VECheckoff
Public VEProperties() As VEProperty
Public VESections() As VESection
Public VESteps() As VEStep
Public StepStyles() As StepStyle
Public domSetup As DOMDocument60
Public ThisFormat As VEFormat
Public ThisPSI() As VEPSI
Public ThisPSIFrame As VEPSIFrame
Public MySection As VESection
Public ThisSection As VESection
Public ThisSectionID As Integer
Public ThisStepStyle As StepStyle
Public ThisStepStyleID As Integer
Public ThisVEStep As VEStep
Public ThisSeparator As String
Public ThisLevel As String
Public ThisIdent As String
Public ThisSetup As String
Public RibbonStatus As String
Public ThisRange As Word.Range
Const FmtFolder As String = "fmtall"
Const sSetupFileExtension As String = ".xml"
Public Const bDebug As Boolean = True
End Module

View File

@@ -0,0 +1,234 @@
'------------------------------------------------------------------------------
' <auto-generated>
' This code was generated by a tool.
' Runtime Version:4.0.30319.42000
'
' Changes to this file may cause incorrect behavior and will be lost if
' the code is regenerated.
' </auto-generated>
'------------------------------------------------------------------------------
Option Strict Off
Option Explicit On
'''
<Microsoft.VisualStudio.Tools.Applications.Runtime.StartupObjectAttribute(0), _
Global.System.Security.Permissions.PermissionSetAttribute(Global.System.Security.Permissions.SecurityAction.Demand, Name:="FullTrust")> _
Partial Public NotInheritable Class ThisAddIn
Inherits Microsoft.Office.Tools.AddInBase
Friend WithEvents CustomTaskPanes As Microsoft.Office.Tools.CustomTaskPaneCollection
Friend WithEvents VstoSmartTags As Microsoft.Office.Tools.SmartTagCollection
<Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0")> _
Friend WithEvents Application As Microsoft.Office.Interop.Word.Application
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Public Sub New(ByVal factory As Global.Microsoft.Office.Tools.Word.ApplicationFactory, ByVal serviceProvider As Global.System.IServiceProvider)
MyBase.New(factory, serviceProvider, "AddIn", "ThisAddIn")
Globals.Factory = factory
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Protected Overrides Sub Initialize()
MyBase.Initialize()
Me.Application = Me.GetHostItem(Of Microsoft.Office.Interop.Word.Application)(GetType(Microsoft.Office.Interop.Word.Application), "Application")
Globals.ThisAddIn = Me
Global.System.Windows.Forms.Application.EnableVisualStyles()
Me.InitializeCachedData()
Me.InitializeControls()
Me.InitializeComponents()
Me.InitializeData()
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Protected Overrides Sub FinishInitialization()
Me.OnStartup()
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Protected Overrides Sub InitializeDataBindings()
Me.BeginInitialization()
Me.BindToData()
Me.EndInitialization()
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub InitializeCachedData()
If (Me.DataHost Is Nothing) Then
Return
End If
If Me.DataHost.IsCacheInitialized Then
Me.DataHost.FillCachedData(Me)
End If
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub InitializeData()
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub BindToData()
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
Private Sub StartCaching(ByVal MemberName As String)
Me.DataHost.StartCaching(Me, MemberName)
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
Private Sub StopCaching(ByVal MemberName As String)
Me.DataHost.StopCaching(Me, MemberName)
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
Private Function IsCached(ByVal MemberName As String) As Boolean
Return Me.DataHost.IsCached(Me, MemberName)
End Function
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub BeginInitialization()
Me.BeginInit()
Me.CustomTaskPanes.BeginInit()
Me.VstoSmartTags.BeginInit()
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub EndInitialization()
Me.VstoSmartTags.EndInit()
Me.CustomTaskPanes.EndInit()
Me.EndInit()
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub InitializeControls()
Me.CustomTaskPanes = Globals.Factory.CreateCustomTaskPaneCollection(Nothing, Nothing, "CustomTaskPanes", "CustomTaskPanes", Me)
Me.VstoSmartTags = Globals.Factory.CreateSmartTagCollection(Nothing, Nothing, "VstoSmartTags", "VstoSmartTags", Me)
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Private Sub InitializeComponents()
End Sub
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Advanced)> _
Private Function NeedsFill(ByVal MemberName As String) As Boolean
Return Me.DataHost.NeedsFill(Me, MemberName)
End Function
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0"), _
Global.System.ComponentModel.EditorBrowsableAttribute(Global.System.ComponentModel.EditorBrowsableState.Never)> _
Protected Overrides Sub OnShutdown()
Me.VstoSmartTags.Dispose()
Me.CustomTaskPanes.Dispose()
MyBase.OnShutdown()
End Sub
End Class
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0")> _
Partial Friend NotInheritable Class Globals
'''
Private Sub New()
MyBase.New()
End Sub
Private Shared _ThisAddIn As ThisAddIn
Private Shared _factory As Global.Microsoft.Office.Tools.Word.ApplicationFactory
Private Shared _ThisRibbonCollection As ThisRibbonCollection
Friend Shared Property ThisAddIn() As ThisAddIn
Get
Return _ThisAddIn
End Get
Set(ByVal value As ThisAddIn)
If (_ThisAddIn Is Nothing) Then
_ThisAddIn = value
Else
Throw New System.NotSupportedException()
End If
End Set
End Property
Friend Shared Property Factory() As Global.Microsoft.Office.Tools.Word.ApplicationFactory
Get
Return _factory
End Get
Set(ByVal value As Global.Microsoft.Office.Tools.Word.ApplicationFactory)
If (_factory Is Nothing) Then
_factory = value
Else
Throw New System.NotSupportedException()
End If
End Set
End Property
Friend Shared ReadOnly Property Ribbons() As ThisRibbonCollection
Get
If (_ThisRibbonCollection Is Nothing) Then
_ThisRibbonCollection = New ThisRibbonCollection(_factory.GetRibbonFactory)
End If
Return _ThisRibbonCollection
End Get
End Property
End Class
'''
<Global.System.Diagnostics.DebuggerNonUserCodeAttribute(), _
Global.System.CodeDom.Compiler.GeneratedCodeAttribute("Microsoft.VisualStudio.Tools.Office.ProgrammingModel.dll", "16.0.0.0")> _
Partial Friend NotInheritable Class ThisRibbonCollection
Inherits Microsoft.Office.Tools.Ribbon.RibbonCollectionBase
'''
Friend Sub New(ByVal factory As Global.Microsoft.Office.Tools.Ribbon.RibbonFactory)
MyBase.New(factory)
End Sub
End Class

View File

@@ -0,0 +1,5 @@
<hostitem:hostItem hostitem:baseType="Microsoft.Office.Tools.AddInBase" hostitem:namespace="" hostitem:className="ThisAddIn" hostitem:identifier="ThisAddIn" hostitem:primaryCookie="AddIn" hostitem:master="true" hostitem:factoryType="Microsoft.Office.Tools.Word.ApplicationFactory" 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.Word.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>

View File

@@ -0,0 +1,20 @@
Public Class ThisAddIn
Private Sub ThisAddIn_Startup() Handles Me.Startup
End Sub
Private Sub ThisAddIn_Shutdown() Handles Me.Shutdown
End Sub
Protected Overrides Function CreateRibbonExtensibilityObject() As Microsoft.Office.Core.IRibbonExtensibility
Return New Ribbon1()
End Function
Public Sub HelloWorld()
MsgBox("Hello World", vbOKOnly, "Testing")
End Sub
End Class

File diff suppressed because it is too large Load Diff

View File

@@ -0,0 +1,294 @@
<Project ToolsVersion="16.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<!--
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};{F184B08F-C81C-45F6-A57F-5ABD9991F28F}</ProjectTypeGuids>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProjectGuid>{8116F31D-7220-4519-8648-93546FA7259C}</ProjectGuid>
<OutputType>Library</OutputType>
<RootNamespace>W2PAddIn</RootNamespace>
<AssemblyName>W2PAddIn</AssemblyName>
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
<DefineConstants>VSTO40</DefineConstants>
<StartupObject>
</StartupObject>
<IsWebBootstrapper>False</IsWebBootstrapper>
<BootstrapperEnabled>true</BootstrapperEnabled>
<PublishUrl>publish\</PublishUrl>
<InstallUrl />
<TargetCulture>en</TargetCulture>
<ApplicationVersion>1.0.0.0</ApplicationVersion>
<AutoIncrementApplicationRevision>true</AutoIncrementApplicationRevision>
<UpdateEnabled>true</UpdateEnabled>
<UpdateInterval>7</UpdateInterval>
<UpdateIntervalUnits>days</UpdateIntervalUnits>
<ProductName>W2PAddIn</ProductName>
<PublisherName />
<SupportUrl />
<FriendlyName>W2PAddIn</FriendlyName>
<OfficeApplicationDescription />
<LoadBehavior>3</LoadBehavior>
</PropertyGroup>
<ItemGroup>
<BootstrapperPackage Include=".NETFramework,Version=v4.7.2">
<Visible>False</Visible>
<ProductName>Microsoft .NET Framework 4.7.2 %28x86 and x64%29</ProductName>
<Install>true</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.Net.Framework.3.5.SP1">
<Visible>False</Visible>
<ProductName>.NET Framework 3.5 SP1</ProductName>
<Install>false</Install>
</BootstrapperPackage>
<BootstrapperPackage Include="Microsoft.VSTORuntime.4.0">
<Visible>False</Visible>
<ProductName>Microsoft Visual Studio 2010 Tools for Office Runtime %28x86 and x64%29</ProductName>
<Install>true</Install>
</BootstrapperPackage>
</ItemGroup>
<PropertyGroup>
<!--
OfficeApplication
Add-in host application
-->
<OfficeApplication>Word</OfficeApplication>
</PropertyGroup>
<PropertyGroup>
<OptionInfer>On</OptionInfer>
</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' ">
<DefineConstants>$(DefineConstants)</DefineConstants>
<DefineDebug>true</DefineDebug>
<DefineTrace>true</DefineTrace>
<DebugType>full</DebugType>
<DebugSymbols>true</DebugSymbols>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DocumentationFile>W2PAddIn.xml</DocumentationFile>
<RegisterForComInterop>false</RegisterForComInterop>
<RemoveIntegerChecks>false</RemoveIntegerChecks>
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
</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' ">
<DefineConstants>
</DefineConstants>
<DefineDebug>false</DefineDebug>
<DefineTrace>true</DefineTrace>
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DocumentationFile>W2PAddIn.xml</DocumentationFile>
<RegisterForComInterop>false</RegisterForComInterop>
<RemoveIntegerChecks>false</RemoveIntegerChecks>
<NoWarn>42016,41999,42017,42018,42019,42032,42036,42020,42021,42022</NoWarn>
</PropertyGroup>
<!--
This section specifies references for the project.
-->
<ItemGroup>
<Reference Include="Accessibility" />
<Reference Include="System" />
<Reference Include="System.Data" />
<Reference Include="System.Drawing" />
<Reference Include="System.Windows.Forms" />
<Reference Include="System.Xml" />
<Reference Include="System.Core" />
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
</ItemGroup>
<ItemGroup>
<Reference Include="Microsoft.Office.Tools.v4.0.Framework, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<Private>False</Private>
</Reference>
<Reference Include="Microsoft.VisualStudio.Tools.Applications.Runtime, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<Private>False</Private>
</Reference>
<Reference Include="Microsoft.Office.Tools, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<Private>False</Private>
</Reference>
<Reference Include="Microsoft.Office.Tools.Common, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<Private>False</Private>
</Reference>
<Reference Include="Microsoft.Office.Tools.Word, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<Private>False</Private>
</Reference>
</ItemGroup>
<ItemGroup>
<Reference Include="Microsoft.Office.Tools.Common.v4.0.Utilities, Version=10.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<Private>True</Private>
</Reference>
</ItemGroup>
<ItemGroup>
<Reference Include="Office, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c">
<Private>False</Private>
<EmbedInteropTypes>true</EmbedInteropTypes>
</Reference>
<Reference Include="Microsoft.Office.Interop.Word, Version=15.0.0.0, Culture=neutral, PublicKeyToken=71e9bce111e9429c">
<Private>False</Private>
<EmbedInteropTypes>true</EmbedInteropTypes>
</Reference>
<Reference Include="stdole, Version=7.0.3300.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a">
<Private>False</Private>
</Reference>
</ItemGroup>
<!-- Visual Basic supports importing namespaces (equivalent to "using" statements in C#). -->
<ItemGroup>
<Import Include="Microsoft.VisualBasic" />
<Import Include="System" />
<Import Include="System.Collections.Generic" />
<Import Include="System.Linq" />
<Import Include="System.Text" />
<Import Include="System.Xml.Linq" />
<Import Include="Office = Microsoft.Office.Core" />
<Import Include="Word = Microsoft.Office.Interop.Word" />
<Import Include="Microsoft.Office.Tools.Word" />
</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>
<AppDesigner Include="My Project\" />
<Compile Include="Cmt.vb" />
<Compile Include="Tools.vb" />
<Compile Include="Setup.vb" />
<Compile Include="Ribbon1.vb" />
<Compile Include="ThisAddIn.vb">
<SubType>Code</SubType>
</Compile>
<None Include="ThisAddIn.Designer.xml">
<DependentUpon>ThisAddIn.vb</DependentUpon>
</None>
<Compile Include="ThisAddIn.Designer.vb">
<DependentUpon>ThisAddIn.Designer.xml</DependentUpon>
</Compile>
<Compile Include="My Project\AssemblyInfo.vb" />
<EmbeddedResource Include="My Project\Resources.resx">
<Generator>VbMyResourcesResXFileCodeGenerator</Generator>
<LastGenOutput>Resources.Designer.vb</LastGenOutput>
<CustomToolNamespace>My.Resources</CustomToolNamespace>
<SubType>Designer</SubType>
</EmbeddedResource>
<Compile Include="My Project\Resources.Designer.vb">
<AutoGen>True</AutoGen>
<DesignTime>True</DesignTime>
<DependentUpon>Resources.resx</DependentUpon>
</Compile>
<None Include="My Project\Settings.settings">
<Generator>SettingsSingleFileGenerator</Generator>
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
</None>
<Compile Include="My Project\Settings.Designer.vb">
<AutoGen>True</AutoGen>
<DependentUpon>Settings.settings</DependentUpon>
<DesignTimeSharedInput>True</DesignTimeSharedInput>
</Compile>
<None Include="W2PAddIn_TemporaryKey.pfx" />
</ItemGroup>
<ItemGroup>
<EmbeddedResource Include="Ribbon1.xml" />
</ItemGroup>
<ItemGroup>
<COMReference Include="MSXML2">
<Guid>{F5078F18-C551-11D3-89B9-0000F81FE221}</Guid>
<VersionMajor>6</VersionMajor>
<VersionMinor>0</VersionMinor>
<Lcid>0</Lcid>
<WrapperTool>tlbimp</WrapperTool>
<Isolated>False</Isolated>
<EmbedInteropTypes>True</EmbedInteropTypes>
</COMReference>
</ItemGroup>
<PropertyGroup>
<VisualStudioVersion Condition="'$(VisualStudioVersion)' == ''">10.0</VisualStudioVersion>
<VSToolsPath Condition="'$(VSToolsPath)' == ''">$(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion)</VSToolsPath>
</PropertyGroup>
<PropertyGroup>
<OptionExplicit>On</OptionExplicit>
</PropertyGroup>
<PropertyGroup>
<OptionCompare>Binary</OptionCompare>
</PropertyGroup>
<PropertyGroup>
<OptionStrict>Off</OptionStrict>
</PropertyGroup>
<PropertyGroup>
<SignManifests>true</SignManifests>
</PropertyGroup>
<PropertyGroup>
<ManifestKeyFile>W2PAddIn_TemporaryKey.pfx</ManifestKeyFile>
</PropertyGroup>
<PropertyGroup>
<ManifestCertificateThumbprint>F465CB637D617137E692F112047E506C182EFF5E</ManifestCertificateThumbprint>
</PropertyGroup>
<!-- Include the build rules for a Visual Basic project. -->
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
<!-- Include additional build rules for an Office application add-in. -->
<Import Project="$(VSToolsPath)\OfficeTools\Microsoft.VisualStudio.Tools.Office.targets" Condition="'$(VSToolsPath)' != ''" />
<!-- This section defines VSTO properties that describe the host-changeable project properties. -->
<ProjectExtensions>
<VisualStudio>
<FlavorProperties GUID="{BAA0C2D2-18E2-41B9-852F-F413020CAA33}">
<ProjectProperties HostName="Word" HostPackage="{29A7B9D7-A7F1-4328-8EF0-6B2D1A56B2C1}" OfficeVersion="15.0" VstxVersion="4.0" ApplicationType="Word" Language="vb" TemplatesPath="" DebugInfoExeName="#Software\Microsoft\Office\16.0\Word\InstallRoot\Path#WINWORD.EXE" DebugInfoCommandLine="/x" AddItemTemplatesGuid="{DCFE8D25-4715-4C33-9EAB-A34A9EBC9544}" />
<Host Name="Word" IconIndex="0">
<HostItem Name="ThisAddIn" Code="ThisAddIn.vb" CanonicalName="AddIn" CanActivate="false" IconIndex="1" Blueprint="ThisAddIn.Designer.xml" GeneratedCode="ThisAddIn.Designer.vb" />
</Host>
</FlavorProperties>
</VisualStudio>
</ProjectExtensions>
</Project>

View File

@@ -0,0 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<PublishUrlHistory />
<InstallUrlHistory />
<SupportUrlHistory />
</PropertyGroup>
</Project>

View File

@@ -0,0 +1,21 @@
<?xml version="1.0" encoding="utf-8"?>
<asmv1:assembly xsi:schemaLocation="urn:schemas-microsoft-com:asm.v1 assembly.adaptive.xsd" manifestVersion="1.0" xmlns:asmv1="urn:schemas-microsoft-com:asm.v1" xmlns="urn:schemas-microsoft-com:asm.v2" xmlns:asmv2="urn:schemas-microsoft-com:asm.v2" xmlns:xrml="urn:mpeg:mpeg21:2003:01-REL-R-NS" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:asmv3="urn:schemas-microsoft-com:asm.v3" xmlns:dsig="http://www.w3.org/2000/09/xmldsig#" xmlns:co.v1="urn:schemas-microsoft-com:clickonce.v1" xmlns:co.v2="urn:schemas-microsoft-com:clickonce.v2">
<assemblyIdentity name="W2PAddIn.vsto" version="1.0.0.0" publicKeyToken="d86ab549373cd2ed" language="neutral" processorArchitecture="msil" xmlns="urn:schemas-microsoft-com:asm.v1" />
<description asmv2:publisher="Windows User" asmv2:product="W2PAddIn" xmlns="urn:schemas-microsoft-com:asm.v1" />
<deployment install="false" />
<compatibleFrameworks xmlns="urn:schemas-microsoft-com:clickonce.v2">
<framework targetVersion="4.7.2" profile="Full" supportedRuntime="4.0.30319" />
</compatibleFrameworks>
<dependency>
<dependentAssembly dependencyType="install" codebase="W2PAddIn.dll.manifest" size="12526">
<assemblyIdentity name="W2PAddIn.dll" version="1.0.0.0" publicKeyToken="d86ab549373cd2ed" language="neutral" processorArchitecture="msil" type="win32" />
<hash>
<dsig:Transforms>
<dsig:Transform Algorithm="urn:schemas-microsoft-com:HashTransforms.Identity" />
</dsig:Transforms>
<dsig:DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" />
<dsig:DigestValue>nuvIPa2NhLuJY/2OPyRAWjIaHMYGGc2VbFXtJbeOmuI=</dsig:DigestValue>
</hash>
</dependentAssembly>
</dependency>
<publisherIdentity name="CN=VLN\Jeff" issuerKeyHash="4b01709bbd58d086ce53ae880354a453ce5d4b51" /><Signature Id="StrongNameSignature" xmlns="http://www.w3.org/2000/09/xmldsig#"><SignedInfo><CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#" /><SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha256" /><Reference URI=""><Transforms><Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature" /><Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#" /></Transforms><DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /><DigestValue>i75V9++J1vYD7+eyWhwyZVMMjzjp6B+t01cU+mvalow=</DigestValue></Reference></SignedInfo><SignatureValue>ML4j0AsMGerYcbacaeEUB0scgNjV5n0YctckYCQqPCh4yB0Jqs7RmwPAnToLyJN0flj11awPmg6L7NC6p736Ea346VLeU7EquaTNje+OPN8s0gvWRTXmiE8LIpFkEvHszBtXIua5kAm1mu3jxKwaYGQNU7pRcea1g5af9/XEH4Y=</SignatureValue><KeyInfo Id="StrongNameKeyInfo"><KeyValue><RSAKeyValue><Modulus>x7gOeAuaRjoF7uYD1y7gT0fHgcZDWiBwirwA2rTscr8qlMKRv++ZV2zim4U2pHOuD2CaXgsK8/LBs5vjzmG5X1Psq3LsPFpk/mtqNSuGiKbxhX9rcUPnBqBzbo8KCsDZPIIEpYMVyE+F08K/FX50uRbtKU1AxtohMQW2PvJKsgE=</Modulus><Exponent>AQAB</Exponent></RSAKeyValue></KeyValue><msrel:RelData xmlns:msrel="http://schemas.microsoft.com/windows/rel/2005/reldata"><r:license xmlns:r="urn:mpeg:mpeg21:2003:01-REL-R-NS" xmlns:as="http://schemas.microsoft.com/windows/pki/2005/Authenticode"><r:grant><as:ManifestInformation Hash="8c96da6bfa1457d3ad1fe8e9388f0c5365321c5ab2e7ef03f6d689eff755be8b" Description="" Url=""><as:assemblyIdentity name="W2PAddIn.vsto" version="1.0.0.0" publicKeyToken="d86ab549373cd2ed" language="neutral" processorArchitecture="msil" xmlns="urn:schemas-microsoft-com:asm.v1" /></as:ManifestInformation><as:SignedBy /><as:AuthenticodePublisher><as:X509SubjectName>CN=VLN\Jeff</as:X509SubjectName></as:AuthenticodePublisher></r:grant><r:issuer><Signature Id="AuthenticodeSignature" xmlns="http://www.w3.org/2000/09/xmldsig#"><SignedInfo><CanonicalizationMethod Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#" /><SignatureMethod Algorithm="http://www.w3.org/2000/09/xmldsig#rsa-sha256" /><Reference URI=""><Transforms><Transform Algorithm="http://www.w3.org/2000/09/xmldsig#enveloped-signature" /><Transform Algorithm="http://www.w3.org/2001/10/xml-exc-c14n#" /></Transforms><DigestMethod Algorithm="http://www.w3.org/2000/09/xmldsig#sha256" /><DigestValue>j6fDpjwUU4iSfEWOE8klhD6G8qNpWk4jfLxkVQck8bU=</DigestValue></Reference></SignedInfo><SignatureValue>YAfaKL4wZRufRripkyKBF1+8qTqmBeCx0/2k1pwD7qkkCwmYNmoCDMGyVW3lUP8fnIIng3o25jw9NzjgFwrC7n/hNBaTj/sPwaq5PxZZt0c/RuWNn95PdVknh7ilwzDljR8qj1d3AQwamz9zQYM+2lgMX13OcoLoIO90OKz9llM=</SignatureValue><KeyInfo><KeyValue><RSAKeyValue><Modulus>x7gOeAuaRjoF7uYD1y7gT0fHgcZDWiBwirwA2rTscr8qlMKRv++ZV2zim4U2pHOuD2CaXgsK8/LBs5vjzmG5X1Psq3LsPFpk/mtqNSuGiKbxhX9rcUPnBqBzbo8KCsDZPIIEpYMVyE+F08K/FX50uRbtKU1AxtohMQW2PvJKsgE=</Modulus><Exponent>AQAB</Exponent></RSAKeyValue></KeyValue><X509Data><X509Certificate>MIIBuTCCASKgAwIBAgIQLPdNsN9k4a9AG4GokyPktTANBgkqhkiG9w0BAQsFADAbMRkwFwYDVQQDHhAAVgBMAE4AXABKAGUAZgBmMB4XDTIxMDMyNjE3MTc0M1oXDTIyMDMyNjIzMTc0M1owGzEZMBcGA1UEAx4QAFYATABOAFwASgBlAGYAZjCBnzANBgkqhkiG9w0BAQEFAAOBjQAwgYkCgYEAx7gOeAuaRjoF7uYD1y7gT0fHgcZDWiBwirwA2rTscr8qlMKRv++ZV2zim4U2pHOuD2CaXgsK8/LBs5vjzmG5X1Psq3LsPFpk/mtqNSuGiKbxhX9rcUPnBqBzbo8KCsDZPIIEpYMVyE+F08K/FX50uRbtKU1AxtohMQW2PvJKsgECAwEAATANBgkqhkiG9w0BAQsFAAOBgQBwD8xvC/uhFv49GfC48OqUwN1Kx/m6I/vMKv05Q/ytQ1zfnt2o46tN2BzZ4kB0hRb0NbTWyEqRaon2q30FzHbH9ps+ZT7fuMff8QdWPt+n8fiI3V9XqLreBv/7vdJz72aT82VBJFKyWd+8L6qNOFvcJtg+b5x1wtXvsByVTKImhw==</X509Certificate></X509Data></KeyInfo></Signature></r:issuer></r:license></msrel:RelData></KeyInfo></Signature></asmv1:assembly>

View File

@@ -0,0 +1,7 @@
' <autogenerated/>
Option Strict Off
Option Explicit On
Imports System
Imports System.Reflection
<Assembly: Global.System.Runtime.Versioning.TargetFrameworkAttribute(".NETFramework,Version=v4.7.2", FrameworkDisplayName:=".NET Framework 4.7.2")>

View File

@@ -0,0 +1 @@
b60a9c9413416665430fcbd3dd5127aa6190c026

View File

@@ -0,0 +1,20 @@
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\bin\Debug\W2PAddIn.dll
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\bin\Debug\W2PAddIn.pdb
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\bin\Debug\W2PAddIn.xml
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\bin\Debug\W2PAddIn.dll.manifest
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\bin\Debug\W2PAddIn.vsto
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\bin\Debug\Microsoft.Office.Tools.Common.v4.0.Utilities.dll
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\obj\Debug\W2PAddIn.vbprojAssemblyReference.cache
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\obj\Debug\W2PAddIn.Resources.resources
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\obj\Debug\W2PAddIn.vbproj.GenerateResource.cache
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\obj\Debug\W2PAddIn.vbproj.CoreCompileInputs.cache
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\obj\Debug\W2PAddIn.vbproj.CopyComplete
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\obj\Debug\W2PAddIn.dll
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\obj\Debug\W2PAddIn.xml
C:\Users\Jeff.VLN\source\repos\W2PAddIn\W2PAddIn\obj\Debug\W2PAddIn.pdb
C:\Data\WORD ADD-INs\W2PAddIn\W2PAddIn\obj\Debug\W2PAddIn.vbproj.AssemblyReference.cache
C:\Data\WORD ADD-INs\W2PAddIn\W2PAddIn\obj\Debug\Interop.MSXML2.dll
C:\Data\WORD ADD-INs\W2PAddIn\W2PAddIn\obj\Debug\W2PAddIn.vbproj.ResolveComReference.cache
C:\Data\WORD ADD-INs\W2PAddIn\W2PAddIn\obj\Debug\W2PAddIn.Resources.resources
C:\Data\WORD ADD-INs\W2PAddIn\W2PAddIn\obj\Debug\W2PAddIn.vbproj.GenerateResource.cache
C:\Data\WORD ADD-INs\W2PAddIn\W2PAddIn\obj\Debug\W2PAddIn.vbproj.CoreCompileInputs.cache