![MACROMEDIA Flash Lite 2 Скачать руководство пользователя страница 232](http://html1.mh-extra.com/html/macromedia/flash-lite-2/flash-lite-2_reference_687553232.webp)
232
ActionScript language elements
GetNetworkConnectStatus fscommand2 Command
GetNetworkConnectStatus
Returns a value that indicates the current network connection status.
Availability:
ActionScript 1.0; Flash Lite 1.1
Example
The following example assigns the network connection status to the
connectstatus
variable,
and then uses a
switch
statement to update a text field with the status of the connection:
connectstatus = FSCommand2("GetNetworkConnectStatus");
switch (connectstatus) {
connectstatus = FSCommand2("GetNetworkConnectStatus");
switch (connectstatus) {
connectstatus = FSCommand2("GetNetworkConnectStatus");
switch (connectstatus) {
case -1 :
_root.= "connectstatus not supported" + "\n";
break;
case 0 :
_root.= "connectstatus shows active connection" + "\n";
break;
case 1 :
_root.= "connectstatus shows attempting connection" + "\n";
break;
case 2 :
_root.= "connectstatus shows no connection" + "\n";
break;
case 3 :
_root.= "connectstatus shows suspended connection" + "\n";
break;
case 4 :
_root.= "connectstatus shows indeterminable state" + "\n";
break;
}
Command
Parameters
Value Returned
GetNetworkConnectStatus
None
-1
: Not supported.
0
: There is currently
an active network connection.
1
: The
device is attempting to connect to the
network.
2
: There is currently no active
network connection.
3
: The network
connection is suspended.
4
: The network
connection cannot be determined.
Содержание Flash Lite 2
Страница 1: ...Flash Lite 2 x ActionScript Language Reference...
Страница 22: ...22 Contents...
Страница 244: ...244 ActionScript language elements...
Страница 760: ...760 ActionScript classes...