473,569 Members | 2,762 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

membership/roles create user problem

Hi

I have a web service asmx file in a sub folders of site app root folder.
With in the web service I am trying to cerate the user as below;

<WebMethod()_
Public Function CreateUser(ByVa l Username As String, ByVal Password As
String, ByVal Email As String, ByRef ErrMsg As String) As Boolean

Dim newUser As MembershipUser = Membership.Crea teUser(Username , Password,
Email, passwordQuestio n, passwordAnswer, True, status)
If (newUser Is Nothing) Then
ErrMsg = GetErrorMessage (status)
CreateUser = False
true
CreateUser = True
End If
End Function

The user seems to be created fine but it does not appear in the Web Site
Administration Tool list of users. When I look in the aspnet db, the user is
created in the vw_aspnet_Users table but not in any of the rest of the
tables such as vw_aspnet_Membe rshipUsers.

What is wrong and how can it be fixed?

Thanks

Regards
Aug 28 '06 #1
3 1806
I think I have cracked this one.

Thanks

Regards

"John" <Jo**@nospam.in fovis.co.ukwrot e in message
news:%2******** ********@TK2MSF TNGP05.phx.gbl. ..
Hi

I have a web service asmx file in a sub folders of site app root folder.
With in the web service I am trying to cerate the user as below;

<WebMethod()_
Public Function CreateUser(ByVa l Username As String, ByVal Password As
String, ByVal Email As String, ByRef ErrMsg As String) As Boolean

Dim newUser As MembershipUser = Membership.Crea teUser(Username , Password,
Email, passwordQuestio n, passwordAnswer, True, status)
If (newUser Is Nothing) Then
ErrMsg = GetErrorMessage (status)
CreateUser = False
true
CreateUser = True
End If
End Function

The user seems to be created fine but it does not appear in the Web Site
Administration Tool list of users. When I look in the aspnet db, the user
is created in the vw_aspnet_Users table but not in any of the rest of the
tables such as vw_aspnet_Membe rshipUsers.

What is wrong and how can it be fixed?

Thanks

Regards

Aug 28 '06 #2
What was it?

"John" <Jo**@nospam.in fovis.co.ukwrot e in message
news:Oa******** *****@TK2MSFTNG P06.phx.gbl...
>I think I have cracked this one.

Thanks

Regards

"John" <Jo**@nospam.in fovis.co.ukwrot e in message
news:%2******** ********@TK2MSF TNGP05.phx.gbl. ..
>Hi

I have a web service asmx file in a sub folders of site app root folder.
With in the web service I am trying to cerate the user as below;

<WebMethod() _
Public Function CreateUser(ByVa l Username As String, ByVal Password As
String, ByVal Email As String, ByRef ErrMsg As String) As Boolean

Dim newUser As MembershipUser = Membership.Crea teUser(Username , Password,
Email, passwordQuestio n, passwordAnswer, True, status)
If (newUser Is Nothing) Then
ErrMsg = GetErrorMessage (status)
CreateUser = False
true
CreateUser = True
End If
End Function

The user seems to be created fine but it does not appear in the Web Site
Administrati on Tool list of users. When I look in the aspnet db, the user
is created in the vw_aspnet_Users table but not in any of the rest of the
tables such as vw_aspnet_Membe rshipUsers.

What is wrong and how can it be fixed?

Thanks

Regards


Aug 29 '06 #3
Actually the method Membership.Crea teUser(Username , Password,Email,
passwordQuestio n, passwordAnswer, True, status) was failing and user was not
being properly created. I used Membership.Crea teUser(Username ,
Password,Email) variation as I did not need/use passwordQuestio n ,
passwordAnswer etc. and it worked.

Regards
"Ken Cox [Microsoft MVP]" <BA**********@n ewsgroups.nospa mwrote in message
news:e2******** ******@TK2MSFTN GP05.phx.gbl...
What was it?

"John" <Jo**@nospam.in fovis.co.ukwrot e in message
news:Oa******** *****@TK2MSFTNG P06.phx.gbl...
>>I think I have cracked this one.

Thanks

Regards

"John" <Jo**@nospam.in fovis.co.ukwrot e in message
news:%2******* *********@TK2MS FTNGP05.phx.gbl ...
>>Hi

I have a web service asmx file in a sub folders of site app root folder.
With in the web service I am trying to cerate the user as below;

<WebMethod( )_
Public Function CreateUser(ByVa l Username As String, ByVal Password As
String, ByVal Email As String, ByRef ErrMsg As String) As Boolean

Dim newUser As MembershipUser = Membership.Crea teUser(Username ,
Password, Email, passwordQuestio n, passwordAnswer, True, status)
If (newUser Is Nothing) Then
ErrMsg = GetErrorMessage (status)
CreateUser = False
true
CreateUser = True
End If
End Function

The user seems to be created fine but it does not appear in the Web Site
Administratio n Tool list of users. When I look in the aspnet db, the
user is created in the vw_aspnet_Users table but not in any of the rest
of the tables such as vw_aspnet_Membe rshipUsers.

What is wrong and how can it be fixed?

Thanks

Regards



Aug 29 '06 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
1387
by: artificer | last post by:
I want to create an Internet application that will be accessed by several pre-registered companies. All of those companies will be accessing the same database and the same application but each one of them will only access the records that belong to their company. Another complication is that not all user of a company will access all the forms...
2
1228
by: Demetri | last post by:
I have several questions regarding the Membership and Roles mechanism in ASP.Net 2.0. 1. In the box, it comes with SqlMembershipProvider, which uses SQL Express 2005. What if I want it to use SQL Server 2005 Enterprise (not express) instead? I'm really hoping I don't have to write my own MembershipProvider to accomplish this. 2. My users...
5
1656
by: JP.Gantlin | last post by:
I want to have a login page where the new user self-registers, giving some simple info like Real Estate Agent #. Do I need to used the membershiop/roles thing, or profiles? Are profiles part of the membership thing, or how are they tied together? Thanks
4
3259
by: AC | last post by:
Hi there. My asp.net 2.0 development website uses roles to control access to sections of my site, configured using the asp.net configuration tool, which is great. Except that isn't available once published on the public, third-party hosted site. So I need to be able to configure access through a new section of the site, available only to...
5
2899
by: Mahernoz | last post by:
Hi Everyone! I have a problem here. I have used the latest asp.net membership & profiles functionality in my site. I have 2 roles admin and user. I also have a user named admin. Now, my website is running perfectly, but i want to deploy it.
3
2170
by: Glenn | last post by:
My current classic-ASP site has users, projects, roles and the 2.0 membership looks like a perfect fit, but I'm having trouble finding examples of how to have users that belong to different projects, and have different roles per project. The current model.. * When a user joins my site, they eventually end up joining or creating one or...
4
8214
by: alexandis | last post by:
There are tons of articles about custom role and provider membership, but they just tear me apart and confuse :( The situation is following: I use DB2, so I wrote custom role + membership providers. Membership provider seems to work. I use forms authentication, so as articles say, I need to do some magic to be able to get roles for current...
1
2934
by: =?Utf-8?B?aGZkZXY=?= | last post by:
Hello, I have a web application that makes use of the SQL Membership and Role providers. My app has admin screens to manage users (membership), roles, and supplementary user data. I have just deployed the application to a production server. My Question: How do I create the initial Admin role and user in the clean/unpopulated database...
6
2920
by: Jonathan Wood | last post by:
Although this will be a challenge at my level of ASP.NET knowledge, I'm thinking I should implement my own membership provider class. Looking over the methods I must implement, a number of questions come to mind. 1. How would one implement GetNumberOfUsersOnline? I'm not sure where there is any indication of this? And it this affected by...
3
1782
by: dm3281 | last post by:
Hello -- I need to write an ASP.NET 2.0 application for our clients to use to login and verify file transmissions. Each client will need their own logon, in addition to a way to assign each user a unique customerid. All users beloning to the same custeromid would see the same information on the website. Can I easily do this using...
0
7609
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
7921
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. ...
0
8118
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
0
7964
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the...
0
6278
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
1
5504
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes...
0
3651
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
0
3636
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
936
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.