Themes with dropthings (WF and LINQ help needed!)

Apr 8, 2008 at 8:03 AM
Edited Apr 8, 2008 at 9:48 AM

What I'm trying to do: Allow users to also apply a theme to dropthings.

What I've done: First I tried having a profile property Theme but it didn't seem to persist across sessions or postbacks. Maybe I did something wrong? What would you have to do to add a new Profile property in this project that persisted in the database? I edited UserProfile.cs and intellisense found the property, just for some reason it didn't persist and when I looked in the database the only property was IsFirstVisit.

So, I gave up on that and decided that it was better to have it as a user setting anyway in the database. I've added a theme property to the dbo.UserSetting table, I've implemented the themes in .NET using CSS, all works fine.

Now, I want to remain loyal to the architecture of this system, using WF etc. I've managed to get the IntranetWidgetDataSet.xsd and Dashboard.dbml files so they recognise the new Theme property by dragging and dropping the datasource (database) onto the canvas. I've had a go at the Workflow bit- but got a bit stuck. Can anyone help me?

1. LINQ side: Do I have to recompile anything with sqlmetal, if so how do I do this?

2. WF side: All that would be required would be one workflow: ChangeTheme with basically one activity to change the value in the database that the user selects. Can anyone give me any pointers? It would be greatly appreciated! I've tried creating my own workflows- my own activity isn't appearing in the list of activities?!

I promise when I get my project up and running (I'm using Dropthings as an Intranet site using Windows authentication with themes and custom widgets) I will write it all up in my blog to help everyone else!



P.S. I love the project- it looks and works great and users seem to really like it!

Apr 8, 2008 at 1:47 PM
Ignore my ramblings! I've figured it out- always do after posting on forums/ discussion groups... but I will still write-up after I've completed my project!
Aug 13, 2008 at 1:54 AM
Hi lilalfyalien.

I'd be very interested in knowing how you setup themes in your application as I'm working on the same feature but unfortunately, keep getting stuck.