title: Using Drawing to create a graphic verification code does not display
body: <p>I am developing an API tool for generating verification codes. I use the Drawing package. I have found some methods, but why can't I generate the graphic verification codes I need? Where am I doing wrong?</p>
  <pre><code> public void Output(HttpResponse objHttpResponse)
          {
              using (Bitmap bitmap = this.GetImage())
              {
                  if (bitmap != null)
                  {
                      using (MemoryStream ms= new MemoryStream())
                      {
                          bitmap .Save(ms, ImageFormat.Jpeg);
   
                          HttpContext.Current.Response.ClearContent();
                          HttpContext.Current.Response.ContentType = &quot;image/Jpeg&quot;;
                          HttpContext.Current.Response.BinaryWrite(ms.ToArray());
                          HttpContext.Current.Response.Flush();
                          HttpContext.Current.Response.End();
                      }
                  }
              }
          }
  </code></pre>