This project has moved and is read-only. For the latest updates, please go here.

problem Failed to resolve Assembly

Oct 24, 2012 at 7:06 AM

ciao SebastianDotNet.

Ti ringrazio infinitamente per l'ottimo lavoro che stai facendo !!!

This is my pc :

OS: Windows 7Ultimate  X64

VS : Visual Sudio Ultimate

Net Office : NetOffice [RC]

Here's my problem:

In Your Solution NetOffice.sln 

Project : ClientApplication

Class : Form1

in  public Form1() :

i Have Add This Code ( to Try) :

try          {

            /*Initialize Api COMObject Support*/            NetOffice.Factory.Initialize();            DebugConsole.Mode = ConsoleMode.MemoryList;
                    /*>> your testcode here <<*/
            // start outlook            Outlook.Application outlookApplication = new Outlook.Application();
            // create a new TaskItem.            Outlook.TaskItem newTask = outlookApplication.CreateItem(OlItemType.olTaskItem) as Outlook.TaskItem;
            // Configure the task at hand and save it.            newTask.Subject = "Don't forget to check for NetOffice.DeveloperToolbox updates";            newTask.Body = "check updates here:";            newTask.DueDate = DateTime.Now;            newTask.Importance = OlImportance.olImportanceHigh;            newTask.Save();
            // close outlook and dispose            outlookApplication.Quit();            outlookApplication.Dispose();    }                catch (Exception)                {                    Console.WriteLine("------------------------");                    Console.WriteLine("An error is occured. NetOffice DebugConsole content below:");
                    foreach (string item in DebugConsole.Messages)                        Console.WriteLine(item);
                    Console.WriteLine("------------------------");                }                finally                {

ON  Outlook.TaskItem newTask = outlookApplication.CreateItem(OlItemType.olTaskItem) as Outlook.TaskItem;

Cath Error


An error is occured. NetOffice DebugConsole content below:

Failed to resolve Assembly

Failed to resolve Assembly


Message:Please call NetOffice.Factory.Initialize()

Target:NetOffice.IFactoryInfo GetFactoryInfo(System.Object)Stack:   in NetOffice.Factory.GetFactoryInfo(Object comProxy) in D:\Download\NetOffice [RC]\NetOffice [RC]\Source\NetOffice\Factory.cs:riga 1013   in NetOffice.Factory.CreateObjectFromComProxy(COMObject caller, Object comProxy) in D:\Download\NetOffice [RC]\NetOffice [RC]\Source\NetOffice\Factory.cs:riga 544


i Hope that help you to enhance this great product that you are developing

Thank you











Oct 25, 2012 at 10:50 AM

hey gianni,
thank you :-)

did you copy the example code to the source code?
as far i know the source code project settings is 'sign assemblies=false' in[RC]
if you want to use the source then sign the projects, the keyfile are available in KeyFiles folder.
the core api (NetOffice.dll) try to resolve the NetOffice assemblies at runtime and use the signed PublicKeyTokens as identifier.