Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8653415
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T14:32:13+00:00 2026-06-12T14:32:13+00:00

I would like to import a new reference into my Workflow Designer, however I

  • 0

I would like to import a new reference into my Workflow Designer, however I encounter a weird problem.

Here’s my code to import a reference.

var root = GetRootElement();
VisualBasicSettings vbs = VisualBasic.GetSettings(root);
vbs.ImportReferences.Add(new VisualBasicImportReference { Assembly = Assembly.Load("Castle.Core").FullName, Import = "Castle.Core.Configuration.Xml" });

private object GetRootElement()
{
     var modelservice = workflowDesigner.Context.Services.GetService<ModelService>();
     if (modelservice == null)
         return null;
     var rootmodel = modelservice.Root.GetCurrentValue();
     return rootmodel;
}

It works when I load my designer for the first time, the assembly is well added into the hashset ImportReferences then I also see the namespace in the “Imports” panel. But when I call the above method when user picks a dll through a picker dialog, I call the code above, the assembly is also well added to ImportReferences, but the “Imports” panel is not refreshed…

Any ideas ?

Thanks for your help.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T14:32:14+00:00Added an answer on June 12, 2026 at 2:32 pm

    Actually, the namespace is well imported, it was hided in the dropdownlist above.

    Here’s the most simple code to import a namespace.
    http://blogs.msdn.com/b/tilovell/archive/2011/11/02/wf4-adding-vb-namespace-imports-to-your-workflow-programmatically.aspx

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I would like to be able to import TFS tasks / work items into
How can I import a CSV file into a MySQL table? I would like
I am modifying a website on wordpress (codex) and I would like to import
I would like to know what is the best import strategy within django reusable
The following: >>>import struct >>>struct.unpack('!d', ('40d11998e5035288').decode('hex'))[0] >>> >>>17510.3889778429 I would like to be able
I have a game here, and I would like to add event handlers to
I am new to Alfresco (version 4) and I would like to create webscript
I'm using Plone 4.1 and collective.externaleditor. I would like that whenever a new user
I would like to understand better how Gridview works, in particular auto_fit . Here
Would like to parse IPv4 address from exit-addresses . Format of the file: ExitNode

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.