Programming, technology, and CRM – from a Belgian programmer exiled to Missouri
  • rss
  • Home
  • Contact Me
  • Welcome

Picklist Bundle Assistant – Now with Integrated Bundler

Nicolas Galler | December 29, 2008

Laziness being what it is I got tired of having to open and save each project separately after my bundle assistant created them and added an option to generate the bundle files directly from the tool.

It’s not perfect but it does what I need (except for a better interface to capture the picklist values – maybe next time).

image

Comments
No Comments »
Categories
Uncategorized
Comments rss Comments rss
Trackback Trackback

Picklist Bundle Assistant

Nicolas Galler | December 26, 2008

Today I finally broke down.  Confronted with the task of creating 15 picklist bundles I decided to (slightly) automate the task with a tool.  It is very simple (does what I need and nothing more) – basically given a list of picklist names (the picklists must already exist) it will create the corresponding projects.

image

I think in the near future I will prepare an improvement to also make it easier to enter the picklist values (right now I use the import feature from the Architect but it still require you to create and set up the picklists one by one) – but that’s for another day.

The code is available on MSDN Code Gallery.

Comments
No Comments »
Categories
Uncategorized
Comments rss Comments rss
Trackback Trackback

Authenticate Users with Active Directory (in ASP.NET 1.1)

Nicolas Galler | December 19, 2008

If you need to authenticate user logins against their Active Directory credentials, integrated authentication is often preferable since it is automatic but it is not always possible.  Given clear text user name and password, how can we do it?

A quick search will turn up a lot of ways:

  • Use the LogonUser API (possibly not recommended as this is really used to impersonate a user, not just validate their login, but it appears if you use LOGON32_LOGON_NETWORK as logon type then it is a valid way to do it)
  • Use the SSPI API – I’ll admit I was not able to go through that document
  • Use an LDAP connection object (with a special OleDb provider)
  • Use an LDAP object (with the GetObject call in VBScript – not sure what the equivalent is in C# though)
  • Use the System.DirectoryServices

Of the above the DirectoryServices is the only one that worked for me on ASP.NET 1.1. 

The authentication procedure looked something like this:

private bool ValidateLogin(String user, String pw)
{
  DirectoryEntry e = new DirectoryEntry("GC://DOMAIN", user, pw, AuthenticationTypes.Secure);
  try {
    if(e.Name != null)
      return true;
  } catch {
    // exception means the logon failed
    return false;
  }
  // should not be reached
  return false;
}

The “GC://DOMAIN” part was the little trick… first I tried “WinNT://DOMAIN/USER” and found out new users were not able to log in.  You can also use a full LDAP query string.

Comments
No Comments »
Categories
Uncategorized
Comments rss Comments rss
Trackback Trackback

Categories

  • Experiments (4)
  • Interesting (1)
  • MSCRM (1)
  • Programming (60)
  • Rant (3)
  • Saleslogix (34)
  • Tricks (8)
  • Uncategorized (24)

Post History

  • 2010
    • January (3)
    • March (1)
  • 2009
    • March (2)
    • April (1)
    • May (3)
    • June (3)
    • July (1)
    • September (3)
    • October (2)
    • December (5)
  • 2008
    • January (9)
    • February (4)
    • March (9)
    • April (1)
    • May (5)
    • June (8)
    • July (1)
    • August (2)
    • September (1)
    • November (1)
    • December (3)
  • 2007
    • January (3)
    • February (7)
    • March (1)
    • April (3)
    • May (6)
    • June (2)
    • July (1)
    • August (2)
    • September (5)
    • October (3)
    • November (5)
    • December (4)
  • 2006
    • January (2)
    • September (1)
    • November (3)
    • December (4)
  • 2005
    • April (1)

Meta

  • Log in
  • Entries RSS
  • Comments RSS
  • WordPress.org
rss Comments rss valid xhtml 1.1 design by jide powered by Wordpress get firefox