YAFLogo

kainthedragoonx
15 years ago
Good afternoon,

Ok, I got 1.9.3 installed and upgraded my 1.9.1 database to 1.9.3. Now I am trying to build a site around the 1.9.3 site.

I've looked through the posts and tried to get the integration working. Basically what I want to do is use the YAF admin panel to manage the users and roles and groups...if that is possible. So I start building the site, and now I am experiencing some issues.

Two things right now: First, I cannot log in to the forums using any of the users that existed in the previous 1.9.1 forum app. My assumption is that I am doing something incorrect with the web.config file, but I've tried the "recommended Yaf Web.Config

...this:


		<roleManager enabled="true" defaultProvider="YafRoleProvider">
			<providers>
				<clear/>
				<add connectionStringName="yafnet" applicationName="YetAnotherForum" name="YafRoleProvider" type="YAF.Providers.Roles.YafRoleProvider"/>
			</providers>
		</roleManager>
		<membership defaultProvider="YafMembershipProvider" hashAlgorithmType="SHA1">
			<providers>
				<clear/>
				<add connectionStringName="yafnet" 
					 applicationName="YetAnotherForum" 
					 name="YafMembershipProvider" 
					 requiresUniqueEmail="true" 
					 useSalt="true" 
					 type="YAF.Providers.Membership.YafMembershipProvider"/>
			</providers>
		</membership>
		<profile enabled="true" defaultProvider="YafProfileProvider" inherits="YAF.Classes.Utils.YafUserProfile">
			<providers>
				<clear/>
				<add connectionStringName="yafnet" applicationName="YetAnotherForum" name="YafProfileProvider" type="YAF.Providers.Profile.YafProfileProvider"/>
			</providers>
		</profile>

and I attempted the standard SQL Provider, but it didn't work either.

So, question number 1:

What do I have to do to get it so that I can log into the forums?

Question number 2:

When I drill down to the actual topic, I recieve the following error:


 Value cannot be null.
Parameter name: type
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.ArgumentNullException: Value cannot be null.
Parameter name: type

Source Error:

Line 296:				{
Line 297:					// setup instance of the user profile...
Line 298:					_userProfile = PageContext.GetProfile( UserMembershipHelper.GetUserNameFromID( Convert.ToInt32( DataRow ["UserID"] ) ) );
Line 299:				}
Line 300:


Source File: c:\Inetpub\wwwroot\TTG\forums\controls\DisplayPost.ascx.cs    Line: 298 

my assumption is that both these errors are related...but I cannot seem to get this stuff figured out.

Obviously the goal is to get a single-sign-on application build and up and running.

I know everyone is busy as hell, and I thank everyone for helping me out!

Thanks

Kain


Sponsor
StereoHead
15 years ago
I am in the same situation here....

Value cannot be null.

Parameter name: type

Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.

Exception Details: System.ArgumentNullException: Value cannot be null.

Parameter name: type

Source Error:

Line 379: {

Line 380: // setup instance of the user profile...

Line 381: _userProfile = PageContext.GetProfile( UserMembershipHelper.GetUserNameFromID( UserId ) );

Line 382: }

Line 383:

I have set the role, membership and profile providers to the normal asp.net ones (except i left the inherits="YAF.Classes.Utils.YafUserProfile" because it needs that right?)

I can login to yaf with my existing users that registered on the site, but when i try to view a topic i get the error above.

This is the final hurdle in getting YAF fully working with our site and would really appreciate any help that can be offered.

Mek
  • Mek
  • 100% (Exalted)
  • YAF Developer
15 years ago
where are you grabbing UserID?

If you do a throw new applicationException on the UserID.ToString() does it output a value?

Edit: And apologies to Kain for missing his thread from way back in 2008.


UserPostedImage

"It's a case of RTFM.. the only problem being we don't have a manual!"

When I post FP:Mek in a topic, I'm leaving my footprint there so I can track it once I get into coding/supporting. (Yes I stole this off Ederon 🙂 )