By-Jokese 3 Posted March 1, 2018 I have a custom dialog, with an edit box and a button. I need to send the text entered by the user to a custom script. What do I have to put in the action parameter for sending that data to the script. Thank you. 1 Share this post Link to post Share on other sites
HazJ 1288 Posted March 1, 2018 https://community.bistudio.com/wiki/ctrlText Example should be on Wiki. Let me know if you get stuck. This will return text in the edit box. 1 Share this post Link to post Share on other sites
By-Jokese 3 Posted March 1, 2018 Thanks! Will try it and see if I have any problems. @HazJ EDIT: is this correct? action = "[ctrlText 100] execVM 'Scripts/script_name.sqf'"; Share this post Link to post Share on other sites
HazJ 1288 Posted March 1, 2018 @By-Jokese action = "[] execVM 'Scripts/script_name.sqf'"; In script_name.sqf disableSerialization; _display = uiNamespace getVariable "something"; // OR _display = findDisplay IDD; _inputText = ctrlText (_display displayCtrl 100); systemChat format [":: %1", _inputText]; I personally don't use action anymore. How I would do it is using ButtonClick EH. https://community.bistudio.com/wiki/User_Interface_Event_Handlers#onButtonClick disableSerialization; _display = findDisplay IDD; (_display displayCtrl 100) ctrlAddEventHandler ["ButtonClick", { params ["_button"]; _inputText = ctrlText (findDisplay IDD displayCtrl _button); systemChat format [":: %1", _inputText]; }]; 1 Share this post Link to post Share on other sites