title: Is it possible for a winform to have an animation effect if it is in a parent container?
body: <p>I have a winform application using C#. I have tried everything to have a transition effect from form1 to form2.(opacity and height width change base on timer) But it seems that using parent-child container (MdiParent), it is not possible. Am I right? Or there are other way?</p>
  
  <p>Here is my code..</p>
  
  <pre><code>public static System.Windows.Forms.Form gMdiForm;
  
  public static Boolean fCheckFormNotUsed(string tMdiChildFormName)
      {
          foreach (System.Windows.Forms.Form childform in gMdiForm.MdiChildren)
          {
              if (childform.Name == tMdiChildFormName)
              {
                  childform.Visible = true;
                  childform.Activate();
                  return false;
              }
          }
          return true;
      }
  
  if (fCheckFormNotUsed("frm2"))
          {
              frm2 mMDIChild = new frm2();
              mMDIChild.MdiParent = cls0G.gMdiForm;
              mMDIChild.WindowState = FormWindowState.Maximized;
              mMDIChild.Opacity = 0;
              mMDIChild.Show();
  
          }
  </code></pre>
  
  <p>Here is the code for timer in frm2</p>
  
  <pre><code>private void timer1_Tick(object sender, EventArgs e)
      {
          if (this.Opacity &lt;= 1.0)
          {
              this.Opacity += 0.07;
              this.Height += 1;
              this.Width  += 3;
  
          }
          else
          {
              timer1.Stop();
          }
      }
  </code></pre>
  
  <p>Here is the load for form2</p>
  
  <pre><code>        this.Opacity = 0;
          timer1.Start();
  </code></pre>