It's my code ,ok?

205 views
Skip to first unread message

maybeg...@gmail.com

unread,
Feb 9, 2014, 10:11:45 AM2/9/14
to suppor...@runmyprocess.com
Hi
I want to create a pre launch script but it's not working(doesn't launch the start process), this is my code:

///
if ( variable_from_footer == 100){

true;

} else{

alert(“something is wrong”);

false;
}
///
I mean, I don't know if I can just take the variable from the footer, and putting it into an submit pre launch script(Do I need to parse it?).
I did a javascript to sum numbers introduced into an array widget(and it works, when showing the result in the footer).

I followed this: http://docs.runmyprocess.com/Developer_Guide/Web_Interface/Design/Summing_Array

Thanks!

Richard Manga

unread,
Feb 9, 2014, 10:20:40 AM2/9/14
to suppor...@runmyprocess.com
Good morning,

Your logic is good. But, to access the footer variable, you can use the following code: 

if(parseInt(RMPApplication.get("your_footer_variable"))==100){

true;

} else{

alert(“something is wrong”);

false;
}

Best regards,

Richard Manga



--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to the Google Groups "RunMyProcess Support Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at http://groups.google.com/a/runmyprocess.com/group/supportforum/.
To view this discussion on the web visit https://groups.google.com/a/runmyprocess.com/d/msgid/supportforum/f029a4a5-76bc-411d-af39-1f4154956161%40runmyprocess.com.
For more options, visit https://groups.google.com/a/runmyprocess.com/groups/opt_out.

maybeg...@gmail.com

unread,
Feb 9, 2014, 11:47:41 AM2/9/14
to suppor...@runmyprocess.com, maybeg...@gmail.com
Hi
The submit button doesn't work, I don't know if the javascript I did , it's the problem.

The javascript function I made for sum in an array widget:

//
var total_porcentaje = [[array_p.porcentaje]][P_index];

id_array_p.id_porcentaje[P_index].setText("" + total_porcentaje);
id_array_p.id_porcentaje[P_index].setActive(true);
//
I created another column(type javascript) to put this code in the array widget.
and in the footer configuration interface(from other column) I checked "sum" in the type field.

Do you know which could be the problem? or Did I make myself understand?

Thanks in advance.

att:
nes

Richard Manga

unread,
Feb 9, 2014, 1:11:20 PM2/9/14
to suppor...@runmyprocess.com, maybeg...@gmail.com
Good morning,

You don't need to write a function to make a sum in array column.

You should use the sum function of your footer column. Using this function, you will have a variable containing this sum on

the properties of your footer.

So, I suggest you to use this variable in your pre-launch script.

Best regards,

Richard Manga.


--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to the Google Groups "RunMyProcess Support Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at http://groups.google.com/a/runmyprocess.com/group/supportforum/.

maybeg...@gmail.com

unread,
Feb 9, 2014, 2:44:34 PM2/9/14
to suppor...@runmyprocess.com, maybeg...@gmail.com
Thanks for your answer, Mister Richard.

I see. The sum works fine and I deleted that unnecessary function.

The submit button still doesn't work.
I used the code you teached me, in the pre launch script:
//
if(parseInt(RMPApplication.get("footerporcen")) == 100){

true;

} else{

alert(“something is wrong”);

false;
}
//

"footerporcen" it's the variable name of my footer.

I don't know if is there any restriction on using a variable from an array widget, in a pre launch script.

Richard Manga

unread,
Feb 10, 2014, 4:16:38 AM2/10/14
to suppor...@runmyprocess.com, maybeg...@gmail.com
Good morning,

In fact,you can access the variable used for the sum (footer variable) in your prelaunch script as I said before.

Can you give me an overview of the process you are trying to start with this prelaunch script?

Best regards, 

Richard Manga.


--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to the Google Groups "RunMyProcess Support Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at http://groups.google.com/a/runmyprocess.com/group/supportforum/.

maybeg...@gmail.com

unread,
Feb 10, 2014, 12:15:37 PM2/10/14
to suppor...@runmyprocess.com, maybeg...@gmail.com


Hi Richard, thanks for the answer.

The pre-launch script is from a submit button on the launch interface.
and I need to continue to the next process.

The sum is computed in an array widget (of course), but I don´t know why I can't just use the variable in the footer, I don't know if the syntax on the above code is wrong.

I appreciate it.

Richard Manga

unread,
Feb 10, 2014, 12:31:03 PM2/10/14
to suppor...@runmyprocess.com, Nesgeek Cepeda
Good morning,

Please can you give me more details about what happens when you click on submit button?

Do you execute always the "else" condition or you have some error message?

If you have some error message, I suggest you to copy your JS code and to test it in the console in your web interface.

Best regards,

Richard Manga.


--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to the Google Groups "RunMyProcess Support Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at http://groups.google.com/a/runmyprocess.com/group/supportforum/.

maybeg...@gmail.com

unread,
Feb 10, 2014, 3:21:33 PM2/10/14
to suppor...@runmyprocess.com, maybeg...@gmail.com
Hi Richard.


When I click on "SUBMIT" button to continue with the next process, it doesn't show anything, I think "else" neither works. How I said to you, I just named the footer, and I used this variable inside the pre launch script, with the code you gave me.

It should work fine with the code(But I don't know why it doesn't):
//
if(parseInt(RMPApplication.get("My_footer_variable")) == 100){

true;

} else{

alert(“something is wrong”);

false;
}
//

or I need to call other variable? instead of the variable of the "footer"
Thanks in advance, I really appreciate your help.

Richard Manga

unread,
Feb 11, 2014, 3:32:44 AM2/11/14
to suppor...@runmyprocess.com
Good morning,

Please, can you send me a screenshot of your process and a screenshot of the configuration of your footer?

Best regards,

Richard Manga.




--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to the Google Groups "RunMyProcess Support Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at http://groups.google.com/a/runmyprocess.com/group/supportforum/.

maybeg...@gmail.com

unread,
Feb 11, 2014, 2:18:19 PM2/11/14
to suppor...@runmyprocess.com, maybeg...@gmail.com
Hi, Richard.


I attached the respective screenshots.


Thank you very much.

Att:
Nes

Process.PNG
launch interface.PNG
Footer configuration.PNG
the prelaunch script.PNG

maybeg...@gmail.com

unread,
Feb 11, 2014, 10:46:14 PM2/11/14
to suppor...@runmyprocess.com, maybeg...@gmail.com
if not too much trouble, Could you explain me how exactly would you do it?

Sorry to ask you this, but I really don't know what is happening.

thoshino

unread,
Feb 12, 2014, 12:36:02 AM2/12/14
to suppor...@runmyprocess.com, maybeg...@gmail.com
Hi,

I can guide you to debug your code.
When you open your web interface in TEST mode, you will have a "tester" at the top of page.
Please see attached.
You can write your code here to see how it behaves.

For example, type in values into the web interface so that the footer is equal to 100 (you can see this value, right?).
Then when you write
RMPApplication.get("foot");
in the tester and click on Run javascript, it should display 100.
If this is not the case, then you can guess that this is where your prelaunch script is stuck at.

You can also try this:
parseInt(RMPApplication.get("foot"))

If above looks okay, then you can try this:
parseInt(RMPApplication.get("foot")) == 100;

This should display
true

Then you can also try putting the whole prelaunch script there too.
if (parseInt(RMPApplication.get("foot"))==100){
true;
}else{
alert("not okay");
}

It should return
true
if the footer is 100. If not, the alert message should appear.

I hope this helps you discover the cause of your error.

Best regards,

Taka
javascript-debug.png

maybeg...@gmail.com

unread,
Feb 12, 2014, 11:01:09 AM2/12/14
to suppor...@runmyprocess.com, maybeg...@gmail.com
It works!!!

The issue I think was about a simple syntax error in my code, yes I know it can be too obvious but I needed to be sure.

Thanks a lot for your help!!!
Next time, I'll test in the console test section.

I'm much obliged.


att:
Nes

ii2team...@gmail.com

unread,
Nov 4, 2014, 5:14:27 AM11/4/14
to suppor...@runmyprocess.com, maybeg...@gmail.com
could you please explain what is actually in "debug mode for an application" in RMP life cycle guide?


Fabien Tabary

unread,
Nov 7, 2014, 3:13:27 AM11/7/14
to suppor...@runmyprocess.com
Hi,
Many informations about the debug mode are available on our documentation. If you have any question do not hesitate to contact us.

Best regards / Cordialement

--

Fabien Tabary

PreSales Consultant

     

Fujitsu RunMyProcess user? Please add a review on GoogleApps Marketplace

Afin de contribuer au respect de l'environnement, merci de n'imprimer ce message qu'en cas de nécessité.
Be environmentally friendly: do not print this email unless it is entirely necessary.

On Tue, Nov 4, 2014 at 11:14 AM, <ii2team...@gmail.com> wrote:
could you please explain what is actually in "debug mode for an application" in RMP life cycle guide?
--
Fujitsu - RunMyProcess
---
You received this message because you are subscribed to the Google Groups "RunMyProcess Support Forum" group.
To unsubscribe from this group and stop receiving emails from it, send an email to supportforum...@runmyprocess.com.
To post to this group, send email to suppor...@runmyprocess.com.
Visit this group at http://groups.google.com/a/runmyprocess.com/group/supportforum/.
Reply all
Reply to author
Forward
0 new messages