This website uses cookies. By clicking Accept, you consent to the use of cookies. Click Here to learn more about how we use cookies.
Turn on suggestions
Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.
- Revenera Community
- :
- InstallAnywhere
- :
- InstallAnywhere Forum
- :
- this is the code but it does not work
Subscribe
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Subscribe
- Mute
- Printer Friendly Page
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Apr 13, 2008
02:16 AM
this is the code but it does not work
hi,
How should i use getResource(),i am including a file got valuetouse.txt in the installer and then in the pre install custom code action class i am using it in the public void install (method)
public void install(InstallerProxy ip) throws InstallException {
// TODO Auto-generated method stub
URL somepath=ip.getResource("/valuetouse.txt");
String forManipulation=somepath.toString();
System.out.println(forManipulation);
ip.setVariable("$SOMETHING$",forManipulation);
}
What is the correct way for passing valuetouse.txt in the installer??????????
Where am i going wrong
the code is like this:
/**
*
*/
package com.installanywhere.exper;
import java.net.URL;
import com.zerog.ia.api.pub.CustomCodeAction;
import com.zerog.ia.api.pub.InstallException;
import com.zerog.ia.api.pub.InstallerProxy;
import com.zerog.ia.api.pub.UninstallerProxy;
/**
* @author james
*
*/
public class SampleCustomCodeAction extends CustomCodeAction {
/* (non-Javadoc)
* @see com.zerog.ia.api.pub.CustomCodeAction#getInstallStatusMessage()
*/
@Override
public String getInstallStatusMessage() {
// TODO Auto-generated method stub
return null;
}
/* (non-Javadoc)
* @see com.zerog.ia.api.pub.CustomCodeAction#getUninstallStatusMessage()
*/
@Override
public String getUninstallStatusMessage() {
// TODO Auto-generated method stub
return null;
}
/* (non-Javadoc)
* @see com.zerog.ia.api.pub.CustomCodeAction#install(com.zerog.ia.api.pub.InstallerProxy)
*/
@Override
public void install(InstallerProxy ip) throws InstallException {
// TODO Auto-generated method stub
URL somepath=ip.getResource("/valuetouse.txt");
String forManipulation=somepath.toString();
System.out.println(forManipulation);
ip.setVariable("$SOMETHING$",forManipulation);
}
/* (non-Javadoc)
* @see com.zerog.ia.api.pub.CustomCodeAction#uninstall(com.zerog.ia.api.pub.UninstallerProxy)
*/
@Override
public void uninstall(UninstallerProxy arg0) throws InstallException {
// TODO Auto-generated method stub
}
}
But when i used it ,i got the value as null when i checked for $SOMETHING$
How should i use getResource(),i am including a file got valuetouse.txt in the installer and then in the pre install custom code action class i am using it in the public void install (method)
public void install(InstallerProxy ip) throws InstallException {
// TODO Auto-generated method stub
URL somepath=ip.getResource("/valuetouse.txt");
String forManipulation=somepath.toString();
System.out.println(forManipulation);
ip.setVariable("$SOMETHING$",forManipulation);
}
What is the correct way for passing valuetouse.txt in the installer??????????
Where am i going wrong
the code is like this:
/**
*
*/
package com.installanywhere.exper;
import java.net.URL;
import com.zerog.ia.api.pub.CustomCodeAction;
import com.zerog.ia.api.pub.InstallException;
import com.zerog.ia.api.pub.InstallerProxy;
import com.zerog.ia.api.pub.UninstallerProxy;
/**
* @author james
*
*/
public class SampleCustomCodeAction extends CustomCodeAction {
/* (non-Javadoc)
* @see com.zerog.ia.api.pub.CustomCodeAction#getInstallStatusMessage()
*/
@Override
public String getInstallStatusMessage() {
// TODO Auto-generated method stub
return null;
}
/* (non-Javadoc)
* @see com.zerog.ia.api.pub.CustomCodeAction#getUninstallStatusMessage()
*/
@Override
public String getUninstallStatusMessage() {
// TODO Auto-generated method stub
return null;
}
/* (non-Javadoc)
* @see com.zerog.ia.api.pub.CustomCodeAction#install(com.zerog.ia.api.pub.InstallerProxy)
*/
@Override
public void install(InstallerProxy ip) throws InstallException {
// TODO Auto-generated method stub
URL somepath=ip.getResource("/valuetouse.txt");
String forManipulation=somepath.toString();
System.out.println(forManipulation);
ip.setVariable("$SOMETHING$",forManipulation);
}
/* (non-Javadoc)
* @see com.zerog.ia.api.pub.CustomCodeAction#uninstall(com.zerog.ia.api.pub.UninstallerProxy)
*/
@Override
public void uninstall(UninstallerProxy arg0) throws InstallException {
// TODO Auto-generated method stub
}
}
But when i used it ,i got the value as null when i checked for $SOMETHING$
(1) Reply
- Mark as New
- Subscribe
- Mute
- Permalink
- Report Inappropriate Content
Apr 14, 2008
08:08 AM
hi,
i want to know if anyone has tried this one.
james
i want to know if anyone has tried this one.
james
