Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
CODE PROJECT For Those Who Code
  • Home
  • Articles
  • FAQ
Community
  1. Home
  2. General Programming
  3. .NET (Core and Framework)
  4. Security problem with Word 2007 add-in

Security problem with Word 2007 add-in

Scheduled Pinned Locked Moved .NET (Core and Framework)
helpcsharpdotnetsecurityquestion
1 Posts 1 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • E Offline
    E Offline
    Eagle_Wizard
    wrote on last edited by
    #1

    In the add-in itself I use reflection. An other programmer can give me a DLL file with actions (functions) and with the class, namespace and the path of the DLL I can use these functions in my add-in. I tested everything in a windows application and it worked perfect. After that I tried to use the same code in my Word add-in but I got a Security error. Here is the code where I had the problem: Assembly ass = Assembly.LoadFile(this.FilePath); if (ass == null) return; //compilatie liep wellicht verkeerd System.Type T = ass.GetType(this.Namespace + "." + this.Class); object o = System.Activator.CreateInstance(T); T.InvokeMember(this.Method, System.Reflection.BindingFlags.InvokeMethod, null, o, new object[] { (object)dicArgs, (object)sConfig }); The program gave a securityerror on the InvokeMember method. Probably I have to register the used dll somewhere in the .NET Framework 2.0. Can anybody help me fix this?

    Programming code is like magic, just use the right code (magic words) to make happen what you want..

    1 Reply Last reply
    0
    Reply
    • Reply as topic
    Log in to reply
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes


    • Login

    • Don't have an account? Register

    • Login or register to search.
    • First post
      Last post
    0
    • Categories
    • Recent
    • Tags
    • Popular
    • World
    • Users
    • Groups