Topic
No replies
SystemAdmin
SystemAdmin
2736 Posts
ACCEPTED ANSWER

Pinned topic HACL code requires HOD Applet/code

‏2012-10-15T22:28:51Z |
Hopefully this is an easy one. Does this sample code snippet from Host Access Toolkit v11 require Host On-Demand Toolkit/libraries to run? It is straight out of the sample code. I only have Host Access Toolkit at the moment.

/*****************************************************************************/
/* Licensed Materials - Property of IBM */
/* */
/* 5648-D70 */
/* */
/* (C)Copyright IBM Corp. 2000 All Rights Reserved */
/*****************************************************************************/
import java.util.Properties;
import com.ibm.eNetwork.ECL.*;

public class Sample31 implements ECLAppletInterface
{

/*********************************************************************
* Constructor for ECLSamps
*/
public Sample31()
{
}
/*********************************************************************
* Method called by Host On-Demand when the applet is initialized.
* This method is defined as part of the ECLAppletInterface
*/
public void init(ECLSession s)
{
//--------------------------------------------------------------------
// Cause an 'invalid parameter' error and catch the ECLErr exception.
// Then extract the error number and language-sensitive message text.
//--------------------------------------------------------------------
ECLPS ps = s.GetPS();

try {
ps.SetCursorPos(999,999); // Invalid parameter
}
catch (ECLErr e) {
System.out.println("ECL error caught: message number - " + e.GetMsgNumber());
System.out.println("Message text: " + e.GetMsgText());
}

} // end sample

}