How can I define a variable inside my rollout?

Hi,

Can I define a variable inside a rollout?

I want my edittext deafault text store as a variable.

This is piece of my code:

try(destroyDialog PI_JobSubmissionTool)catch()
 
rollout PI_JobSubmissionTool "PI_JobSubmissionTool" width:350 height:160
(
	edittext _defJobName "Job Name:" width:300 height:20 pos:[10,50] text:"enter job name here..."
	oldString = _defJobName.text
) 
createdialog PI_JobSubmissionTool 

Comments

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
miauu's picture

.

use the word LOCAL

try(destroyDialog PI_JobSubmissionTool)catch()
 
rollout PI_JobSubmissionTool "PI_JobSubmissionTool" width:350 height:160
(
local etVal = "enter job name here..."
	edittext _defJobName "Job Name:" width:300 height:20 pos:[10,50] text:"enter job name here..."
	local oldString = _defJobName.text
) 
createdialog PI_JobSubmissionTool

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.