cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
james_decosta
Level 9

Is this a bug in the installanywhere ,its really interesting

hi,
i have a problem while executing custom code wherein i gave a class name and then i specified the jar file within which it can be found out.
But due to unprecedented circumstances,i had to change the class,
Now i made the changes and then i specified the jar file wherein i can find the
class, i made the changes in the class but they did not get reflected in the panel where i am calling the custom code.
Again for experimenting i changed the name of the class and again gave the name of the jar file and the class name.
To my surprise now it worked fine.
(GIST) The installer caches the classes somewhere i believe so that when i make the changes in the class they are not reflected.
james
Labels (1)
0 Kudos
(7) Replies
pv7721
Level 20

It might be sound as a very stupid question to you, but after having modified your custom code and jar file, have you rebuilt your installer?
0 Kudos
james_decosta
Level 9

hi,
i have cleared the jar file name,put the new jar file name and then i saved it and rebuilt it .But then my problem what to do nowhere to go.
james.
0 Kudos
james_decosta
Level 9

hi,
can anyone say where i am going wrong or else this is some problem with the installer

Please try it out.
Write down some sample custom code rule class and write something in it,make a jar of it and add it to a dialog,
Again modify the class(please dont change the class name) and make a jar of it and add it to the dialog box.
To your surprise you will find that the changes will not be reflected.
Any suggestions are eagerly awaited.
james.
0 Kudos
james_decosta
Level 9

hi,
till now i have seen that i am unable to crack this jinx.
Is there anyone who is able to crack this bug(i believe)
james.
0 Kudos
purcellk24
Level 7

I modify custom actions and re-create the jar file all the time and changes are always reflected. Check your custom action, your jar file (and the finished contents) and the installer to make sure you are loading the correct jar.

Another thing that I have found, you aren't using the same package.classname from a different jar in the same installer are you? IA doesn't like that.
0 Kudos
james_decosta
Level 9

hi,
i was using com.xxx.installer.OriginalClass
tHEN i did some modifications and i found out i gave the same package name and class name,but they were not reflected.
I will try to reproduce this problem
james.
0 Kudos
james_decosta
Level 9

hi,
unzip them and run the installlers and see if you can cross the get user input panel.
CUSTOM CODE RULE ADDED ON MESSAGE IN BEFOREMODIFICATION(INSTALLER.EXE)

package com.sample.source;

import com.zerog.ia.api.pub.CustomCodeRule;

public class SampleCustomRule extends CustomCodeRule {

@Override
public boolean evaluateRule() {
String james_first=ruleProxy.substitute("$JAMES_ONE$");
String james_second=ruleProxy.substitute("$JAMES_TWO$");
String james_third=ruleProxy.substitute("$JAMES_THREE$");
String james_four=ruleProxy.substitute("$JAMES_FOUR$");
String james_five=ruleProxy.substitute("$NULL$");
String valueToRefer=ruleProxy.substitute("$NULL$");
if(james_first.equalsIgnoreCase(valueToRefer)||james_second.equalsIgnoreCase(valueToRefer)||james_third.equalsIgnoreCase(valueToRefer)||james_four.equalsIgnoreCase(valueToRefer)||james_five.equalsIgnoreCase(valueToRefer)){
return true;
}
else{
return false;
}
}

}

CUSTOM CODE RULE IN AFTERMODIFICATION(INSTALLER.EXE)

package com.sample.source;

import com.zerog.ia.api.pub.CustomCodeRule;

public class SampleCustomRule extends CustomCodeRule {

@Override
public boolean evaluateRule() {
String james_first=ruleProxy.substitute("$JAMES_ONE$");
String james_second=ruleProxy.substitute("$JAMES_TWO$");
String james_third=ruleProxy.substitute("$JAMES_THREE$");
String james_four=ruleProxy.substitute("$JAMES_FOUR$");
String james_five=ruleProxy.substitute("$JAMES_FIVE$");
String valueToRefer=ruleProxy.substitute("$NULL$");
if(james_first.equalsIgnoreCase(valueToRefer)||james_second.equalsIgnoreCase(valueToRefer)||james_third.equalsIgnoreCase(valueToRefer)||james_four.equalsIgnoreCase(valueToRefer)||james_five.equalsIgnoreCase(valueToRefer)){
return true;
}
else{
return false;
}
}

}
0 Kudos