Visual Studio 2008

330 views
Skip to first unread message

Alex Figueiredo

unread,
Apr 13, 2012, 8:19:40 AM4/13/12
to jui...@googlegroups.com
How can I use JuiceUI with Visual Studio 2008?

Andrew Powell (appendTo)

unread,
Apr 13, 2012, 9:07:43 AM4/13/12
to jui...@googlegroups.com
At the moment, JuiceUI is built on .NET 4.0. Unfortunately VS2008 doesn't support .NET 4.0.

Visual Studio 2008 is over four years old now. If possible, I'd highly recommend upgrading, asking for an upgrade from your employer or using one of the Express development tools that are free to download from Microsoft. You'll still be able to maintain .NET 2, 3, and 3.5 projects with the newer version of VS.

John Kattenhorn

unread,
Apr 17, 2012, 8:40:46 AM4/17/12
to jui...@googlegroups.com
Hi,

I have a web application which is no allowed to be upgraded from .Net 3.5 SP1 to .Net 4.0; so I use VS2010 but I'd like to second that it would be great to have a 3.5 version of Juice.

Thanks

John

Andrew Powell (appendTo)

unread,
Apr 17, 2012, 9:03:51 AM4/17/12
to jui...@googlegroups.com
Many changes to the code would be necessary to support 3.5. What we'd end up having to do is maintaining two separate versions of the project and releasing two separate versions every time we did a release. Unfortunately this is not something we can support at this time.

If you'd like, I'd be happy to help you through building your own copy to support 3.5. You'll have to fork the project at github and maintain the 3.5 copy in your own fork. The first step once you have your own fork of JuiceUI would be to change the target .NET version in the project properties and attempt a build. You'll get a lot of build errors. If you post these errors, I can tell you how to resolve them. It'll be a process, but you'll end up with your own functioning version for 3.5.

John Kattenhorn

unread,
Apr 17, 2012, 9:17:04 AM4/17/12
to jui...@googlegroups.com
Hi,

I've already done this and started to investigate the compiler errors; it's not too bad I hope; here is the output :

Error 1 The type or namespace name 'Concurrent' does not exist in the namespace 'System.Collections' (are you missing an assembly reference?) C:\Development\Projects\JuiceUI\Juice\Framework\JuiceWidgetState.cs 2 26 JuiceUI
Error 2 The type or namespace name 'PreApplicationStartMethodAttribute' does not exist in the namespace 'System.Web' (are you missing an assembly reference?) C:\Development\Projects\JuiceUI\Juice\JuiceApp.cs 8 23 JuiceUI
Error 3 The type or namespace name 'PreApplicationStartMethod' does not exist in the namespace 'System.Web' (are you missing an assembly reference?) C:\Development\Projects\JuiceUI\Juice\JuiceApp.cs 8 23 JuiceUI
Error 4 The type or namespace name 'ScriptResourceDefinition' could not be found (are you missing a using directive or an assembly reference?) C:\Development\Projects\JuiceUI\Juice\Framework\CssResourceDefinition.cs 8 39 JuiceUI
Error 5 The type or namespace name 'ScriptResourceMapping' could not be found (are you missing a using directive or an assembly reference?) C:\Development\Projects\JuiceUI\Juice\Framework\CssResourceMapping.cs 9 36 JuiceUI
Error 6 The type or namespace name 'ConcurrentDictionary' could not be found (are you missing a using directive or an assembly reference?) C:\Development\Projects\JuiceUI\Juice\Framework\JuiceWidgetState.cs 21 27 JuiceUI

This mostly seems to be related to new functionality in the ScriptManager in .Net 4.0. I was considering defining an interface which allow me to wrap functionality from the ScriptManager and then build a 3.5 implementation of the interface. 

Unfortunately the ScriptManager in 3.5 the update panel and having to support both JQuery and AjaxToolkit controls at the same time was the reason I came searching for JuiceUI in the first place! And just to make it even harder all of these controls are rendered dynamically in code!

Any pointers you could give me would be much appreciated as I'm under some time pressure (aren't we all) :-)

Thanks 

Andrew Powell (appendTo)

unread,
Apr 17, 2012, 9:41:30 AM4/17/12
to jui...@googlegroups.com
When we analyzed what it would take to do this internally, we settled on the practice of 'extending' the missing methods and such as the best route to take. It would allow for the least amount of friction as new versions of JuiceUI are released. You're basically filling the holes in 3.5. (What the javascript community calls a "polyfill")

I'll try to itemize these for you:

Concurrent Collections - Basically a thread-safe collection. http://msdn.microsoft.com/en-us/library/system.collections.concurrent.aspx Your best bet is to take something like this thread-safe dictionary implementation http://www.grumpydev.com/2010/02/25/thread-safe-dictionarytkeytvalue/ and re-work the naming and any method/property names to match the Concurrent implementation in .NEt 4.0.

PreApplicationStartMethod - This defines what should run even before App_Start is executed. This one will be a little trickier to implement and may involve forcing users to add code to their Global.asax(.cs) file. I don't have a solid suggestion for you on this one other than recommending than to leave the current code in place and create classes to compensate for the missing ones, and just use that code in whatever your final solution is.

ScriptResourceMapping & ScriptResourceDefinition - This is where the big differences come into play. Again, the best route is to extend ScriptManager to handle these methods. These classes are relatively small and can be pulled verbatim from .NET 4 through a tool like Reflector (though I try not to recommend that tool after RedGate took it over). The trick is wiring up the other methods to tie into the correct methods in .NET 3.5.


Reply all
Reply to author
Forward
0 new messages