I want to map the action of the button and in Tab Action I select Pascal scripting. I try to write the following code but without any success.
uses Process;
var
RunProgram: TProcess;
begin
RunProgram := TProcess.Create(nil);
RunProgram.CommandLine := ‘calc.exe’;
RunProgram.Execute;
RunProgram.Free;
end;
If someone can help me please. It is urgent!
Problem with Pascal script
- chessware
- Site Admin
- Posts: 384
- Joined: Sat Jun 22, 2013 11:26 am
- Contact:
Re: Problem with Pascal script
Use a "Execute a program" command instead.
-
- Posts: 3
- Joined: Fri Jan 15, 2021 12:05 pm
Re: Problem with Pascal script
It was my first idea. I wrote calc.exe for example. I want to open the special software and than to perform a series of operations (which I can do only with some script). But my idea was to integrate the script to the keyboard which I preparing now. I am not so friendly with pascal that's why I need help. If there is some way to use some other programing languages write me some base instructions
So If you can share me some idea In this line of thought I will be very grateful. (I am sure you are the master of this software)
So If you can share me some idea In this line of thought I will be very grateful. (I am sure you are the master of this software)
- chessware
- Site Admin
- Posts: 384
- Joined: Sat Jun 22, 2013 11:26 am
- Contact:
Re: Problem with Pascal script
You can write a DLL with the language of your choice.
Then copy that DLL to the Touch-It folder and call exported procedures from Pascal scipting.
Remember that you need a 64 bit DLL on 64 bit plateform.
Then copy that DLL to the Touch-It folder and call exported procedures from Pascal scipting.
Remember that you need a 64 bit DLL on 64 bit plateform.
-
- Posts: 3
- Joined: Fri Jan 15, 2021 12:05 pm
Re: Problem with Pascal script
I try all day without any results . The dll is in the correct folder the code is like yours but nothing. You will see in attachment the dll file and the picture of my last try. Could you try with my dll file. The code inside of the dll is similar like in my first post just to open calculator.
Public Function Sayhello()
System.Diagnostics.Process.Start("calc.exe")
End Function
Public Function Sayhello()
System.Diagnostics.Process.Start("calc.exe")
End Function
- Attachments
-
- DIMDLL.zip
- (1.35 KiB) Downloaded 23 times
- chessware
- Site Admin
- Posts: 384
- Joined: Sat Jun 22, 2013 11:26 am
- Contact:
Re: Problem with Pascal script
Your dll is 32 bit. It will only works on 32 bit platform. You must comply with Touch-It which is either 32 or 64 bit based on the platform.
Your dll does not provide any entry point. MyFunc and MyProc are not available.
Your dll must be located in the Touch-It app folder (C:\Program Files\Chessware\Touch-It), not the data folder (we will change this in the next release).
Your dll does not provide any entry point. MyFunc and MyProc are not available.
Your dll must be located in the Touch-It app folder (C:\Program Files\Chessware\Touch-It), not the data folder (we will change this in the next release).
Return to “Problems and solutions”
Who is online
Users browsing this forum: No registered users and 1 guest