...Document mainDocument = tab.MainDocument;
if (mainDocument.IsVoid) return -1;
ResourceManager rm = new System.Resources.ResourceManager("", System.Reflection.Assembly.GetExecutingAssembly());
string rectangleString = tab.FindImage(rm.GetString(""), new[] { new Rectangle(0, 0...