I know how to launch another application using ‘folderitem.launch’ but want to manipulate the fields also. Like if the launched application have a textfield, i want to assign a text from the calling app. Is that possible?
the launching part can also be done from cmd or bat but manipulation of launched app so far i can not do. Thanks in advance
Yes it can be done with Api Calls. SetText, FindWindow, etc.
There are lots of examples in the forum, also in the windows functionality suite
thanks @Pedro Ivan Tellez Corella .Will look in to the WIN API . Thanks.
try passing through a command line when invoking -
dim target as folderitem = [application to start]
dim com_line as string = “–change-textfield1=This can update the textfield”
#if targetWin32
target.launch com_line
#elseif targetMacOS
dim s as new shell
s.mode=0
s.execute target.shellpath+" “+com_line+” >/dev/null 2>&1 &"
#endif
Then in the application you are invoking you can detect if “–change-textfield1” command is used in system.commandline, and assign where needed
[quote=418504:@Connor Blackler]try passing through a command line when invoking -
…
Then in the application you are invoking you can detect if “–change-textfield1” command is used in system.commandline, and assign where needed[/quote]
This is too limited, it will work ONLY if the target app is a xojo app AND if he has the source code AND if it only need change the content a single time.
If it is a third party app, Windows Api calls, if is another xojo app that you have the source code and can recompile, is better to use a IPCSocket to make “interprocess communication between two applications on the same computer”