Chris Hammond is
a father, husband, developer, geek, car guy. The Director of Training for DotNetNuke Corporation. To learn more about Chris check out the about me page.
LIVESTRONG Challenge Davis

I use Strava to track my bicycle rides. Below you can see my recent activity.

 

Tags
  1. 12 items are tagged with .net
  2. 58 items are tagged with asp.net
  3. 47 items are tagged with Autocross
  4. 12 items are tagged with Baby
  5. 39 items are tagged with Boston Red Sox
  6. 21 items are tagged with California
  7. 15 items are tagged with Car
  8. 29 items are tagged with Community Server
  9. 14 items are tagged with communityserver
  10. 17 items are tagged with Corvette
  11. 26 items are tagged with daily tips
  12. 93 items are tagged with Development
  13. 180 items are tagged with DotNetNuke
  14. 25 items are tagged with DotNetNuke Development
  15. 11 items are tagged with DotNetNuke Tips
  16. 12 items are tagged with DotNetNuke Training
  17. 12 items are tagged with Electric
  18. 12 items are tagged with Energy
  19. 25 items are tagged with Family
  20. 73 items are tagged with Fitness
  21. 117 items are tagged with Friends
  22. 44 items are tagged with Games
  23. 32 items are tagged with general Software Development
  24. 13 items are tagged with Green
  25. 22 items are tagged with HDTV
  26. 18 items are tagged with Health
  27. 13 items are tagged with Leaf
  28. 381 items are tagged with Life News
  29. 12 items are tagged with Microsoft
  30. 39 items are tagged with Music
  31. 14 items are tagged with Nissan
  32. 13 items are tagged with Nissan Leaf
  33. 88 items are tagged with Photography
  34. 18 items are tagged with Photos
  35. 89 items are tagged with Pictures
  36. 108 items are tagged with Places to See
  37. 20 items are tagged with Project 240Z
  38. 12 items are tagged with Project 350Z
  39. 21 items are tagged with Red Sox
  40. 19 items are tagged with Red Sox in St. Louis
  41. 15 items are tagged with SCCA
  42. 418 items are tagged with SEO
  43. 203 items are tagged with Site News
  44. 33 items are tagged with St. Louis
  45. 275 items are tagged with Technology
  46. 41 items are tagged with Travel
  47. 17 items are tagged with Vista
  48. 16 items are tagged with Weblog
  49. 16 items are tagged with Xbox360
  50. 12 items are tagged with Zune

Community Server 1.1 Latest Posts control

Last Updated Wednesday, January 23, 2008 4:50 PM


I took the latest forum posts control from Christian Nordbakk and turned it into a control to use on SCCAForums.com

The differences are that my control

  • displays the latest post made 
  • links to the last post made instead of the first
  • shows the user who made the last post
  • shows the forum the post was made in

You can change some of the settings for this control such as the number of posts returned, by looking at the GetThreads() method in the code.

If you want to use this control please feel free to do so. You'll need to download the control here (rename it from latestforumsposts.txt to latestforumposts.ascx) and place it in the root of your CS folder, eventually I'll get around to making this control part of my CJHControls package, but for now you can just use it as is. It won't work in the themes/default/skins/ folder without some further changes.

To put it on your main page you need to add the following to the top of your default.aspx file

<%@ Register TagPrefix="LatestForumPostsControl" TagName="LatestForumPosts" SRC="LatestForumPosts.ascx" %>

and then add this line to the page

<LatestForumPostsControl:LatestForumPosts Runat="Server" ID="Latestforumposts1" NAME="Latestforumposts1"/>

Recent Comments
This does not work for me. It's probably a silly error on my part. I noticed, though, that your directions need tweaking; latestForumsPosts.txt will need to be renamed to LatestForumPosts.ascx (singular Forum) and the Register TagPrefix cannot be placed twice on the /Default.aspx page as you suggest.

I look forward to getting this to work.

Before moving things around on my site the other day, I had a control working and thought it was yours. Alas, I do not have a backup for that page. Silly me.

Any thoughts on how your page is set would be appreciated.
Posted By: Anonymous Poster on Wednesday, August 03, 2005 4:45 PM
I've tweaked the instructions to note the file name differences.
Though I'm not sure where you are seeing that I say you must place the register tagprefix on the same page twice?
Posted By: Anonymous Poster on Wednesday, August 03, 2005 4:55 PM
Interesting, after you replied the second Register tag is gone. Hmm.. Anyway. Thanks for updating the instructions. I am placing the following on /Default.aspx;

<Blog:AggregatePostList runat="Server" />
<LatestForumPostsControl:LatestForumPosts runat="Server" ID="LatestForumPosts" NAME="LatestForumPosts"/>

The blog list shows but no forums code. I placed it on another site and it showed code until I did a refresh and nothing showed until I went into the forums and came back. I'm rebooting the server to see if something is confused :)

Sometimes an error is thrown. I will copy it to you too if it happens again.

Thank you for your help.
Posted By: Anonymous Poster on Wednesday, August 03, 2005 5:26 PM
Checked both sites and the control was working. Added a post to one site and the other one threw this error. The one I've seen a few times now.

Object reference not set to an instance of an object. This code is highlighted.

<br /> in <a href="<%# ForumUrls.Instance().Forum( ((Thread) Container.DataItem).SectionID ) %>">
Posted By: Anonymous Poster on Wednesday, August 03, 2005 5:30 PM
I can't say I've seen that error before :(
Posted By: Anonymous Poster on Wednesday, August 03, 2005 6:03 PM