0

I have created a C# code where I'll input a code to it and it returns me an encrypted entry pass code. Its all working perfectly. Now the question is that, I want to apply this code to every application I create so that only after getting the pass code, the application should run. As far as I know, I now insert that C# code file to that application and everytime am linking that code files.

For a C# application its fine, but when I create application using VB.NET, I am forced to convert the code file written in C# to VB everytime. I have heard about DLL and class files. But I am not sure how to apply this further.

Help is wanted for me as to how:

  • I should create DLL (or class) file out that C# Code file
  • How I should send and retrieve the values from that file
  • How should I make it available for both C# and VB application.

Thanks for your time.

2
Contributors
3
Replies
9
Views
3 Years
Discussion Span
Last Post by hericles
1

To build a dll, type this from the command line
csc /target:library /out:<dll_name>.dll <list of .cs files to make up dll>

After that just add the dll to your upcoming projects

0

can I return and pass the value exactly as I did with the c# code file before?

1

Without knowing exactly how you code works, maybe...
The methods of a dll become available to your code once it is added but if it requires things like displaying text then there is an visual element that needs to be taken into account.

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.