White76 Posted October 2, 2009 Share Posted October 2, 2009 There is some problem - I want to create my DLL with math functions inside, and to call some "*.dll" from script using Dllcall or pluginopen. My questions to г is - How to write DLL, using AutoIT ??? - Is it real to write any script , compile and rename to DLL ??? ( only Func-Endfunc of math functions in script).... I dont use any programm-languages and want to create my Lib to use in my scripts. I know about #include directive - i need a portable DLL file May be, anybody know who can explain me solution of my idea. (russioned-broaken english ))) Link to comment Share on other sites More sharing options...
Inverted Posted October 2, 2009 Share Posted October 2, 2009 Wrong section ? Anyway, you can't create a dll with autoit. (and renaming stuff doesn't help lol !) You could compile some scripts with your functions which you can call with some parameters, and then check the returns. You could also create one compiled script which does all your functions and run it like for example : mainscript.exe /function_number /parameter1 /parameter2 and check its return. Link to comment Share on other sites More sharing options...
White76 Posted October 2, 2009 Author Share Posted October 2, 2009 oh! thanks! I inderstand what operator $var=run("script.exe /number /value1 /value2") can run from BAT file or command Line ??? $var will be the value of function ? then another question - mainscript.exe /function_number /parameter1 /parameter2 <= number function in script ??? Thanks Again! Link to comment Share on other sites More sharing options...
White76 Posted October 2, 2009 Author Share Posted October 2, 2009 OK, I did script 1 (as DLL) func dll($a) Return 2*$a EndFunc Script 2 $a=run("dll.exe /1 /2") MsgBox(0,"",$a) Msgbox is always different .... Where a mistake ??? Link to comment Share on other sites More sharing options...
Zisly Posted October 2, 2009 Share Posted October 2, 2009 I made this quick, there are probably a lot better ways xD If you decide to work with this don't forget adding error checking and all that. "dll" call($CmdLine[1]) Func _MsgBox() MsgBox($CmdLine[2],$CmdLine[3],$CmdLine[4]) EndFunc example _call('test.exe', '_MsgBox', 4, 'yes?', 'text') Func _call($sProg, $sFunc, $p1 = "", $p2 = "", $p3 = "") ; lol ShellExecute($sProg, $sFunc&' '&$p1&' '&$p2&' '&$p3) EndFunc Link to comment Share on other sites More sharing options...
White76 Posted October 2, 2009 Author Share Posted October 2, 2009 (edited) I understood the little part of your code xD CALL can not by use ByRef, and var $CMDline is What ??? SHELLEXECUTE dont return the value of my func, only 1 if all right. PLEASE DONT USE DIFFICULT WORD - MY ENGLISH IS RUSSIAN xD . rewriting my question : I want to write my DLL or analogical file with mathFunctions, using Autoit, and to get the value of func in program from this external file.....so.... How to get this values??? Edited October 2, 2009 by White76 Link to comment Share on other sites More sharing options...
AdmiralAlkex Posted October 2, 2009 Share Posted October 2, 2009 Maybe you should try the Russian community? They will probably understand you better.http://autoit-script.ru/ .Some of my scripts: ShiftER, Codec-Control, Resolution switcher for HTC ShiftSome of my UDFs: SDL UDF, SetDefaultDllDirectories, Converting GDI+ Bitmap/Image to SDL Surface Link to comment Share on other sites More sharing options...
White76 Posted October 5, 2009 Author Share Posted October 5, 2009 Maybe you should try the Russian community? They will probably understand you better.http://autoit-script.ru/Oh,Thanks! I'll create EXE and its function will depend of $CMDline... Link to comment Share on other sites More sharing options...
Inverted Posted October 5, 2009 Share Posted October 5, 2009 Oh,Thanks! I'll create EXE and its function will depend of $CMDline...Exactly, you'll pass the number of the function and any function parameters through the command line parameters Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now