what kind of dll, is it API!?.
try DLLImport
using System.Runtime.InteropServices;
-----------
public class Import
{
[DllImport("YourDLL.dll", EntryPoint="Logon", ExactSpelling=false,CallingConvention=CallingConvention.Cdecl)]
public static extern int Logon(string username, string password);
}
---------
Import.Logon(Usr_Name, Usr_Pass);