title: Zooming a UIScrollView in MonoTouch
body: <p>I'm trying to implement zooming functionality using a UIScrollView in MonoTouch but I just can't seem to make it work.</p>
  
  <p>I've looked at a few tutorials which talk about setting a Delegate but most of it is in Obj-C which I can't translate over to C#.</p>
  
  <p>Basically, I have a UIScrollView in Interface Builder that has an UIImageView as a Subview.</p>
  
  <p>I've set the ContentSize of the UIScrollView to be the full size of the image and have also set a min/max zoom scale. Here's my code:</p>
  
  <pre><code>UIImage imgMap = new UIImage("img/map.png");
  ivMap.Image = imgMap;
  svMap.MinimumZoomScale = 1.0f;
  svMap.MaximumZoomScale = 3.0f;
  svMap.ContentSize = new System.Drawing.SizeF(ivMap.Frame.Width, ivMap.Frame.Height);
  </code></pre>
  
  <p>Any ideas on what I'm missing? </p>
  
  <p><strong>EDIT</strong></p>
  
  <p>I've created a new .xib file with the code provided by @Geoff but still no luck, the image just scrolls but still doesn't zoom.</p>
  
  <pre><code>public override void ViewDidLoad ()
  {
      base.ViewDidLoad ();
  
      UIScrollView sv = new UIScrollView (thisView.Frame);
      UIImageView iv = new UIImageView(UIImage.FromFile ("img/map.png"));
  
      sv.AddSubview (iv);
      sv.ContentSize = iv.Frame.Size;
      sv.MinimumZoomScale = 1.0f;
      sv.MaximumZoomScale = 3.0f;
  
      vwMineral.AddSubview(sv);
  }
  </code></pre>