Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Integration w existing asp.net 4 VS2010 vb web application
Carnac
#1 Posted : Friday, 23 July 2010 7:51:42 AM(UTC)
Rank: Member

Joined: 23/07/2010(UTC)
Posts: 4
Location: Costa Rica

Hi Roger,

SEE UPDATES TO THIS POST BELOW!

I just downloaded your code the other day and I feel so close to getting it. I'm trying to use GSP as a usercontrol and plug it into my existing app and existing sql server db. I'm pretty much stuck with these two errors after building my project:

Warning 1 The element 'system.web' has invalid child element 'galleryServerPro'. List of possible elements expected: 'anonymousIdentification, authentication, authorization, browserCaps, clientTarget, compilation, customErrors, deployment, deviceFilters, fullTrustAssemblies, globalization, healthMonitoring, hostingEnvironment, httpCookies, httpHandlers, httpModules, httpRuntime, identity, machineKey, membership, mobileControls, pages, partialTrustVisibleAssemblies, processModel, profile, roleManager, securityPolicy, sessionPageState, sessionState, siteMap, trace, trust, urlMappings, webControls, webParts, webServices, xhtmlConformance, caching'.

and

Error 16 Type 'GalleryServerPro.Web.Gallery' is not defined. C:\xxx\Gallery.aspx.designer.vb 23 33 Seaside2.1

I have read the admin guide cover-to-cover and searched your forums including:

http://www.galleryserver...yserverproconfiggt.aspx

and

http://www.galleryserver...scx-does-not-exist.aspx

After following the instructions carefully and attempting a build I first got WindowsBase, Core, WPF reference errors as noted here (http://www.galleryserverpro.com/forum/yaf_postst1114_Integration-issues-with-existing-ASPNet-website.aspx).

I excluded all folders within my "_gs" directory inside my existing vb web application per your instructions in the reply to the above thread and that got rid of the references error, but now I still get errors at build time. On attempting to run my "gallery.aspx" page in a browser, I get a "Could not load type ..." error.

I'm not looking to lose any karma points although I would be indebted to those with some extra Karma to throw my way to help me out.

Regards,
A GSP newbie

UPDATED: I have torn my hair out over this application. Basically, with regards to Visual Studio 2010 and .net 4, if one follows the instructions (to integrate w/ existing site and existing db) in the admin guide perfectly, this application will not work. It will not compile.

This site says you don't have to add references to your app. Well, adding references was the only way for me to even get it to recognize GallleryServerPro.Web.Gallery. Once I added the references (and excluded all the folders in the gs directory), I finally got the app to compile and go through the install wizard. However, after the install completed successfully, my page with the user control will not work. It throws the error:

Could not load file or assembly 'AjaxControlToolkit, Version=1.0.10920.32880, Culture=neutral, PublicKeyToken=28f01b0e84b6d53e' or one of its dependencies....

The admin guide says if you have .net 3.5 or higher that you don't need ajax 1.0. What gives? What can I do to fix this? I tried to add code like this based on posts in the forum:

Code:
    <runtime>
        <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1" appliesTo="v2.0.50727">
            <dependentAssembly>
                <assemblyIdentity name="AjaxControlToolkit" publicKeyToken="28f01b0e84b6d53e" />
                <bindingRedirect oldVersion="1.0.0.0-1.1.0.0" newVersion="4.1.40412.0" />
            </dependentAssembly>
        </assemblyBinding>
    </runtime>


But, that doesn't seem to work either. Same error. I tried to see which ajax version I have by viewing the properties of the AjaxToolKit in my references. I already have the AjaxTookKit in my existing project as a reference so I didnt copy the one from the bin folder.

Please help!!! I don't have many hairs left!

Regards,
-Carnac





Roger Martin
#2 Posted : Monday, 26 July 2010 8:57:46 AM(UTC)
Roger Martin

Rank: Administration

Joined: 3/08/2007(UTC)
Posts: 3,300
Location: Fort Atkinson, WI

Your post prompted me to spent today investigating the issue. See my blog post for full details.
Roger Martin
Creator and Lead Developer of Gallery Server Pro
Carnac
#3 Posted : Tuesday, 27 July 2010 9:54:54 AM(UTC)
Rank: Member

Joined: 23/07/2010(UTC)
Posts: 4
Location: Costa Rica

Roger,

Thank you so much for writing that blog post! I felt like it was just for me!!!

As I have been working non stop on my application the last few days, I had to move forward without a fix. So, I managed to get it working in my 4.0 app ONLY by going back to AJAX 1.0.

Since my app didn't use ajax (as much as it should I might add) much, I just dealt with it for the time being. It did manage to break all my rounded corners extenders, by the way.

Now that I've seen your new post, I'm trying to figure out what I did wrong. Perhaps I didn't put the dependent assembly bindings at the end of my web.config? In any case, thanks to you I now have it working with AJAX 4 and my app looks great again!

Thanks for taking the time to update things. It was really frustrating, but given the features of your app I think it is still going to be worth the effort in the end. I'm moving on to integrating my existing roles and existing users. I have it hooked up to my custom SQL profile provider--I had to add your 3 profile property fields (UserAlbumId, EnableUserAlbmum, ShowMediaObject) to my "get_profile" and "set_profile" SQL Server stored procedures that handle data from the provider. Easy enough and it works fine.

I'm not going to bother you any more unless I really have to. I will perusing the admin guide to figure out how to create useralbums for my existing users and to integrate my existing roles.

Muchas gracias! Pura vida!
-e
Carnac
#4 Posted : Wednesday, 28 July 2010 8:18:32 AM(UTC)
Rank: Member

Joined: 23/07/2010(UTC)
Posts: 4
Location: Costa Rica

Hi Roger et al,

Just reporting back so everyone can learn from my experience with integrating GSP into my existing .net 4 vb web app.

I'm getting a few AJAX errors. Specifically, I'm getting the following:

1.)
Webpage error details
User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET CLR 3.5.21022; .NET4.0C; .NET4.0E; Media Center PC 5.0; SLCC1; InfoPath.3; MS-RTC LM 8)

Message: 'AjaxControlToolkit' is undefined
Line: 169
Char: 3
Code: 0
URI: http://seaside21/Gallery.aspx?moid=9

This error occurs when I click on a thumbnail image to view the compressed image (I increased maxlength to 870). The error message above is clipped from IE, but I get the same error (and a bunch of other warnings) in Firefox 3.0.10.


2.)
Webpage error details
User Agent: Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 6.1; Trident/4.0; SLCC2; .NET CLR 2.0.50727; .NET CLR 3.5.30729; .NET CLR 3.0.30729; Media Center PC 6.0; .NET CLR 3.5.21022; .NET4.0C; .NET4.0E; Media Center PC 5.0; SLCC1; InfoPath.3; MS-RTC LM 8)

Message: 'AjaxControlToolkit' is undefined
Line: 169
Char: 3
Code: 0
URI: http://seaside21/Gallery.aspx?moid=73&msg=30

Looks like same error. It happens when attempting to rotate an image at the leaf image level. The onscreen message says the rotation was successful, but the ajax error is still thrown. everything seems to work fine despite the error.

3.) FYI, I'm not sure if this is an error or not...
On attempting to rotate multiple images at once in an album while viewing the thumbnails, I click on the UP box on several images and then click the Rotate Button. But, two things happen that I don't expect. First, the success message is "Media objects successfully rearranged... " and NOT "rotated". Second, on the page displayed with the success message the thumbnails of the images I rotated are not rotated. When I click on the non-rotated thumbnail of the image I just rotated, the displayed compressed image is rotated properly. Perhaps a resynch is required? NOPE. I just tried the sycnh with overwrite thumbnails and the thumbs are not rotated. The ajaxtoolkit error also throws here too.

These are minor issues, but I just want to pass it on.

Pura vida,
-Carnac





Roger Martin
#5 Posted : Wednesday, 28 July 2010 8:29:38 AM(UTC)
Roger Martin

Rank: Administration

Joined: 3/08/2007(UTC)
Posts: 3,300
Location: Fort Atkinson, WI

Have you downloaded the sample .NET 4 project from my blog post? If you don't see the javascript errors there, maybe it will help you find out what is different about your app.

Regarding the rotating issue, hit F5 in your browser after rotating. I think you are just seeing the cached images from your browser.
Roger Martin
Creator and Lead Developer of Gallery Server Pro
Carnac
#6 Posted : Saturday, 31 July 2010 5:30:11 AM(UTC)
Rank: Member

Joined: 23/07/2010(UTC)
Posts: 4
Location: Costa Rica

Thanks again Roger.

I deleted everything in my galleries and re-synched. Since then, I have not encountered the rotate issue again. However, at the time I was definitely pressing f5 or cntrl-r attempting to refresh the page. Additionally, per another post on your forum, I'm calling your flush cache method on logouts.

I'm still getting the AJAX errors, but no functionality seems to be affected. I've been diverted to another function point presently, but I plan to revisit this issue before going to production and I will make use of your sample 4.0 project per your suggestion.

Thanks again for your support.

Pura vida,
-carnac
Rss Feed  Atom Feed
Users browsing this topic
Guest
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.