<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:copyright="http://blogs.law.harvard.edu/tech/rss" xmlns:image="http://purl.org/rss/1.0/modules/image/">
    <channel>
        <title>WPF</title>
        <link>http://geekswithblogs.net/sonam/category/9175.aspx</link>
        <description>WPF</description>
        <language>en-US</language>
        <copyright>sonam</copyright>
        <managingEditor>sonamsingh_19@yahoo.co.in</managingEditor>
        <generator>Subtext Version 0.0.0.0</generator>
        <item>
            <title>Setting "WindowStyle=None" hides taskbar on maximizing</title>
            <link>http://geekswithblogs.net/sonam/archive/2009/07/21/setting-windowstylenone-hides-taskbar-on-maximizing.aspx</link>
            <description>&lt;br /&gt;
If you ever tried to make irregular windows in wpf and used setting windowstyle=none,You might have used some code like this to enable minimising,maximising properties for the window:&lt;br /&gt;
&lt;br /&gt;
&lt;span style="color: rgb(255, 102, 0);"&gt;        private void Minimize_Click(object sender, RoutedEventArgs e)&lt;/span&gt;&lt;br style="color: rgb(255, 102, 0);" /&gt;
&lt;span style="color: rgb(255, 102, 0);"&gt;        {&lt;/span&gt;&lt;br style="color: rgb(255, 102, 0);" /&gt;
&lt;br style="color: rgb(255, 102, 0);" /&gt;
&lt;span style="color: rgb(255, 102, 0);"&gt;            this.WindowState = WindowState.Minimized;&lt;/span&gt;&lt;br style="color: rgb(255, 102, 0);" /&gt;
&lt;br style="color: rgb(255, 102, 0);" /&gt;
&lt;span style="color: rgb(255, 102, 0);"&gt;        }&lt;/span&gt;&lt;br /&gt;
&lt;br style="color: rgb(255, 0, 0);" /&gt;
&lt;span style="color: rgb(255, 0, 0);"&gt;        private void Maximize_Click(object sender, RoutedEventArgs e)&lt;/span&gt;&lt;br style="color: rgb(255, 0, 0);" /&gt;
&lt;span style="color: rgb(255, 0, 0);"&gt;        {&lt;/span&gt;&lt;br style="color: rgb(255, 0, 0);" /&gt;
&lt;br style="color: rgb(255, 0, 0);" /&gt;
&lt;span style="color: rgb(255, 0, 0);"&gt;            this.WindowState = WindowState.Maximized;&lt;/span&gt;&lt;br style="color: rgb(255, 0, 0);" /&gt;
&lt;br style="color: rgb(255, 0, 0);" /&gt;
&lt;span style="color: rgb(255, 0, 0);"&gt;        }&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
But on maximizing  ,the window hides the taskbar.i.e it goes fullscreen.&lt;br /&gt;
To avoid that issue,You can use this code and yes,it works like a charm.&lt;br /&gt;
&lt;br /&gt;
&lt;a href="http://blogs.msdn.com/llobo/archive/2006/08/01/Maximizing-window-_2800_with-WindowStyle_3D00_None_2900_-considering-Taskbar.aspx"&gt;http://blogs.msdn.com/llobo/archive/2006/08/01/Maximizing-window-_2800_with-WindowStyle_3D00_None_2900_-considering-Taskbar.aspx&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;span class="Apple-style-span" style="border-collapse: separate; color: rgb(0, 0, 0); font-family: 'Times New Roman'; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;"&gt;&lt;span class="Apple-style-span" style="font-family: Tahoma; font-size: 13px;"&gt;
&lt;pre class="code"&gt;    public override void OnApplyTemplate()&lt;br /&gt;        {&lt;br /&gt;            System.IntPtr handle = (new WinInterop.WindowInteropHelper(this)).Handle;&lt;br /&gt;            WinInterop.HwndSource.FromHwnd(handle).AddHook(new WinInterop.HwndSourceHook(WindowProc));&lt;br /&gt;        }&lt;br /&gt;&lt;br /&gt;        private static System.IntPtr WindowProc(&lt;br /&gt;              System.IntPtr hwnd,&lt;br /&gt;              int msg,&lt;br /&gt;              System.IntPtr wParam,&lt;br /&gt;              System.IntPtr lParam,&lt;br /&gt;              ref bool handled)&lt;br /&gt;        {&lt;br /&gt;            switch (msg)&lt;br /&gt;            {&lt;br /&gt;                &lt;font style="background-color: rgb(255, 255, 0);"&gt;&lt;font color="#000000"&gt;case 0x0024:&lt;/font&gt;&lt;span style="font-size: 10pt; color: green; font-family: Consolas;"&gt;&lt;font color="#000000"&gt;/* WM_GETMINMAXINFO */&lt;/font&gt;&lt;/span&gt;&lt;/font&gt;&lt;br /&gt;                    WmGetMinMaxInfo(hwnd, lParam);&lt;br /&gt;                    handled = true;&lt;br /&gt;                    break;&lt;br /&gt;            }&lt;br /&gt;&lt;br /&gt;            return (System.IntPtr)0;&lt;br /&gt;        }&lt;br /&gt;&lt;br /&gt;        private static void WmGetMinMaxInfo(System.IntPtr hwnd, System.IntPtr lParam)&lt;br /&gt;        {&lt;br /&gt;            &lt;br /&gt;            MINMAXINFO mmi = (MINMAXINFO)Marshal.PtrToStructure(lParam, typeof(MINMAXINFO));&lt;br /&gt;&lt;br /&gt;            &lt;font color="#000000" style="background-color: rgb(255, 255, 0);"&gt;// Adjust the maximized size and position to fit the work area of the correct monitor&lt;br /&gt;&lt;/font&gt;            int MONITOR_DEFAULTTONEAREST =0x00000002;&lt;br /&gt;            System.IntPtr monitor = MonitorFromWindow(hwnd, MONITOR_DEFAULTTONEAREST);&lt;br /&gt;&lt;br /&gt;            if (monitor != System.IntPtr.Zero)&lt;br /&gt;            {&lt;br /&gt;                &lt;br /&gt;                MONITORINFO monitorInfo = new MONITORINFO();&lt;br /&gt;                GetMonitorInfo(monitor, monitorInfo);&lt;br /&gt;                RECT rcWorkArea = monitorInfo.rcWork;&lt;br /&gt;                RECT rcMonitorArea = monitorInfo.rcMonitor;&lt;br /&gt;                mmi.ptMaxPosition.x = Math.Abs(rcWorkArea.left - rcMonitorArea.left);&lt;br /&gt;                mmi.ptMaxPosition.y = Math.Abs(rcWorkArea.top - rcMonitorArea.top);&lt;br /&gt;                mmi.ptMaxSize.x = Math.Abs(rcWorkArea.right - rcWorkArea.left);&lt;br /&gt;                mmi.ptMaxSize.y = Math.Abs(rcWorkArea.bottom - rcWorkArea.top);&lt;br /&gt;            }&lt;br /&gt;&lt;br /&gt;            Marshal.StructureToPtr(mmi, lParam, true);&lt;br /&gt;        }&lt;br /&gt;&lt;/pre&gt;
&lt;p&gt;As seen above the code basically handles the &lt;span style="font-size: 10pt; color: green; font-family: Consolas;"&gt;&lt;font color="#ff0000"&gt;&lt;strong&gt;WM_GETMINMAXINFO&lt;/strong&gt;&lt;/font&gt; &lt;/span&gt;message. The sample project code is also included. Have Fun. :)&lt;/p&gt;
&lt;p mce_keep="true"&gt; &lt;/p&gt;
&lt;p&gt;&lt;strong&gt;Update&lt;/strong&gt;: A better way to get the handle to the window is to use the SourceInitialized event. This would also avoid calling ApplyTemplate everytime the window template is changedon the fly. Thanks to Hamid for pointing out the better solution. The attached project is now updated.&lt;/p&gt;
&lt;p&gt;&lt;font size="2"&gt;win.SourceInitialized +=&lt;span class="Apple-converted-space"&gt; &lt;/span&gt;&lt;/font&gt;&lt;font size="2" color="#0000ff"&gt;new&lt;/font&gt;&lt;font size="2"&gt;&lt;span class="Apple-converted-space"&gt; &lt;/span&gt;&lt;/font&gt;&lt;font size="2" color="#008080"&gt;EventHandler&lt;/font&gt;&lt;font size="2"&gt;(win_SourceInitialized);&lt;/font&gt;&lt;/p&gt;
&lt;p&gt;&lt;font size="2" color="#0000ff"&gt;void&lt;/font&gt;&lt;font size="2"&gt;&lt;span class="Apple-converted-space"&gt; &lt;/span&gt;win_SourceInitialized(&lt;/font&gt;&lt;font size="2" color="#0000ff"&gt;object&lt;/font&gt;&lt;font size="2"&gt;&lt;span class="Apple-converted-space"&gt; &lt;/span&gt;sender,&lt;span class="Apple-converted-space"&gt; &lt;/span&gt;&lt;/font&gt;&lt;font size="2" color="#008080"&gt;EventArgs&lt;/font&gt;&lt;font size="2"&gt;&lt;span class="Apple-converted-space"&gt; &lt;/span&gt;e)&lt;br /&gt;
{&lt;br /&gt;
   System.&lt;/font&gt;&lt;font size="2" color="#008080"&gt;IntPtr&lt;/font&gt;&lt;font size="2"&gt;&lt;span class="Apple-converted-space"&gt; &lt;/span&gt;handle = (&lt;/font&gt;&lt;font size="2" color="#0000ff"&gt;new&lt;/font&gt;&lt;font size="2"&gt;&lt;span class="Apple-converted-space"&gt; &lt;/span&gt;WinInterop.&lt;/font&gt;&lt;font size="2" color="#008080"&gt;WindowInteropHelper&lt;/font&gt;&lt;font size="2"&gt;(&lt;/font&gt;&lt;font size="2" color="#0000ff"&gt;this&lt;/font&gt;&lt;font size="2"&gt;)).Handle;&lt;br /&gt;
   WinInterop.&lt;/font&gt;&lt;font size="2" color="#008080"&gt;HwndSource&lt;/font&gt;&lt;font size="2"&gt;.FromHwnd(handle).AddHook(&lt;/font&gt;&lt;font size="2" color="#0000ff"&gt;new&lt;/font&gt;&lt;font size="2"&gt;&lt;span class="Apple-converted-space"&gt; &lt;/span&gt;WinInterop.&lt;/font&gt;&lt;font size="2" color="#008080"&gt;HwndSourceHook&lt;/font&gt;&lt;font size="2"&gt;(WindowProc));&lt;br /&gt;
}&lt;/font&gt;&lt;/p&gt;
&lt;/span&gt;&lt;/span&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=133639"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=133639" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/sonam/aggbug/133639.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>sonam</dc:creator>
            <guid>http://geekswithblogs.net/sonam/archive/2009/07/21/setting-windowstylenone-hides-taskbar-on-maximizing.aspx</guid>
            <pubDate>Wed, 22 Jul 2009 11:49:48 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/sonam/comments/133639.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/sonam/archive/2009/07/21/setting-windowstylenone-hides-taskbar-on-maximizing.aspx#feedback</comments>
            <wfw:commentRss>http://geekswithblogs.net/sonam/comments/commentRss/133639.aspx</wfw:commentRss>
        </item>
        <item>
            <title>What happened to my vacations</title>
            <link>http://geekswithblogs.net/sonam/archive/2009/07/21/what-happened-to-my-vacations.aspx</link>
            <description>College is opening tommorow and I am thinking what i have done in past 1 and half months of vacations.&lt;br /&gt;
&lt;br /&gt;
The only thing i can remember is bluz,my open source project.&lt;br /&gt;
Where is that p2p thing i decided earlier?&lt;br /&gt;
All the research papers about skype,overlay networks ,guntella etc are lying there on disk as it is.i have read them only once.I have read not understood..&lt;img src="/Providers/BlogEntryEditor/FCKeditor/editor/images/smiley/msn/wink_smile.gif" alt="" /&gt;&lt;br /&gt;
&lt;br /&gt;
The positive side of vacations is:&lt;br /&gt;
1)I learned a lot about WPF,Blend etc.&lt;br /&gt;
2) I am participating in win7 contest based on above experience.&lt;br /&gt;
3)I met shaun,my  new co-developer of bluz..&lt;br /&gt;
4)I have got some books of ASP.Net by bill ,scott and  WPF book by Mathew macdonald..&lt;br /&gt;
&lt;br /&gt;
And now i have some web 2.0 ideas that i hope to implement as a way of parcticing this ASP.net stuff.Thats a business idea,So you might  see something interesting on web soon.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
So,If i look back that way,I think it was more rewarding than any of internship i could get.&lt;br /&gt;
&lt;br /&gt;
Now ,its my last year of  graduation,My targets include:&lt;br /&gt;
1)Enjoy it fully.I know thats hard but i'll have to make this year remeberable .&lt;br /&gt;
2)Implement business ideas.(I love making money in humanatic way).&lt;br /&gt;
3)Make final year Project.&lt;br /&gt;
The 3rd one is where i'll cut my efforts ,Becoz i don't think that really matters as compared to my learning.Also,I don't see potential partners for a cool. .Net team to make a cool project at the college.&lt;br /&gt;
&lt;br /&gt;
cya guys,&lt;br /&gt;
cheers&lt;br /&gt;
&lt;br /&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=133640"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=133640" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/sonam/aggbug/133640.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>sonam</dc:creator>
            <guid>http://geekswithblogs.net/sonam/archive/2009/07/21/what-happened-to-my-vacations.aspx</guid>
            <pubDate>Wed, 22 Jul 2009 05:20:28 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/sonam/comments/133640.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/sonam/archive/2009/07/21/what-happened-to-my-vacations.aspx#feedback</comments>
            <wfw:commentRss>http://geekswithblogs.net/sonam/comments/commentRss/133640.aspx</wfw:commentRss>
        </item>
        <item>
            <title>I am gonna win this contest</title>
            <link>http://geekswithblogs.net/sonam/archive/2009/07/21/i-am-gonna-win-this-contest.aspx</link>
            <description>&lt;span style="border-collapse: separate; color: rgb(0, 0, 0); font-family: 'Times New Roman'; font-size: 16px; font-style: normal; font-variant: normal; font-weight: normal; letter-spacing: normal; line-height: normal; orphans: 2; text-indent: 0px; text-transform: none; white-space: normal; widows: 2; word-spacing: 0px;" class="Apple-style-span"&gt;&lt;span style="font-family: -webkit-monospace; font-size: 13px; white-space: pre-wrap;" class="Apple-style-span"&gt;Hii guys,&lt;br /&gt;
Just heard about this &lt;br /&gt;
&lt;br /&gt;
&lt;a href="https://www.code7contest.com/"&gt;https://www.code7contest.com/&lt;/a&gt;&lt;br /&gt;
&lt;br /&gt;
If you have  a little experience with MS .Net and you are as empty as me,Have a look over it.&lt;br /&gt;
&lt;br /&gt;
The prizes are awesome and mouth watering .You will have to grasp a little about the windows 7 techonolgies though .But you can do that for atleast 17777$.&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
I am getting ready with a killer app idea..yes it  is a a killer idea,Either it will Kill MS or my Laptop.lol!(Sorry bill,its a metaphor,don't take it serious.)&lt;br /&gt;
&lt;br /&gt;
And the best thing is that ,My Last 2-3 months of WPF experience is what gonna be tested.&lt;br /&gt;
The deadline is short but thats good for me ,I am entering with an optimistic mind,Hope to see you guys at LA soon..&lt;br /&gt;
&lt;br /&gt;
cheer with a beer.(I don't drink though)&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;/span&gt;&lt;/span&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=133616"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=133616" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/sonam/aggbug/133616.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>sonam</dc:creator>
            <guid>http://geekswithblogs.net/sonam/archive/2009/07/21/i-am-gonna-win-this-contest.aspx</guid>
            <pubDate>Tue, 21 Jul 2009 19:57:10 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/sonam/comments/133616.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/sonam/archive/2009/07/21/i-am-gonna-win-this-contest.aspx#feedback</comments>
            <wfw:commentRss>http://geekswithblogs.net/sonam/comments/commentRss/133616.aspx</wfw:commentRss>
        </item>
        <item>
            <title>Extracting Album art  from An Audio File</title>
            <link>http://geekswithblogs.net/sonam/archive/2009/06/11/extracting-album-from-an-audio-file.aspx</link>
            <description>I have moved the tagging features for my media player application from MediaInfo to taglib-sharp.&lt;br /&gt;
because taglib-sharp provides writing of tags back to audio files too..&lt;br /&gt;
As a matter of fact,&lt;br /&gt;
Everything else was fine but,it took me whole half day to figure out how to display an image (album art) from taglib-sharp.&lt;br /&gt;
&lt;br /&gt;
I thought to finally post this workaround.&lt;br /&gt;
&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;span style="color: rgb(51, 102, 255);"&gt;     TagLib.File file = TagLib.File.Create((FilePath); //FilePath is the audio file location&lt;/span&gt;&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;span style="color: rgb(51, 102, 255);"&gt;                 TagLib.IPicture pic=file.Tag.Pictures[0];  //pic contains data for image.&lt;/span&gt;&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;span style="color: rgb(51, 102, 255);"&gt;                 MemoryStream stream = new MemoryStream(pic.Data.Data);  /create an in memory stream&lt;/span&gt;&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;span style="color: rgb(51, 102, 255);"&gt;               Image im = new Image();&lt;/span&gt;&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;span style="color: rgb(51, 102, 255);"&gt;               BitmapFrame bmp = BitmapFrame.Create(stream);&lt;/span&gt;&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;span style="color: rgb(51, 102, 255);"&gt;               im.Source = bmp;&lt;/span&gt;&lt;br style="color: rgb(51, 102, 255);" /&gt;
&lt;span style="color: rgb(51, 102, 255);"&gt; &lt;/span&gt;now u can use this image as a normal image..:)..i.e transformation,animation should be possible as usual.&lt;br /&gt;
&lt;br /&gt;
cheers, i didn't  got any  post on web till now even after searching Novell's Repositories..Hopefully it helps to somebody out there .&lt;br /&gt;
&lt;br /&gt;
            &lt;br /&gt;
 &lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=132745"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=132745" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/sonam/aggbug/132745.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>sonam</dc:creator>
            <guid>http://geekswithblogs.net/sonam/archive/2009/06/11/extracting-album-from-an-audio-file.aspx</guid>
            <pubDate>Thu, 11 Jun 2009 15:27:41 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/sonam/comments/132745.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/sonam/archive/2009/06/11/extracting-album-from-an-audio-file.aspx#feedback</comments>
            <slash:comments>1</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/sonam/comments/commentRss/132745.aspx</wfw:commentRss>
        </item>
        <item>
            <title>Awesome way to support plugins/AddIns in your applications</title>
            <link>http://geekswithblogs.net/sonam/archive/2009/04/14/awesome-way-to-support-pluginsaddins-in-your-applications.aspx</link>
            <description>Hey all,&lt;br /&gt;
I can't imagine how easy it can be to develop and maintain a plugin architecture with System.AddIn and this tool &lt;br /&gt;
VSPipelineBuilder.. This is a visual studio addIn is an open source  project by the ClrAddIn team and is really awesome.&lt;br /&gt;
&lt;br /&gt;
U just define an interface/Contract and rest of the things, just a single click through that addIn.&lt;br /&gt;
AddIn will implement that  Interface and thats it,u can use it..Cheers .........&lt;br /&gt;
&lt;br /&gt;
I used it for first defining a single interface .and implemented a small AddIn.&lt;br /&gt;
.&lt;br /&gt;
then i added 2-3 interfaces and re executed that VSPipeline Builder AddIn..And it was awesome to see that every project in The Pipeline(4-5 projects) got updated accordingly.&lt;span style="color: rgb(255, 0, 0);"&gt;My old AddIn was still working  becoz its contract was still there..&lt;/span&gt;&lt;br style="color: rgb(255, 0, 0);" /&gt;
And iwas ready to implement new AddIns..Really great...It can save a lot of time when u have a lot of contracts to support various plugins/AddIns.&lt;br /&gt;
Below is a screenshot of an excellent demo app from jesse kaplan:&lt;br /&gt;
&lt;br /&gt;
It demonstrates visual addIn also(Passing UI objects between AddIn and host)&lt;br /&gt;
ClrAddIn Team blogs at:&lt;br /&gt;
http://blogs.msdn.com/clraddins/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;img src="http://blogs.msdn.com/photos/clr_add-in_team/images/4265273/original.aspx" alt="" /&gt;&lt;br /&gt;
&lt;br /&gt;
U can download the VSPipeline Builder from here:&lt;br /&gt;
&lt;br /&gt;
http://clraddins.codeplex.com/&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
Cheers,And thanx to Jesse kaplan and the whole ClrAddIn team.&lt;br /&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=130959"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=130959" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/sonam/aggbug/130959.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>sonam</dc:creator>
            <guid>http://geekswithblogs.net/sonam/archive/2009/04/14/awesome-way-to-support-pluginsaddins-in-your-applications.aspx</guid>
            <pubDate>Tue, 14 Apr 2009 17:53:06 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/sonam/comments/130959.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/sonam/archive/2009/04/14/awesome-way-to-support-pluginsaddins-in-your-applications.aspx#feedback</comments>
            <slash:comments>1</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/sonam/comments/commentRss/130959.aspx</wfw:commentRss>
        </item>
        <item>
            <title>ListView DragDrop in WPF,multiselect</title>
            <link>http://geekswithblogs.net/sonam/archive/2009/03/02/listview-dragdrop-in-wpfmultiselect.aspx</link>
            <description>After going through the web ,I haven't got anything that i can use directly to enable drag drop between two listview controls or within same for multiple items.&lt;br /&gt;
The best thing available in my opinion is this one by Josh smith:&lt;br /&gt;
http://www.codeproject.com/KB/WPF/ListViewDragDropManager.aspx&lt;br /&gt;
&lt;br /&gt;
But it is for single SelectionMode only&lt;br /&gt;
&lt;br /&gt;
Another one for multiselct is this:&lt;br /&gt;
http://www.codeproject.com/KB/WPF/WPF_MultiSelect_DragDrop.aspx&lt;br /&gt;
But the second one has many limitations..&lt;br /&gt;
So i have done some work to extend it from there..&lt;br /&gt;
I don't have much time in near weeks to work on this ,So it is not that much well written.&lt;br /&gt;
But it will serve as the good to get u one what u want during drag drop in more graceful way....&lt;br /&gt;
&lt;br /&gt;
The code is as follows:&lt;br /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(0, 0, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Collections.Generic;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Collections;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Linq;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Text;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Windows.Controls;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Windows;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Windows.Media;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Windows.Controls.Primitives;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Collections.ObjectModel;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Reflection;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Diagnostics;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;namespace DragDropManager&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;{&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;   public class DragDropManager&amp;lt;T&amp;gt; where T:class,ICloneable&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;   {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        ListView listView;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       // delegate for GetPosition function of DragEventArgs and&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       // MouseButtonEventArgs event argument objects. This delegate is used to reuse the code&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       // for processing both types of events.&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       delegate Point GetPositionDelegate(IInputElement element);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       public DragDropManager(ListView listView)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           this.listView = listView;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           listView.PreviewMouseLeftButtonDown += new System.Windows.Input.MouseButtonEventHandler(listView_PreviewMouseLeftButtonDown);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           listView.Drop += new System.Windows.DragEventHandler(listView_Drop);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       }&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       void listView_Drop(object sender, DragEventArgs e)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           int index = this.GetCurrentIndex(e.GetPosition);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           if (index &amp;lt; 0)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;               return;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           Dictionary&amp;lt;int,T&amp;gt; draggedItems =  e.Data.GetData(typeof(Dictionary&amp;lt;int,T&amp;gt;)) as Dictionary&amp;lt;int,T&amp;gt;;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        if(sender==this.listView)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            this.listView.SelectedItems.Clear();&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       int i = 0;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;         ObservableCollection&amp;lt;T&amp;gt;  itemsSource=  this.listView.ItemsSource as ObservableCollection&amp;lt;T&amp;gt;;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           // finally insert the items into the source collection&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;         T dropTarget = itemsSource[index];&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;         if (draggedItems.ContainsValue(dropTarget)) return;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;   &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;   &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;          foreach(int key in draggedItems.Keys)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;          {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;              T draggedItemClone = draggedItems[key].Clone() as T;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;              itemsSource.Insert(index + i, draggedItemClone);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;             &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;              i++;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;          &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;          }&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
  &lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;&lt;/span&gt;&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;&lt;/span&gt;&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;          &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;      &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       }&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       void listView_PreviewMouseLeftButtonDown(object sender, System.Windows.Input.MouseButtonEventArgs e)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           int index = this.GetCurrentIndex(e.GetPosition);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           if (index &amp;lt;0) return; &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           // this will create the drag "rectangle"&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           DragDropEffects allowedEffects = DragDropEffects.Move;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           if (this.listView.SelectedItems.Count == 0)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;               return;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;          &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           Dictionary&amp;lt;int,T&amp;gt; draggedItems = new Dictionary&amp;lt;int, T&amp;gt;();&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;      &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;         &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           foreach(T draggedItem in this.listView.SelectedItems)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            draggedItems[this.listView.Items.IndexOf(draggedItem)] = (draggedItem as T);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;             &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           }&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           T item = this.listView.Items[index] as T;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           if (!draggedItems.ContainsValue(item))&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;                     return;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           DragDrop.DoDragDrop(this.listView, draggedItems, allowedEffects);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       }&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       ListViewItem GetListViewItem(int index)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           if (this.listView.ItemContainerGenerator.Status != GeneratorStatus.ContainersGenerated)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;               return null;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           return this.listView.ItemContainerGenerator.ContainerFromIndex(index) as ListViewItem;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       }&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       // returns the index of the item in the ListView&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       int GetCurrentIndex(GetPositionDelegate getPosition)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           int index = -1;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           for (int i = 0; i &amp;lt; this.listView.Items.Count; ++i)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;               ListViewItem item = GetListViewItem(i);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           if (this.IsMouseOverTarget(item, getPosition))&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;             &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;               {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;                   index = i;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;                   break;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;               }&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           }&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           return index;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       }&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       bool IsMouseOverTarget(Visual target, GetPositionDelegate getPosition)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           if (target == null)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;               return false ;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           Rect bounds = VisualTreeHelper.GetDescendantBounds(target);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           Point mousePos=  MouseUtilities.GetMousePosition(target);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;           return bounds.Contains(mousePos);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;       }&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;   }&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;}&lt;/span&gt;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
..........................................................................&lt;br /&gt;
The code for MouseUtilities.cs is :&lt;br /&gt;
&lt;br /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Collections.Generic;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Text;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Runtime.InteropServices;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Windows;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;using System.Windows.Media;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;namespace DragDropManager&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;{&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;    /// &amp;lt;summary&amp;gt;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;    /// Provides access to the mouse location by calling unmanaged code.&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;    /// &amp;lt;/summary&amp;gt;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;    /// &amp;lt;remarks&amp;gt;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;    /// This class was written by Dan Crevier (Microsoft).  &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;    /// http://blogs.msdn.com/llobo/archive/2006/09/06/Scrolling-Scrollviewer-on-Mouse-Drag-at-the-boundaries.aspx&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;    /// &amp;lt;/remarks&amp;gt;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;    public class MouseUtilities&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;    {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        [StructLayout(LayoutKind.Sequential)]&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        private struct Win32Point&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            public Int32 X;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            public Int32 Y;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        };&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        [DllImport("user32.dll")]&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        private static extern bool GetCursorPos(ref Win32Point pt);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        [DllImport("user32.dll")]&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        private static extern bool ScreenToClient(IntPtr hwnd, ref Win32Point pt);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        /// &amp;lt;summary&amp;gt;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        /// Returns the mouse cursor location.  This method is necessary during &lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        /// a drag-drop operation because the WPF mechanisms for retrieving the&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        /// cursor coordinates are unreliable.&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        /// &amp;lt;/summary&amp;gt;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        /// &amp;lt;param name="relativeTo"&amp;gt;The Visual to which the mouse coordinates will be relative.&amp;lt;/param&amp;gt;&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        public static Point GetMousePosition(Visual relativeTo)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        {&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            Win32Point mouse = new Win32Point();&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            GetCursorPos(ref mouse);&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            // Using PointFromScreen instead of Dan Crevier's code (commented out below)&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            // is a bug fix created by William J. Roberts.  Read his comments about the fix&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            // here: http://www.codeproject.com/useritems/ListViewDragDropManager.asp?msg=1911611#xx1911611xx&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            return relativeTo.PointFromScreen(new Point((double)mouse.X, (double)mouse.Y));&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            #region Commented Out&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            //System.Windows.Interop.HwndSource presentationSource =&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            //    (System.Windows.Interop.HwndSource)PresentationSource.FromVisual( relativeTo );&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            //ScreenToClient( presentationSource.Handle, ref mouse );&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            //GeneralTransform transform = relativeTo.TransformToAncestor( presentationSource.RootVisual );&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            //Point offset = transform.Transform( new Point( 0, 0 ) );&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            //return new Point( mouse.X - offset.X, mouse.Y - offset.Y );&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;            #endregion // Commented Out&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;        }&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;    }&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;span style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);"&gt;}&lt;/span&gt;&lt;br style="background-color: rgb(255, 255, 255); color: rgb(255, 102, 0);" /&gt;
&lt;br /&gt;
-------------------------------------------------------------------------------------------------------------------------&lt;br /&gt;
I have tested the drag drop of nearly 10,000 items from one listview to another and it was excellent(milliseconds).&lt;br /&gt;
There are some things that i want to say:&lt;br /&gt;
1)If u want to this to work for all SelectionModes,U'll will to do some changes or better to checks before using selectedItems property.&lt;br /&gt;
&lt;br /&gt;
2)The dragDrop between listviews will function when the two controls have same itemType(T) as the observableCollection type.&lt;br /&gt;
For any other type,U'll have do some little more coding .:P&lt;br /&gt;
&lt;br /&gt;
3)The reason for ICloneable Interface is because if u drag and drop one item two or more times to another listview,And then select that item in the other listview,U'll get some annoying behaviour of selection.&lt;br /&gt;
To Overcome that,I have used IConeable Interface for the meanwhile..&lt;br /&gt;
&lt;br /&gt;
If u have any questions regarding this code or feedback,u r most welcome.&lt;br /&gt;
&lt;br /&gt;
And do let me know if u think to make it more graceful and well written code in near future,becoz I'll have time to work on this after 1-2 months only... hopefully....:)&lt;br /&gt;
&lt;br /&gt;
&lt;br style="background-color: rgb(0, 0, 0); color: rgb(255, 255, 255);" /&gt;&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=129803"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=129803" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/sonam/aggbug/129803.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>sonam</dc:creator>
            <guid>http://geekswithblogs.net/sonam/archive/2009/03/02/listview-dragdrop-in-wpfmultiselect.aspx</guid>
            <pubDate>Tue, 03 Mar 2009 05:46:27 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/sonam/comments/129803.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/sonam/archive/2009/03/02/listview-dragdrop-in-wpfmultiselect.aspx#feedback</comments>
            <slash:comments>1</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/sonam/comments/commentRss/129803.aspx</wfw:commentRss>
        </item>
        <item>
            <title>WPF and vlc</title>
            <link>http://geekswithblogs.net/sonam/archive/2009/01/08/wpf-and-vlc.aspx</link>
            <description>I am trying harder to make a player based on the vlc libraries.&lt;br /&gt;
I am using .Net interface to vlc as described on VideoLan.org&lt;br /&gt;
.And shall bring GUI to WPF reach.&lt;br /&gt;
&lt;br /&gt;
Any Guidance or project co-ordinators  willing to lead this open source project?&lt;br /&gt;
I want to bring the best of both worlds.i.e The media player usability with the power of vlc.&lt;br /&gt;
Just mail me at sonamsingh_19@yahoo.co.in Directly..&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=128488"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=128488" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/sonam/aggbug/128488.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>sonam</dc:creator>
            <guid>http://geekswithblogs.net/sonam/archive/2009/01/08/wpf-and-vlc.aspx</guid>
            <pubDate>Thu, 08 Jan 2009 16:20:51 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/sonam/comments/128488.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/sonam/archive/2009/01/08/wpf-and-vlc.aspx#feedback</comments>
            <slash:comments>3</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/sonam/comments/commentRss/128488.aspx</wfw:commentRss>
        </item>
        <item>
            <title>How to Wrap hard disk in a control?Help</title>
            <link>http://geekswithblogs.net/sonam/archive/2008/11/28/how-to-wrap-hard-disk-in-a-controlhelp.aspx</link>
            <description>Well..I am trying to index my hard disk.&lt;br /&gt;
After making an initial Index,I want to get notified from hard disk for any change in the file system on any drive whatsoever (Removable media not into account).The hard disk will notify a background  running windows service(of my app) for event like file moved,copied,deleted,created etc.&lt;br /&gt;
U can say,i want to make my hard disk a control like a button which fires event when clicked.Using Windows Indexing Service would be an overkill.&lt;br /&gt;
Any suggestions or ideas or alternates if somebody have in mind.:)&lt;br /&gt;
I would be very thankful to u.&lt;p&gt;&lt;a href="http://www.pheedo.com/click.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=127436"&gt;&lt;img src="http://www.pheedo.com/img.phdo?x=6cda6ad746d942b9a1110d0715a4fa12&amp;u=127436" border="0"/&gt;&lt;/a&gt;&lt;/p&gt;&lt;iframe src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;PageID=31016&amp;amp;SiteID=1" width=1 height=1 Marginwidth=0 Marginheight=0 Hspace=0 Vspace=0 Frameborder=0 Scrolling=No&gt;
&lt;script language='javascript1.1' src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Browser=NETSCAPE4&amp;amp;NoCache=True&amp;PageID=31016&amp;amp;SiteID=1"&gt;&lt;/script&gt;
&lt;noscript&gt;&lt;a href="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Click&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" target="_blank"&gt;
&lt;img src="http://ads.geekswithblogs.net/a.aspx?ZoneID=5&amp;amp;Task=Get&amp;amp;Mode=HTML&amp;amp;SiteID=1&amp;amp;PageID=31016" width="1" height="1" border="0"  alt=""&gt;&lt;/a&gt;
&lt;/noscript&gt;
&lt;/iframe&gt;
&lt;img src="http://geekswithblogs.net/sonam/aggbug/127436.aspx" width="1" height="1" /&gt;</description>
            <dc:creator>sonam</dc:creator>
            <guid>http://geekswithblogs.net/sonam/archive/2008/11/28/how-to-wrap-hard-disk-in-a-controlhelp.aspx</guid>
            <pubDate>Fri, 28 Nov 2008 17:38:02 GMT</pubDate>
            <wfw:comment>http://geekswithblogs.net/sonam/comments/127436.aspx</wfw:comment>
            <comments>http://geekswithblogs.net/sonam/archive/2008/11/28/how-to-wrap-hard-disk-in-a-controlhelp.aspx#feedback</comments>
            <slash:comments>2</slash:comments>
            <wfw:commentRss>http://geekswithblogs.net/sonam/comments/commentRss/127436.aspx</wfw:commentRss>
        </item>
    </channel>
</rss>