Use of app.setInterval

Avatar

Avatar
Validate 1
Level 1
robertp92176098
Level 1

Likes

0 likes

Total Posts

3 posts

Correct reply

0 solutions
Top badges earned
Validate 1
View profile

Avatar
Validate 1
Level 1
robertp92176098
Level 1

Likes

0 likes

Total Posts

3 posts

Correct reply

0 solutions
Top badges earned
Validate 1
View profile
robertp92176098
Level 1

03-12-2015

I have a simple save function (autoSav()) in a script object (Skip). The function operates as it should when used from say, the mouse-up event on a button.; it is a trusted function to save the form back on itself.

function autoSav()

{

  var myDoc = event.target;

SavInsp(this, myDoc.path);

}

However, when trying to get the following to work: var timeout = app.setInterval("xfa.form.form1.Insp_Report.Skip.autoSav()", 10000); I get errors indicating Skip is not defined or the function is not defined. I have tried multiple syntax changes w/o a cure.

Any direction would be greatly appreciated.

Accepted Solutions (1)

Accepted Solutions (1)

Avatar

Avatar
Establish
MVP
_Bruce_Robertson
MVP

Likes

271 likes

Total Posts

1,782 posts

Correct reply

372 solutions
Top badges earned
Establish
Give Back 25
Give Back 10
Give Back 5
Give Back 3
View profile

Avatar
Establish
MVP
_Bruce_Robertson
MVP

Likes

271 likes

Total Posts

1,782 posts

Correct reply

372 solutions
Top badges earned
Establish
Give Back 25
Give Back 10
Give Back 5
Give Back 3
View profile
_Bruce_Robertson
MVP

08-12-2015

Hi,

Your code looks ok.  I normally put my script objects at the top level so it would be;

var timeout = app.setInterval("xfa.form.form1.Skip.autoSav()", 10000);

Try this code and see where it's starts going wrong;

var timeout = app.setTimeOut("app.alert(xfa.form.form1.somExpression)", 1000);

var timeout = app.setTimeOut("app.alert(xfa.form.form1.Insp_Report.somExpression)", 1000);

var timeout = app.setTimeOut("app.alert(xfa.form.form1.Insp_Report.Skip.somExpression)", 1000);

Regards

Bruce

Answers (1)

Answers (1)

Avatar

Avatar
Validate 1
Level 1
robertp92176098
Level 1

Likes

0 likes

Total Posts

3 posts

Correct reply

0 solutions
Top badges earned
Validate 1
View profile

Avatar
Validate 1
Level 1
robertp92176098
Level 1

Likes

0 likes

Total Posts

3 posts

Correct reply

0 solutions
Top badges earned
Validate 1
View profile
robertp92176098
Level 1

10-12-2015

Bruce,

Thank you for the insight. I will give it a try.

Skip