I am trying to add items to shared buttons and galleries. The problem is related to Factory. In the following code, the OfficeRibbon Factory code is unknown. It is also unknown in the addin code file. Iām missing a link somewhere. I also tried Globals.Factory is still unknown.
RibbonButton rc = this.Factory.CreateRibbonButton();
I have the following statements.
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Globalization;
using System.IO;
using System.Text.RegularExpressions;
using System.Threading;
using System.Windows.Forms;
using Microsoft.Office.Interop.Excel;
using Microsoft.Office.Tools.Ribbon;
This code also does not work in ThisAddin.cs, which was renamed to ReqCommon.cs in my project.
My desired end goal is to dynamically add elements to these two controls. The examples I found here and elsewhere seem to be based on this elusive Factory.
The project refers to Microsoft.Office.Tools.Common.v9.0.dll
source
share