Sunshine81
2011-11-29T14:52:38Z
Hi,

After having inherited a YAF installation that was partially working, and spending many hours banging my head against the screen trying to get it to work and failing I've decided to start from scratch and try a fresh install of YAF. It's got to integrate with our Sitecore website.

I've been using this documentation 

However I can't help but notice that it was written in 2009 and could therefore be out of date.

I'm trying to use v1.9.5.5 RTW SRC because according to the documentation I need to make changes to the source to get it working inside Sitecore. Though the documentation does not say explicitly I'm assuming I should open the YAf project, make the changes I need to, compile it and then use the DLLs in my sitecore project. Is that correct or did I miss something?

I have several issues following section 3 - Changes to Source Code.


3.1 - I make the YafUserProfile inherit Sitecore.Security.UserProfile. I then add a reference to Sitecore.Kernel but I get the error:
Quote:

Assembly generation failed -- Referenced assembly 'Sitecore.Kernel' does not have a strong name


Searched all over. Looks like I need to give the DLL a strong name, though I cannot find a Visual Studio (2010 Pro) command prompt to do so. The above documentation makes no reference of this step so I'm wondering where they pulled their reference from? I know this isn't a YAF issue but I was wondering if anyone else had run into this one and had a solution?


3.2 - SitecoreMembershipUser and SitecoreDomainManager. Where are these classes? Can't find them anywhere? Have they been removed?


We really want to use YAF, it does everything we want it to do and if we can get it working, it'll sit perfectly inside Sitecore. Tearing my hair out and hoping that some of the devs can guide me in the right direction! I might be doing something stupid, but I have years of .NET experience and can't see through this one.
Sponsor
tha_watcha
2011-11-29T15:19:49Z
Originally Posted by: Sunshine81 

3.1 - I make the YafUserProfile inherit Sitecore.Security.UserProfile. I then add a reference to Sitecore.Kernel but I get the error:

Quote:

Assembly generation failed -- Referenced assembly 'Sitecore.Kernel' does not have a strong name


Searched all over. Looks like I need to give the DLL a strong name, though I cannot find a Visual Studio (2010 Pro) command prompt to do so. The above documentation makes no reference of this step so I'm wondering where they pulled their reference from? I know this isn't a YAF issue but I was wondering if anyone else had run into this one and had a solution?



You need to Compile the dll Sitecore.Kernel with a AssemblyKeyFile

[assembly: AssemblyKeyFile("..\\YetAnotherForum.NET.snk")]

Or Remove the Line from YAF and compile yaf without the Key Files.

Ps i didnt know Sitecore but why did you need to modify yaf for it to use the Sitecore.Security.UserProfile i am sure you can change that via the Membership Provider String in the web.config-
UserPostedImage
Sunshine81
2011-11-29T15:28:02Z
Well I was doing it that way because the guide told me to. I've downloaded 1.9.3 and I can see that there are some big changes which kind of render the guide I'm using out of date. However upgrading 1.9.3 to .NET 3.5 has given me a whole set of other errors so I feel I'm caught between a rock and a hard place!

I'd happily write an integration guide for the latest YAF version if I can get it working! I'm at somewhat of a disadvantage in that I'm new to Sitecore though I do have a solid understanding of .NET.

I'll give what you saya go and report back.

EDIT:
Okay removing the solves the 'Sitecore.Kernel' does not have a strong name errors. Perfect, thanks!

I needed to add references to Sitecore.Kernel to these projects:
YAF.Utils
YAF.Core
YAF.Controls
YAF

If I set the YafUserProfile up as such the project builds:
public class YafUserProfile : Sitecore.Security.UserProfile, IYafUserProfile

Not run it yet but it does build.

I'll take the next steps and see how I get on, thanks for the help so far.
reyrahadian
2012-07-24T00:34:00Z
Hey @tha_watcha and @Sunshine81,

i'm also trying to integrate YAF 1.9.6.1 with Sitecore and having trouble on solving the strong name issue.

which line of code should i remove so that the code compiles ?

EDIT:

found it, you need to remove the strong name statement in each projects AssemblyInfo.cs file
priyamkj
2015-03-30T06:36:41Z
Hey ,

I am trying to integrate YAF 2.2.0 and Sitecore 7.5 . Were you able to figure out what these classes are ?

SitecoreMembershipUser and SitecoreDomainManager

Thanks in advance .

About Us

The YAF.NET is an open source .NET forum project. YAF.NET is supported by an team of international developers who are build community by building community software.

Powered by Resharper Donate with PayPal button

Project Twitter Updates

Copyright © YetAnotherForum.NET & Ingo Herbote. All rights reserved