title: How to code an android application update from the Android Market
body: <p>I am developing an android application with one basic function, to allow the user to click a button and download the full app from the android market (a virtual preload type app similar to the apps which come pre-loaded on the phone, which you have to actually install first to use) . </p>
  
  <p>In my Activity class I create a Button and call the setOnClickListener...</p>
  
  <pre><code>marketButton.setOnClickListener(new View.OnClickListener() {
      @Override
      public void onClick(View v) {
          String urlToMarket = "market://search?q=&lt;package.name&gt;";
          Intent i = new Intent(Intent.ACTION_VIEW);
          i.setData(Uri.parse(urlToMarket));
          startActivity(i);
      }
  });
  </code></pre>
  
  <p>i get an <code>ActivityNotFoundException: No Activity found to handle intent.</code> How do I code a handler for this intent?</p>