Products

Solutions

Resources

Partners

Community

Blog

About

QA

Ideas Test

New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

Welcome to the DNN Community Forums, your preferred source of online community support for all things related to DNN.
In order to participate you must be a registered DNNizen

HomeHomeDevelopment and...Development and...DNN Platform (o...DNN Platform (o...IWeb ModuleIWeb Module
Previous
 
Next
New Post
4/17/2009 11:14 AM
 

 I recently installed the IWeb module which also installed the standard web services that come with that module.  However, I can't seem to get the web services working.  I am trying to execute certain web methods of the standard web services through the browser, but they don't seem to be working.  For instance, there is a GetUser method that takes a UserName parameter and returns user info (their membership details, profile details, etc).  I tried to execute this function through IE, Chrome, and Firefox browsers, but each time it returned "object reference not set to an instance of an object".

Am I doing something wrong?  I just installed the IWeb module and did nothing special - just tried to execute some of the standard methods that come with it.  I also tried executing the CreateUser method and passed in all of the relevant values, but that also did not work.  Do I need to installed something else in addition to the IWeb module in order to get the web services working?

Here's the whole XML error message:

  <?xml version="1.0" encoding="utf-8" ?>
- <UserInfo xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://webservices.DotNetNuke.com/">
  <AffiliateID>-1</AffiliateID>
  <IsSuperUser>false</IsSuperUser>
- <Membership>
  <Approved>true</Approved>
  <CreatedDate>0001-01-01T00:00:00</CreatedDate>
  <IsOnLine>false</IsOnLine>
  <LastActivityDate>0001-01-01T00:00:00</LastActivityDate>
  <LastLockoutDate>0001-01-01T00:00:00</LastLockoutDate>
  <LastLoginDate>0001-01-01T00:00:00</LastLoginDate>
  <LastPasswordChangeDate>0001-01-01T00:00:00</LastPasswordChangeDate>
  <LockedOut>false</LockedOut>
  <ObjectHydrated>true</ObjectHydrated>
  <UpdatePassword>false</UpdatePassword>
  <Username>Object reference not set to an instance of an object.</Username>
  </Membership>
  <PortalID>-1</PortalID>
- <Profile>
  <ObjectHydrated>true</ObjectHydrated>
- <ProfileProperties>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Name</propertycategory>
  <propertyname>Prefix</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Name</propertycategory>
  <propertyname>FirstName</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Name</propertycategory>
  <propertyname>MiddleName</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Name</propertycategory>
  <propertyname>LastName</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Name</propertycategory>
  <propertyname>Suffix</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Address</propertycategory>
  <propertyname>Unit</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Address</propertycategory>
  <propertyname>Street</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Address</propertycategory>
  <propertyname>City</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>0</length>
  <propertycategory>Address</propertycategory>
  <propertyname>Region</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>0</length>
  <propertycategory>Address</propertycategory>
  <propertyname>Country</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Address</propertycategory>
  <propertyname>PostalCode</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Contact Info</propertycategory>
  <propertyname>Telephone</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Contact Info</propertycategory>
  <propertyname>Cell</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Contact Info</propertycategory>
  <propertyname>Fax</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Contact Info</propertycategory>
  <propertyname>Website</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>50</length>
  <propertycategory>Contact Info</propertycategory>
  <propertyname>IM</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>0</length>
  <propertycategory>Preferences</propertycategory>
  <propertyname>Biography</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>0</length>
  <propertycategory>Preferences</propertycategory>
  <propertyname>TimeZone</propertyname>
  </ProfilePropertyDefinition>
- <ProfilePropertyDefinition>
  <length>0</length>
  <propertycategory>Preferences</propertycategory>
  <propertyname>PreferredLocale</propertyname>
  </ProfilePropertyDefinition>
  </ProfileProperties>
  <TimeZone>-1</TimeZone>
  </Profile>
  <Roles />
  <UserID>-1</UserID>
  <Username>Object reference not set to an instance of an object.</Username>
  </UserInfo>

 
New Post
4/17/2009 7:22 PM
 

You will get the "Object reference not set to an instance of an object." if you request a user that does not exist or you have not entered the password and supplied it correctly. You also have to specify a valid portal nuber (usually 0)

Set the security on this screen:

 



Michael Washington
http://ADefWebserver.com
www.ADefHelpDesk.com
A Free Open Source DotNetNuke Help Desk Module
 
New Post
4/21/2009 8:48 AM
 

Michael,

I am calling the GetUser method for an existing user here.  Here are the steps I am following:

  1. I am logged in as the host
  2. I created a new user called "User1" under "Admin --> User Accounts".  I can see this new user in my user account list.  I also logged in with this username and verified that this user was indeed a valid user
  3. I went to the "Configure IWeb" screen you pasted above and for the "GetUser" method, I set the security setting to "Registered Users"
  4. Went to the standard web service's "GetUser" method and entered "User1" as the input parameter and clicked on "Invoke"
  5. Got the "object reference not set to an instance of an object" error (that I pasted in the first post of this thread)

Any ideas?

 
New Post
4/26/2009 8:45 PM
 

VishalG wrote
 

I am logged in as the host

  1. I created a new user called "User1" under "Admin --> User Accounts".  I can see this new user in my user account list.  I also logged in with this username and verified that this user was indeed a valid user
  2. I went to the "Configure IWeb" screen you pasted above and for the "GetUser" method, I set the security setting to "Registered Users"
  3. Went to the standard web service's "GetUser" method and entered "User1" as the input parameter and clicked on "Invoke"
  4. Got the "object reference not set to an instance of an object" error (that I pasted in the first post of this thread)

Did you enter the proper portal number and supply a username and password of a registered user? These are passed in a IWeb Authendication header. That's why we supply a Windows client to use for testing.

Also, what version of DNN are you using?

 



Michael Washington
http://ADefWebserver.com
www.ADefHelpDesk.com
A Free Open Source DotNetNuke Help Desk Module
 
Previous
 
Next
HomeHomeDevelopment and...Development and...DNN Platform (o...DNN Platform (o...IWeb ModuleIWeb Module


These Forums are dedicated to discussion of DNN Platform and Evoq Solutions.

For the benefit of the community and to protect the integrity of the ecosystem, please observe the following posting guidelines:

  1. No Advertising. This includes promotion of commercial and non-commercial products or services which are not directly related to DNN.
  2. No vendor trolling / poaching. If someone posts about a vendor issue, allow the vendor or other customers to respond. Any post that looks like trolling / poaching will be removed.
  3. Discussion or promotion of DNN Platform product releases under a different brand name are strictly prohibited.
  4. No Flaming or Trolling.
  5. No Profanity, Racism, or Prejudice.
  6. Site Moderators have the final word on approving / removing a thread or post or comment.
  7. English language posting only, please.
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out