Jump to content

Few lines of AutoIt to dll!


Recommended Posts

I need to transfer this to a .dll

Func GetUUID()
    $Cereal = DriveGetSerial(@HomeDrive)
    $Computer = @ComputerName
    $UUID = StringTrimLeft(StringToBinary(_nCrypt($Cereal & "ÿ" & $Computer, @UserName)), 2)
    Return $UUID
EndFunc

Func SendUUID($UUID)
    $Ret = StringSplit(_nCrypt(BinaryToString("0x" & $UUID), @UserName), "ÿ")
    If @error Then Return -1;Invalid UUID
    If $Ret[1] == DriveGetSerial(@HomeDrive) And $Ret[2] == @ComputerName Then Return 1
    Return 0
EndFunc

The _nCrypt can be any .dll cryptography. It just needs to be encrypted!

Link to comment
Share on other sites

Most likely you could just make your script accept command line parameters, than have the program in need of the functions call the compiled script with the correct command line parameters.

Search command line in the help documentation for AutoIt to see how to handle command line parameters.

Looking at what functions you are trying to use though, I would recommend learning how to do them in C++, as they aren't very complex.

_________[u]UDFs[/u]_________-Mouse UDF-Math UDF-Misc Constants-Uninstaller Shell

Link to comment
Share on other sites

Most likely you could just make your script accept command line parameters, than have the program in need of the functions call the compiled script with the correct command line parameters.

Search command line in the help documentation for AutoIt to see how to handle command line parameters.

Looking at what functions you are trying to use though, I would recommend learning how to do them in C++, as they aren't very complex.

That may work yes, but I want to use this .dll in a C++ program I am writing.
Link to comment
Share on other sites

That may work yes, but I want to use this .dll in a C++ program I am writing.

Does that mean we should understand your real question to be "How do I write a dll in C++?"?
Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script.
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...