Profile Picture

Imail Server Express 11.5 Server APi for .Net : Unable to load DLL 'IMailsec.dll': The handle is...

Posted By machsolinc 7 Years Ago
You don't have permission to rate!

Imail Server Express 11.5 Server APi for .Net : Unable to load DLL...

Author
Message
machsolinc
Crazy Posted 7 Years Ago
View Quick Profile
Forum Newbie

Forum Newbie (5 reputation)Forum Newbie (5 reputation)Forum Newbie (5 reputation)Forum Newbie (5 reputation)Forum Newbie (5 reputation)Forum Newbie (5 reputation)Forum Newbie (5 reputation)Forum Newbie (5 reputation)Forum Newbie (5 reputation)

Group: Forum Members
Last Active: 7 Years Ago
Posts: 1, Visits: 4
I am trying to create domain and user in IMAIl express 11.5 using IMAIL Server API for .Net



I am using the following code (trying to create a domain here using sample code from imail installation folder):





Dim DomData As New DomainData()

DomData.Aliases = "TestALias"

DomData.HostName = "TestImailDomain.com"

DomData.TopDir = IMailAPI_NET.IMailSystem.TopDir & "\TestImailDomain.com"

DomData.UserDBType = DomainData.DBTYPES.IMail

DomData.UserDB = "TestUserDB"

DomData.IPAddress = "192.168.1.12"

DomData.IMEnabled = True

DomData.MaxSize = 100

DomData.MaxOutboundSize = 100

DomData.MaxSingleMessageSize = 100

DomData.MaxMsgs = 20

DomData.MaxUsers = 0

DomData.AllowedLoginAttempts = 20

DomData.AllowedLoginLockouts = 10

DomData.DefaultWebReqPwdLevel = 0

DomData.SaveHost(True)





I get the following error (in api logs created by imail):





9/30/2011 - 10:47 AM : Error : IMailAPI_NET.DomainData.SaveHost-2 : Unable to load DLL 'IMailsec.dll': The handle is invalid. (Exception from HRESULT: 0x80070006 (E_HANDLE))







The full log is as below:





9/30/2011 - 10:36 AM : Error : IMailAPI_NET.DomainCollection.DomainCount : Unable to load DLL 'IMailsec.dll': The handle is invalid. (Exception from HRESULT: 0x80070006 (E_HANDLE))

9/30/2011 - 10:36 AM : Error : IMailAPI_NET.DomainCollection.GetDomainCollection : Unable to load DLL 'IMailsec.dll': The handle is invalid. (Exception from HRESULT: 0x80070006 (E_HANDLE))

9/30/2011 - 10:36 AM : Error : IMailAPI_NET.DomainCollection.DomainCount : Unable to load DLL 'IMailsec.dll': The handle is invalid. (Exception from HRESULT: 0x80070006 (E_HANDLE))

9/30/2011 - 10:36 AM : Error : IMailAPI_NET.DomainData.SaveHost-2 : Unable to load DLL 'IMailsec.dll': The handle is invalid. (Exception from HRESULT: 0x80070006 (E_HANDLE))

9/30/2011 - 10:37 AM : Error : IMailAPI_NET.DomainCollection.DomainCount : Unable to load DLL 'IMailsec.dll': The handle is invalid. (Exception from HRESULT: 0x80070006 (E_HANDLE))

9/30/2011 - 10:37 AM : Error : IMailAPI_NET.DomainCollection.GetDomainCollection : Unable to load DLL 'IMailsec.dll': The handle is invalid. (Exception from HRESULT: 0x80070006 (E_HANDLE))

9/30/2011 - 10:37 AM : Error : IMailAPI_NET.DomainCollection.DomainCount : Unable to load DLL 'IMailsec.dll': The handle is invalid. (Exception from HRESULT: 0x80070006 (E_HANDLE))

9/30/2011 - 10:40 AM : Error : IMailAPI_NET.LDAPService.Start-2 : Time out has expired and the operation has not been completed.

9/30/2011 - 10:46 AM : Error : IMailAPI_NET.DomainCollection.DomainCount : Unable to load DLL 'IMailsec.dll': The handle is invalid. (Exception from HRESULT: 0x80070006 (E_HANDLE))

9/30/2011 - 10:46 AM : Error : IMailAPI_NET.DomainCollection.GetDomainCollection : Unable to load DLL 'IMailsec.dll': The handle is invalid. (Exception from HRESULT: 0x80070006 (E_HANDLE))

9/30/2011 - 10:46 AM : Error : IMailAPI_NET.DomainCollection.DomainCount : Unable to load DLL 'IMailsec.dll': The handle is invalid. (Exception from HRESULT: 0x80070006 (E_HANDLE))

9/30/2011 - 10:47 AM : Error : IMailAPI_NET.DomainData.SaveHost-2 : Unable to load DLL 'IMailsec.dll': The handle is invalid. (Exception from HRESULT: 0x80070006 (E_HANDLE))




Edited
7 Years Ago by machsolinc
Brandon Felger
Posted 7 Years Ago
View Quick Profile
Time Traveler

Time Traveler (161 reputation)Time Traveler (161 reputation)Time Traveler (161 reputation)Time Traveler (161 reputation)Time Traveler (161 reputation)Time Traveler (161 reputation)Time Traveler (161 reputation)Time Traveler (161 reputation)Time Traveler (161 reputation)

Group: Moderators
Last Active: 6 Years Ago
Posts: 145, Visits: 49
Likely as not, you added IMailAPI_NET.dll as a project dependency, but Visual Studio is not copying over IMailAPI_NET.dll's dependencies.



I would recommend copying the following files from IMail into your project's binary directory: imailsec.dll, mailbox.dll and IpswitchLicense.dll.




Brandon Felger

IMail Developer

Ipswitch


Similar Topics


Reading This Topic