net dll (PasswordHashLibrary) to be used in vb6 application. after creating the project, i went to project properties -> build -> Register for COM interop.
Then registered this dll on my machine using regasm command. Started a fresh vb6 project -> added reference to PasswordHashLibrary
Now the vb6 project allows me to write the following
Dim objHash As New PasswordHashLibrary.Hash
- PasswordHashLibrary = namespace
- Hash = Class
But it doesn't let me call any functions inside (class and functions are public)
for instance i have a static function
PasswordHashLibrary.Hash.HashPassword("abc")
It gives compile time error
method or data member not found
When i try to debug and look in object browser there is no member present
My Full .Net Code
namespace PasswordHashLibrary
{
public class Hash
{
private const int PBKDF2IterCount = 1000; // default for Rfc2898DeriveBytes
private const int PBKDF2SubkeyLength = 256 / 8; // 256 bits
private const int SaltSize = 128 / 8; // 128 bits
public static string HashPassword(string password)
{
//my code goes here
}
}
}