Pass parameters to applet

in the new version 7.4.1 i am trying to pass a parameter to a project in an applet. I can get it to work with the client using

http://localhost:8088/main/system/launch/client/projectname.jnlp?param1=value

i have tried the following with the applet with no luck

http://localhost:8088/main/web/applet/client/projectname?param1=value

Thank you,

Hi Jonathan,

You have discovered the current state of development. You can pass parameters to an applet but you can’t do it in the url. You have to use the technique discussed in this thread.

I did take a look at that post and something must be wrong with the syntax in the thread because i cannot get it to work. using what that post says i used the following code in the html page

<script>
	var attributes = {
		//"codebase":"http://localhost:8088/main/system/launchbin/",
		"archive":"launchclient.jar",
		"code":"com.inductiveautomation.ignition.client.launch.BootstrapApplet",
		"width":"1660",
		"height":"1864"};
	var parameters = {		"classloader_cache":"false",
		"javaws.sr.gateway.addr.0":"localhost:8088:8043/main",
		"javaws.sr.scope":"C",
		"javaws.sr.project":"Sales",
		"javaws.sr.launchts":"1334243571861",
		"javaws.sr.main":"com.inductiveautomation.factorypmi.application.runtime.ClientLaunchHook",
		javaws.launchparams=param1;param2;
		javaws.launchparam.param1=Hello
		javaws.launchparam.param2=38
		};
	deployJava.runApplet(attributes,parameters,'1.5');
</script>

but the page will not load.

if i change the code so it looks more like the rest of the section as follows the parameter is available, but it does not set the client tag.

<script>
	var attributes = {
		//"codebase":"http://localhost:8088/main/system/launchbin/",
		"archive":"launchclient.jar",
		"code":"com.inductiveautomation.ignition.client.launch.BootstrapApplet",
		"width":"1660",
		"height":"1864"};
	var parameters = {		"classloader_cache":"false",
		"javaws.sr.gateway.addr.0":"localhost:8088:8043/main",
		"javaws.sr.scope":"C",
		"javaws.sr.project":"Sales",
		"javaws.sr.launchts":"1334243571861",
		"javaws.sr.main":"com.inductiveautomation.factorypmi.application.runtime.ClientLaunchHook",
		"param1":"Hello",
		"param2":38
		};
	deployJava.runApplet(attributes,parameters,'1.5');
</script>

Your right, It doesn’t set the client tags for an applet. You have to use the Applet.getParameter call that Carl mentions at the end of the thread.

We put the call in the window InterFrameActived event to grab the values and populate the client tags.

thanks. i will do the same.