Issues with reading Password filed in Photoshop JavaScript.

New Here ,
Jul 22, 2022 Jul 22, 2022

Copy link to clipboard

Copied

We have an issue with the Photohsop Javascript engine running on MAC, we are using Edittext and noecho property in dailog to read the password in and the standard java script password read mechanisam of calling ".text" is working on windows but failing and giving empty string on MAC. Any suggestions  ? 

 

Below is the snippet :

var dlg = new Window( windowResource);
dlg.group1.name.text = userName;
dlg.group1.password.active = true;
dlg.bottomGroup.applyButton.onClick = function ( ) {

password = dlg.group1.password.text; //  This line is returning empty string.

$.setenv("PW", password);this.parent.parent.close( 2 ); }
dlg.bottomGroup.cancelButton.onClick = function ( ) { cancelled = true; this.parent.parent.close( 2 ); }
dlg.show();

 

windowResource = "dialog {
orientation: 'column',
alignChildren: ['fill', 'top'],
preferredSize:[200, 130],
text: 'Login',
margins:15,

group1: Panel {
orientation: 'row',
alignChildren: 'right',
margins:15,
text: ' Login ',
st: StaticText { text: 'User ID:' },
name: EditText { text: '', characters: 25, justify: 'left'}
st3: StaticText { text: 'Password:' },
password: EditText { text: '', characters: 25, justify: 'left', properties: {noecho:'true'}}
}

bottomGroup: Group{
cancelButton: Button { text: 'Cancel', properties:{name:'cancel'}, size: [120,24], alignment:['right', 'center'] },
applyButton: Button { text: 'Apply', properties:{name:'ok'}, size: [120,24], alignment:['right', 'center'] },
}
}

Views

40

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Community Professional ,
Jul 22, 2022 Jul 22, 2022

Copy link to clipboard

Copied

LATEST

[Moved from Adobe Animate forums]

Likes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines