org.symbian.tools.wrttools.doc.WebDeveloper/html/GUID-C0ADE739-7F72-4D1D-85FC-631983AAE6D5.html
changeset 229 716254ccbcc0
equal deleted inserted replaced
228:913c9751c067 229:716254ccbcc0
       
     1 
       
     2 <!DOCTYPE html
       
     3   PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
       
     4 <html xmlns="http://www.w3.org/1999/xhtml" lang="en" xml:lang="en"><head><meta http-equiv="Content-Type" content="text/html; charset=utf-8"/><meta name="copyright" content="(C) Copyright 2009"/><meta name="DC.rights.owner" content="(C) Copyright 2009"/><meta name="DC.Type" content="mobileconcept"/><meta name="DC.Title" content="networkregistrationstatus"/><meta name="DC.Relation" scheme="URI" content="GUID-9E8CBB8A-E918-4208-9F11-D2147A98EC4F"/><meta name="DC.Relation" scheme="URI" content="GUID-7C69DDA4-16F1-4A8F-BDB2-4CB0015B4E81"/><meta name="DC.Relation" scheme="URI" content="GUID-65AAF569-D347-462B-B59A-9D7CA184AB9C"/><meta name="DC.Relation" scheme="URI" content="GUID-1A678A11-0BDD-4F64-9F40-013F6CDB81D7"/><meta name="DC.Relation" scheme="URI" content="GUID-92D6E2DB-8BAF-4710-AB23-C16F7DE917CA"/><meta name="DC.Format" content="XHTML"/><meta name="DC.Identifier" content="GUID-C0ADE739-7F72-4D1D-85FC-631983AAE6D5"/><title>networkregistrationstatus </title><script type="text/javascript">
       
     5       function initPage() {}
       
     6     </script><link href="../PRODUCT_PLUGIN/book.css" rel="stylesheet" type="text/css"/><link href="css/s60/style.css" rel="stylesheet" type="text/css" media="all"/></head><body onload="initPage();"><div class="body"><div class="contentLeft prTxt"><h1 class="pageHeading" id="GUID-C0ADE739-7F72-4D1D-85FC-631983AAE6D5">networkregistrationstatus</h1><div>
       
     7 <p><strong>Syntax:</strong></p>
       
     8 <pre class="codeblock" id="GUID-9AA4D224-9A38-463C-8C43-1EDFCE4BED1D">[int] sysinfo.networkregistrationstatus;</pre>
       
     9 <p><strong>Description:</strong></p>
       
    10 <p>The <code>networkregistrationstatus</code> property is an integer indicating the current network registration status.</p>
       
    11 <p>The returned value can be one of the statuses listed in the following table.</p>
       
    12 <div class="tablenoborder"><a name="GUID-A4DC7D36-E4D3-40D8-BB83-9B43382A1EF8"><!----></a><table cellpadding="4" cellspacing="0" summary="" id="GUID-A4DC7D36-E4D3-40D8-BB83-9B43382A1EF8" frame="border" border="1" rules="all"><caption><strong>Table: </strong>Values returned by networkregistrationstatus</caption>
       
    13 <thead align="left">
       
    14 <tr class="title "><th class="cellrowborder" valign="top" id="d0e76959">
       
    15 <p>Value</p>
       
    16 </th><th class="cellrowborder" valign="top" id="d0e76964">
       
    17 <p>Description</p>
       
    18 </th></tr>
       
    19 </thead>
       
    20 <tbody>
       
    21 <tr class="">
       
    22 <td class="cellrowborder" valign="top" headers="d0e76959 ">
       
    23 <p>0</p>
       
    24 </td>
       
    25 <td class="cellrowborder" valign="top" headers="d0e76964 ">
       
    26 <p>Registration status is unknown.</p>
       
    27 </td>
       
    28 </tr>
       
    29 <tr class="bg ">
       
    30 <td class="cellrowborder" valign="top" headers="d0e76959 ">
       
    31 <p>1</p>
       
    32 </td>
       
    33 <td class="cellrowborder" valign="top" headers="d0e76964 ">
       
    34 <p>Not registered. The mobile device cannot detect any other networks and is not currently searching a new operator to register to.</p>
       
    35 </td>
       
    36 </tr>
       
    37 <tr class="">
       
    38 <td class="cellrowborder" valign="top" headers="d0e76959 ">
       
    39 <p>2</p>
       
    40 </td>
       
    41 <td class="cellrowborder" valign="top" headers="d0e76964 ">
       
    42 <p>Not registered. The mobile device can detect other networks on which it is possible to make emergency calls only.</p>
       
    43 </td>
       
    44 </tr>
       
    45 <tr class="bg ">
       
    46 <td class="cellrowborder" valign="top" headers="d0e76959 ">
       
    47 <p>3</p>
       
    48 </td>
       
    49 <td class="cellrowborder" valign="top" headers="d0e76964 ">
       
    50 <p>Not registered, but the mobile device is currently searching for a new operator to register to.</p>
       
    51 </td>
       
    52 </tr>
       
    53 <tr class="">
       
    54 <td class="cellrowborder" valign="top" headers="d0e76959 ">
       
    55 <p>4</p>
       
    56 </td>
       
    57 <td class="cellrowborder" valign="top" headers="d0e76964 ">
       
    58 <p>Registered, network busy.</p>
       
    59 </td>
       
    60 </tr>
       
    61 <tr class="bg ">
       
    62 <td class="cellrowborder" valign="top" headers="d0e76959 ">
       
    63 <p>5</p>
       
    64 </td>
       
    65 <td class="cellrowborder" valign="top" headers="d0e76964 ">
       
    66 <p>Registered on home network.</p>
       
    67 </td>
       
    68 </tr>
       
    69 <tr class="">
       
    70 <td class="cellrowborder" valign="top" headers="d0e76959 ">
       
    71 <p>6</p>
       
    72 </td>
       
    73 <td class="cellrowborder" valign="top" headers="d0e76964 ">
       
    74 <p>Registration denied.</p>
       
    75 </td>
       
    76 </tr>
       
    77 <tr class="bg ">
       
    78 <td class="cellrowborder" valign="top" headers="d0e76959 ">
       
    79 <p>7</p>
       
    80 </td>
       
    81 <td class="cellrowborder" valign="top" headers="d0e76964 ">
       
    82 <p>Registered on visited network (roaming).</p>
       
    83 </td>
       
    84 </tr>
       
    85 </tbody>
       
    86 </table></div>
       
    87 <p>For more information on network connection related aspects that you should take into account in your widget, see <a href="GUID-C158B834-9FF8-47C1-B2B5-BA154EBFA8BC.html#GUID-C158B834-9FF8-47C1-B2B5-BA154EBFA8BC">Dealing with network issues</a>.</p>
       
    88 <p><strong>Example code:</strong></p>
       
    89 <pre class="codeblock" id="GUID-E7146E33-6926-4197-BBFC-5FCC2502C224">window.onload = function(){
       
    90   // Detect the current status
       
    91   networkRegEventHandler();
       
    92 }
       
    93 networkRegEventHandler() {
       
    94   var textInfo = null;
       
    95   var networkName = "";
       
    96   var status = sysinfo.networkregistrationstatus;
       
    97   switch (status) {
       
    98      case 0:
       
    99      case 1:
       
   100      case 2:
       
   101      case 3:
       
   102      case 4:
       
   103      case 6:
       
   104          textInfo = "Network registration failed!";
       
   105          break;
       
   106      case 5:
       
   107          networkName = sysinfo.networkname;
       
   108          textInfo ="Registered on home network named );
       
   109          break;
       
   110      case 7:
       
   111          networkName = sysinfo.networkname;
       
   112          textInfo ="Registered on foreign network named );
       
   113          break;
       
   114      default:
       
   115          break;
       
   116   }
       
   117   alert(textInfo + networkname);
       
   118 }</pre>
       
   119 </div></div></div><div class="footer"><hr/><div class="copy">© Nokia 2009.</div></div></body></html>