Provides methods for communicating between current application domain and another application via the parameters. This class cannot be inherited.
public sealed class AppParameters: Object
ObjectAppParameters
// This sample shows how to implement the AppParameters class.
using System;
using System.Diagnostics;
using System.Windows.Forms;
public class MyForm: System.Windows.Forms.Form
{
static void Main()
{
Application.Run( new MyForm() );
}
public MyForm()
{
// Displays the parameters.
Display_external_param("myparam1");
Display_external_param("myparam2");
Display_external_param("myparam3");
}
void Display_external_param( string name )
{
AppDomain app_domain= AppDomain.CurrentDomain;
// value is used to get the AppParameters.
];if( value != null )
Debug.WriteLine( "ExternalParam " +name+ " is " + value);
else
Debug.WriteLine( "ExternalParam " +name+ " has not been defined" );
}
}
/*
<html><body leftmargin=0 topmargin=0>
<!-- saved from url=(0013)about:internet -->
<object
id="swfapp"
width="400"
height="300"
align="CENTER"
codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,22,0"
classid="clsid:D27CDB6E-AE6D-11CF-96B8-444553540000">
<param name="movie" value="bin/Debug/AppParameters.swf"/>
<param name="quality" value="high"/>
<param name="scale" value="noScale"/>
<param name="FlashVars" value="myparam1=abc&myparam2=xyz"/>
<param name="SeamlessTabbing" value="false"/>
<embed
src="bin/Debug/AppParameters.swf"
name="swfapp"
width="400"
height="300"
quality="high"
scale="noScale"
FlashVars=""
SeamlessTabbing="false"
swliveconnect="true"
pluginspage="http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash"
type="application/x-shockwave-flash">
</embed>
</object>
</body></html>
*/
/* The output of the sample.
ExternalParam "myparam1" is "abc"
ExternalParam "myparam2" is "xyz"
ExternalParam "myparam3" has not been defined
/*
Namespace System Flash Library corlib.scl Flash Library Version 2.0.0.2466 Silverlight Library System.Windows.Forms.dll
| © 2003-2007 NETiKA Technologies. All rights reserved. |