Hi Roger,
i wish you a happy new year.
I have a problem with the AD Integration of the gallery.
Gallery Server Pro is installed on a Server 2008 R2 with IIS 7.5. The Database is running on SQL Server 2008. I've created a application for the application pool with an AD-User. The Application still running under .Net 4.0.30319.
Here a some lines from my web.config:
<membership defaultProvider="AspNetActiveDirectoryMembershipProvider">
<providers>
<clear />
<add name="AspNetActiveDirectoryMembershipProvider" type="System.Web.Security.ActiveDirectoryMembershipProvider, System.Web,Version=
2.0.0.0,Culture=neutral,PublicKeyToken=b03f5f7f11d50a3a" connectionStringName="ADConnection" enableSearchMethods="true"/>
</providers>
</membership>
<connectionStrings>
<add name="ADConnection" connectionString="LDAP://192.168.81.32/OU=User,DC=domain,DC=de"/>
<clear />
<add name="SqlServerDbConnection" connectionString="server=SQLServer.domain.de\SQLServer;uid=;pwd=;Trusted_Connection=yes;database=db_name" />
</connectionStrings>
Is this the right version in the red section or must thie the same which the application pool is running?
After saving the new web.config, i restart the website. When i go to the website, i receive the following error:
Error: The type initializer for 'GalleryServerPro.Web.Pages.GalleryPage' threw an exception.
Error Summary
Url
http://www.perupagos.de/mediathek/default.aspx
Timestamp
02.01.2012 15:15:55
Exception Type
System.TypeInitializationException
Message
The type initializer for 'GalleryServerPro.Web.Pages.GalleryPage' threw an exception.
Source
GalleryServerPro.Web
Target Site
Void .ctor()
Stack Trace
at GalleryServerPro.Web.Pages.GalleryPage..ctor()
at GalleryServerPro.Web.Pages.album..ctor()
at ASP.gs_pages_album_ascx..ctor() in c:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\mediathek\ae8d22c0\e346a959\App_Web_wxisuo5f.5.cs:line 0
at __ASP.FastObjectFactory_app_web_wxisuo5f.Create_ASP_gs_pages_album_ascx() in c:\Windows\Microsoft.NET\Framework64\v4.0.30319\Temporary ASP.NET Files\mediathek\ae8d22c0\e346a959\App_Web_wxisuo5f.11.cs:line 0
at System.Web.UI.TemplateControl.LoadControl(IWebObjectFactory objectFactory, VirtualPath virtualPath, Type t, Object[] parameters)
at System.Web.UI.TemplateControl.LoadControl(VirtualPath virtualPath)
at GalleryServerPro.Web.Gallery.LoadRequestedPage()
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Control.InitRecursive(Control namingContainer)
at System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint)
Inner Ex Type
System.Configuration.ConfigurationErrorsException;
Inner ex #2: System.Configuration.Provider.ProviderException
Inner Ex Message
The connection name 'ADConnection' was not found in the applications configuration or the connection string is empty. (D:\Websites\perupagos1\mediathek\web.config line 59);
Inner ex #2: The connection name 'ADConnection' was not found in the applications configuration or the connection string is empty.
Inner Ex Source
System.Web;
Inner ex #2: System.Web
Inner Ex Target Site
System.Configuration.Provider.ProviderBase InstantiateProvider(System.Configuration.ProviderSettings, System.Type);
Inner ex #2: System.String GetConnectionString(System.String, Boolean)
Inner Ex Stack Trace
at System.Web.Configuration.ProvidersHelper.InstantiateProvider(ProviderSettings providerSettings, Type providerType)
at System.Web.Configuration.ProvidersHelper.InstantiateProviders(ProviderSettingsCollection configProviders, ProviderCollection providers, Type providerType)
at System.Web.Security.Membership.InitializeSettings(Boolean initializeGeneralSettings, RuntimeConfig appConfig, MembershipSection settings)
at System.Web.Security.Membership.Initialize()
at System.Web.Security.Membership.get_Provider()
at GalleryServerPro.Web.Controller.UserController.LoadUser(IUserAccount userToLoad)
at GalleryServerPro.Web.Controller.GalleryController.AddMembershipDataToGallerySettings()
at GalleryServerPro.Web.Controller.GalleryController.InitializeGspApplication() at System.Web.Configuration.ProvidersHelper.InstantiateProvider(ProviderSettings providerSettings, Type providerType)
at System.Web.Configuration.ProvidersHelper.InstantiateProviders(ProviderSettingsCollection configProviders, ProviderCollection providers, Type providerType)
at System.Web.Security.Membership.InitializeSettings(Boolean initializeGeneralSettings, RuntimeConfig appConfig, MembershipSection settings)
at System.Web.Security.Membership.Initialize()
at System.Web.Security.Membership.get_Provider()
at GalleryServerPro.Web.Controller.UserController.LoadUser(IUserAccount userToLoad)
at GalleryServerPro.Web.Controller.GalleryController.AddMembershipDataToGallerySettings()
at GalleryServerPro.Web.Controller.GalleryController.InitializeGspApplication();
Inner ex #2: at System.Web.Security.ActiveDirectoryMembershipProvider.GetConnectionString(String connectionStringName, Boolean appLevel)
at System.Web.Security.ActiveDirectoryMembershipProvider.Initialize(String name, NameValueCollection config)
at System.Web.Configuration.ProvidersHelper.InstantiateProvider(ProviderSettings providerSettings, Type providerType)
App Error ID
-2147483648
Gallery ID
1
HTTP User Agent
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:8.0) Gecko/20100101 Firefox/8.0