Siddharth,
You can just call the AnimateWindow API, passing the handle to your
grid, and the transition effect for the slide. Here are the definitions you
need:
private const int AW_HOR_POSITIVE =0x00000001;
private const int AW_HOR_NEGATIVE =0x00000002;
private const int AW_VER_POSITIVE =0x00000004;
private const int AW_VER_NEGATIVE =0x00000008;
private const int AW_CENTER =0x00000010;
private const int AW_HIDE =0x00010000;
private const int AW_ACTIVATE =0x00020000;
private const int AW_SLIDE =0x00040000;
private const int AW_BLEND = 0x00080000;
[DllImport("user32.dll", SetLastError=true)]
private static extern bool AnimateWindow(
HandleRef hwnd,
[MarshalAs(UnmanagedType.U4)] int dwTime,
[MarshalAs(UnmanagedType.U4)] int dwFlags);
Hope this helps.
--
- Nicholas Paldino [.NET/C# MVP]
-
mv*@spam.guard.caspershouse.com
"Siddharth Jain" <si**************@rediffmail.com> wrote in message
news:11*********************@f14g2000cwb.googlegro ups.com...
Hi,
i have made a windows form in which there is a data grid which should
slide in when a button is clicked. Since i am new to .NET i haven't
been able to figure this out even after a lot of googling.
I found something about handles and Animate Window. Could someone
please explain that to me or guide me to a good link to explain all
that.
Thanks
Siddharth Jain