﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>StrataFrame Forum / StrataFrame Application Framework / WinForms (How do I?)  / Exposing the ListPopulating Event of a SFListView in a custom user control / Latest Posts</title><generator>InstantForum.NET v4.1.4</generator><description>StrataFrame Forum</description><link>http://forum.strataframe.net/</link><webMaster>forum@strataframe.net</webMaster><lastBuildDate>Tue, 02 Dec 2008 16:47:21 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: Exposing the ListPopulating Event of a SFListView in a custom user control</title><link>http://forum.strataframe.net/Topic2232-7-1.aspx</link><description>Congrats Scott! :) &lt;P&gt;I was glad to hear that you got your fist event written.  Once you figure it out the first time, it is smooth sailing later on (at least smoother :hehe: ).  Glad to hear to got it going!</description><pubDate>Fri, 18 Aug 2006 08:46:24 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item><item><title>RE: Exposing the ListPopulating Event of a SFListView in a custom user control</title><link>http://forum.strataframe.net/Topic2232-7-1.aspx</link><description>Same here I have dabbled in .NET on some projects, mostly small. I am about to jump in with both feet.&lt;br&gt;&lt;br&gt;Good stuff.</description><pubDate>Thu, 17 Aug 2006 23:34:42 GMT</pubDate><dc:creator>Keith Chisarik</dc:creator></item><item><title>RE: Exposing the ListPopulating Event of a SFListView in a custom user control</title><link>http://forum.strataframe.net/Topic2232-7-1.aspx</link><description>Thanks for the support.  I am coming from a VFP background and .NET is a LOT to get your head wrapped around.  Thank God for SF, it takes care of a lot of the "details" and lets me worry about writing the application specific stuff.  As far as .NET goes,  I am liking it more and more every day, its just hard going from using a development language for about 15 years to being a "newbie". Everyone here is VERY supportive and I have learned a lot.</description><pubDate>Thu, 17 Aug 2006 23:20:33 GMT</pubDate><dc:creator>Scott</dc:creator></item><item><title>RE: Exposing the ListPopulating Event of a SFListView in a custom user control</title><link>http://forum.strataframe.net/Topic2232-7-1.aspx</link><description>Scott I personally find everyones questions and thoughts here invaluable. So thanks for that.&lt;br&gt;&lt;br&gt;As for the dim bulb, wait another few days.....  :D&lt;br&gt;&lt;br&gt;I just finished getting our .NET development environment the way I wanted it so I will start coding with Strataframe Monday.&lt;br&gt;</description><pubDate>Thu, 17 Aug 2006 22:40:22 GMT</pubDate><dc:creator>Keith Chisarik</dc:creator></item><item><title>RE: Exposing the ListPopulating Event of a SFListView in a custom user control</title><link>http://forum.strataframe.net/Topic2232-7-1.aspx</link><description>It Works!!!!!!:w00t:  I was making a stupid mistake,  the Fill method I was using didn't require any parameters, once I change the fill method to one that did, everything worked.&lt;P&gt;Thanks for your help. That .Net light buld is getting a little brighter.:D&lt;/P&gt;&lt;P&gt;Scott</description><pubDate>Thu, 17 Aug 2006 21:00:27 GMT</pubDate><dc:creator>Scott</dc:creator></item><item><title>RE: Exposing the ListPopulating Event of a SFListView in a custom user control</title><link>http://forum.strataframe.net/Topic2232-7-1.aspx</link><description>After a long day of working with events I think I finally understand how this works.  I have done what you suggested but still don't seem to be getting the ListPopulating event fired.  In my class I have tied the ListPopulating event to a private method and it never seems to be getting called (I put a break point and execution never stops).&lt;/P&gt;&lt;P&gt;I know this isn't an easy one to solve via a simple post on a message board but if you have any suggestion as to what to check or look for I would be greatful.&lt;/P&gt;&lt;P&gt;PS other then this issue everything (other events for this control) is working perfectly. For others out there reading this tread here are the links that really helped me get a grip on events\delegates:&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.csharpfriends.com/Articles/getArticle.aspx?articleID=18"&gt;http://www.csharpfriends.com/Articles/getArticle.aspx?articleID=18&lt;/A&gt;&lt;BR&gt;&lt;A href="http://www.akadia.com/services/dotnet_user_controls.html"&gt;http://www.akadia.com/services/dotnet_user_controls.html&lt;/A&gt;</description><pubDate>Thu, 17 Aug 2006 20:35:57 GMT</pubDate><dc:creator>Scott</dc:creator></item><item><title>RE: Exposing the ListPopulating Event of a SFListView in a custom user control</title><link>http://forum.strataframe.net/Topic2232-7-1.aspx</link><description>Let me give you an idea on starting with events.  Create a new test project and create a new control within that project.  Create a simple event that has no event arguments.  Expose a method that will allow you to raise the event once dropped on a form.  You can then build from there.  &lt;/P&gt;&lt;P&gt;My point is, start very simple by just defining an event and then you can grow from there. ;)</description><pubDate>Thu, 17 Aug 2006 13:21:51 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item><item><title>RE: Exposing the ListPopulating Event of a SFListView in a custom user control</title><link>http://forum.strataframe.net/Topic2232-7-1.aspx</link><description>Thanks Trent,  I am rapidly learning that this is a must more involved process.  I will search for some good articles about the topic.</description><pubDate>Thu, 17 Aug 2006 13:19:17 GMT</pubDate><dc:creator>Scott</dc:creator></item><item><title>RE: Exposing the ListPopulating Event of a SFListView in a custom user control</title><link>http://forum.strataframe.net/Topic2232-7-1.aspx</link><description>The only way to "expose" the SF ListView events is by capturing them within your control and then raising your own events on the user control.  So first, you need to create events within your user control.  You will more than likely want to make these thread safe by testing to see if an Invoke is required to prevent cross-thread violations.&lt;/P&gt;&lt;P&gt;If your control does not have a .Invoke() method, then you will need to create a property and implement the ISynchonizeInvoke interface which will allow you to capture the parent control and us it's .Invoke() methods and properties.&lt;/P&gt;&lt;P&gt;Once you declare the events, you will need to create a delegate that can be called within the Invoke method which raises the exposed events.&lt;/P&gt;&lt;P&gt;Once you have your events declared, simply add a handler to capture the desired SF ListView events and then raise your events passing along any event arguments that you need.&lt;/P&gt;&lt;P&gt;Sorry if this is a little ambigous, but if you have not created events before this is a relatively large topic.</description><pubDate>Thu, 17 Aug 2006 12:54:17 GMT</pubDate><dc:creator>Trent L. Taylor</dc:creator></item><item><title>Exposing the ListPopulating Event of a SFListView in a custom user control</title><link>http://forum.strataframe.net/Topic2232-7-1.aspx</link><description>Sorry to ask so many simple questions but that .Net light bulb is still dim for me.  I am trying to create a user control and contains a listview and sever command buttons,  what I want to do is expose the SFListView events so that I can code directly on the new user control. (The next step would be to generate my own events).&lt;/P&gt;&lt;P&gt;Thanks again for all the .Net help.&lt;/P&gt;&lt;P&gt;Scott</description><pubDate>Thu, 17 Aug 2006 12:08:14 GMT</pubDate><dc:creator>Scott</dc:creator></item></channel></rss>