How To Get A Profile Of A Newly Created User

Aug 16, 2010

I am trying to handle add a custom field to a user profile using CreateUserWizard.
I added the field to web.config as

<profile defaultProvider="SqlProvider">
<providers>
<add name="SqlProvider" type="System.Web.Profile.SqlProfileProvider" connectionStringName="db"
[code]...

And added a ListBox to the template of CreateUserWizard. I wanted to add the information to the profile in the CreateUserWizard_UserCreated event. I can retrive values, but I can't figure out how to retrive the ProfileBase of the newly created user.

View 1 Replies


Similar Messages:

C# - Tying MembershipUser And Web.Profile Together For Newly Created Users

Oct 30, 2010

I am using ASP.NET MVC 3. I am using what essentially came with for free in the Visual Studio project template for an MVC project with the "Internet Application" option. Basically this brings in Forms authentication and provides some basic elements to manage user login and stuff.

I am also using the web profiles stuff with this to store some custom fields. Everything was going great. I use SuperFunProfile as a wrapper around the Profile instance to make it easier to get at profile properties. Until I wanted to set a property of a Profile right away after signing the user up.The problem I can't solve is that this.Request.RequestContext.HttpContext.Profile contains the profile for the anonymous user. How can I get a new profile for the user now that he should be signed up and signed in?

public ActionResult SignUp(SignUpModel model)
{
if (ModelState.IsValid)
{
[code]....

I poked around Membership and Web.Profile, but I am not seeing anything that looks like it will get me closer to my goal.Maybe I should just create a ProfileModel that I store myself into the DB rather than using Web.Profile? I could key that on MembershipUser.ProviderUserKey which would make it easier to create a ProfileModel at sign up, I suppose.

View 1 Replies

Security :: Userid Of Newly Created User / To Store Additional Details Of The User In Another Database Table

Nov 10, 2010

Our application lets the administrator create new users. Since the administrator is logged in, I have set Logincreateduser = false so that the administrator is not logged out even after creating the new user.

The problem is :I need the userid of the newly created user to store additional details of the user in another database table. I see that i can get the username using Createuserwizard1.username; but how do I get the userID?

View 2 Replies

Security :: Getting The UserID Of The Newly Created User

Feb 15, 2011

I have created my own form for creating a new user and collecting data, I just need to do one thing, find the UserID of the newly created user before they have logged in

Here is the Code: [Code]....

How do I get the UserID of the just created user?

View 6 Replies

Security :: Default Profile When User Is Created?

Oct 10, 2010

How do i set the default profile when a user logs in. I have an application where the users (once they are authenticated) are in either the logged in, premium, or promotion profile. right now it assigns none. How do i make every user automatically be part of the promotion profile.

View 2 Replies

Security :: Edit A User Profile Once It Has Already Been Created?

Jun 17, 2010

I know this sounds simple, but I can't find the answer anywhere. How do I edit a user profile once it has already been created?

View 2 Replies

Page.Profile Not Saving After User Created In A CreateUserWizard?

Dec 9, 2010

I Have the following code which fires OnCreatedUser and doesn't throw any errors. Profile.Title is getting set to the correct value when inspected after the assignment.

public void CreateUserForm_CreatedUser(object sender, EventArgs e)
{
var ddlTitle = (DropDownList)CreateUserWizardStep1.ContentTemplateContainer.FindControl("Title");

[code]...

View 1 Replies

ADO.NET :: Getting An ID For A Newly-created Object?

Jan 4, 2011

let's say I have an entity (based on a SQL Server table) that I'll call "Schedule." This entity includes the following columns:

DateID -- identity integer column, primary key
StartDate -- DateTime column
EndDate -- another DateTime column.

Let's say I add new data as follows: [Code]....

If I'm not mistaken, I believe that once the EF.SaveChanges() executes, a new entry is created, and a new DateID is generated.I need to get that new DateID.

View 2 Replies

C# - How To Log Newly-Created Users Into The Site

Jul 16, 2010

I have looked and so far not been able to find the answer. When a user creates a new account i want the user to be automatically logged into the site as opposed to just being redirected to the log in page. I am able to create the users but am unsuccessful at finding logging them in.

View 1 Replies

Security :: How To Skip A Newly Created CreateUserWizard Step

Aug 4, 2010

i'm trying to figure out if its possible to skip a step in the create user wizard control that i've added. What i'd like to do is create a checkbox on the previous step and say "add a spouse" and if its checked goto the next step if its not checked goto the step after the "add a spouse" step. make sense?

View 7 Replies

Security :: Best Way To Insert Newly-created UserId Into A Second Table Also?

Sep 25, 2010

[Code]....

View 9 Replies

JQuery / JSTree / How To Get Newly Created Node's ID From Server

Sep 13, 2010

I currently have a JSTree all set up to do the creation and renaming of a new node:

.bind("create_node.jstree", function (NODE, REF_NODE) {
$.ajax({
async: false,
cache: false, [code]...

The problem is that my success doesn't seem to get hit when I return an integer ID on the create node, thus I can't set it to a global variable. What exactly do I need to return in the function to get back the ID from the server? I'm simply returning a new integer right now.

View 1 Replies

DataSource Controls :: Editing A CreateUserWizard And Linking It To Newly Created Database?

Jan 28, 2011

I've editing a create user wizard to add a 2nd step, this step will collect the users address. i can't get the second step to save into a table. I'm completely new to visual web developer, so if you reply please make it as jargon free as possible, see source code and vb code, i think i'm missing code for the "finish Button click"

Source code is. [Code]....

Code Behind the wizard control
Partial Class Registration
Inherits BasePage [Code]....

View 7 Replies

Forms Data Controls :: Not Getting Newly Created Int In The FormView's ItemInserted Event

Jan 13, 2011

I've got a FormView control on a page. Its default mode is insert, since the intent is to have the user enter a record, save it, and then do something else. I've written a stored procedure to insert all of the data into 5 tables. 1 of the columns inserted is default, in SQL Server 2005, as an INT column, which is an IDENTITY column. After it inserts the record into the primary table, using a secondary stored procedure, it retrieves the newly created INT value, and then the primary stored procedure inserts records, using the new INT, into the other 4 tables. This is working fine. The primary stored procedure, which is called by the SqlDataSource on my .aspx page, defines this parameter as an output parameter:

[Code]....

In the FormView's ItemInserted event I'm trying to get the value from the FormViewInsertedEventArgs e parameter like this: [Code]....

However, the result returned is 0. Huh? That cannot be, because the new INT value created is something like 145000. Why am I then seeing a value of 0?

View 4 Replies

Web Forms :: Profile Service Error - Unable To Load User Profile In Iis?

Jan 3, 2011

I am using profile services to store some attributes of users registered in the website. Now I am making a display profile page for a user. The problem is that the profile loads easily when I am running the site from VS 2010, but it gives the following error when I run it from IIS7 on my local machine:

System.NullReferenceException: Object reference not set to an instance of an object.

Source Error:

[Code]....

[code]....

View 4 Replies

Security :: Creating A Profile For A New User Is Updating Other Profile

Feb 4, 2010

I am logged in as user1, and while creating a user in which I have additional information which would store first and last name into the profile database. I have the following code

[Code]....

But because I just have profile like that, it is updating the profile of user1 not the new user i just created

[Code]....

View 5 Replies

Web Forms :: Getting Error "Sys" Is Undefined When Running Newly Created Website

Jun 21, 2010

I just installed Visual Web Developer 2010. All I've done at this point is:

1- Clicked on Create new ASP.net web site (NOT the empty one).
2- It creates the web site
3- I click CTL+F5 to run it.
4- It kicks out the error: Error: 'Sys' is undefined

If I create an Empty web site, and add my own web page, it runs no problem.

View 3 Replies

DataSource Controls :: Getting The PK ID Of The Newly Created Record After Inserting A New Record?

Dec 20, 2010

I am creating an album using the following stored procedure, which returns the primary key for the newly created record:

SET ANSI_NULLS ON
GO
SET QUOTED_IDENTIFIER ON
GO
CREATE PROCEDURE [dbo].[fpa_sp_albums_update_insert]
@album_id int,
@album_name nvarchar (50),
@album_descr nvarchar(250),
@album_img_cover_id_FK int,
@album_creation_date date
AS
If @album_id > 0
UPDATE [fpa_albums]
SET
album_name=@album_name,
album_descr= @album_descr,
album_img_cover_id_FK = @album_img_cover_id_FK,
album_creation_date = @album_creation_date
Where ((album_id = @album_id))
Else
INSERT INTO [fpa_albums] (
album_name,
album_descr,
album_img_cover_id_FK,
album_creation_date)
VALUES (
@album_name,
@album_descr,
@album_img_cover_id_FK,
@album_creation_date)
Return SCOPE_IDENTITY();

I execute the above stored procedure using the SQLHELPER. The VB.NET code for the page is as follows:

[Code]....

However, the createdAlbumID always shows -1 instead of the id for the newly created album.

View 1 Replies

Web Forms :: Aspnetdb_log.ldf Is Not Created When Using Profile Properties?

Jan 29, 2010

{System.Data.SqlClient.SqlException: Cannot open user default database. Login failed. Login failed for user 'MyMachineASPNET'. File activation failure. The physical file name "MyApplicationPathApp_Dataaspnetdb_log.ldf" may be incorrect.

Using Profile propertiseAs aspnetdb.mdf and aspnetdb_log.ldf are supposed to get created automatically, but only aspnetdb.mdf is getting created log file is not created when i run application and get above error.

View 1 Replies

Security :: Table Profile Provider Samples Created By Hao Kung?

Jul 1, 2010

I created a table named Thread to store logged-on users' comments. It has CommentId, Topic, Comment, CreatedTime and UserId columns. I made CommentId as the primary key and UserId as the foreign key to the UnserId in the Membership table aspnet_Users.But when I insert those data into table Thread, I get an error "Cannot insert the value NULL into column 'UserId', table 'ASPNETDB.dbo.Thread'; column does not allow nulls. INSERT fails.The statement has been terminated." I have tried different ways to resolve this, but could not make the UserId in the table Thread match the UserId in table aspnet_Users. Yesterday, I found the Table Profile Provider Samples created by Hao Kung at http://www.asp.net/downloads/sandbox/table-profile-provider-samples. It should be be able to solve my problem. But the code was written in C#. Is there anybody who knows a VB version of this code, or a better way to solve my problem?

View 2 Replies

Inform The User About Newly Released Application?

Feb 23, 2011

i have released one application..

now i have to maintain the document for the released application..

which is the best method to write the information such as in word,or pdf or excel or is there any way to keep the document..?

so that every one should know that the new release application is released .. and they should be updated

i've hosted the previous application and now i have release the modules in that application ..

now i have inform all the user that we have released new modules with etc etc features ..

View 4 Replies

User Controls :: Display User Profile Image Of Logged In User?

May 7, 2015

I would like users to upload a profile picture when they register, and to then show that picture in a picture box control when they are logged in based  on that specific user.

View 1 Replies

Web Forms :: Create A Profile In Which The User Can Create And Edit His Profile?

Jun 25, 2010

I got the followig task.Create a website (Profile.aspx) in which the User can create and edit his profile.Well, I know how to write in a database, but how do I get the UserName oder the UserID to make a PrimaryKey?If the user is logged in a session will be started. In this session is the UserName but I don't know how to read out the UserName with ASP.NET to make an PrimaryKey. If I would try to read out the UserName with C# I must save it in an variable and give it somehow to my form.

asp:sqldatasource id="SqlDataSource1" runat="server"
connectionstring="<%$
ConnectionStrings:MyConnectionString %>"[code]....

View 4 Replies

Web Forms :: When New User Register / Get Pre-designed Page From Where User Can Update Profile?

Apr 20, 2010

I am working on Social Networking Website. My problem is that

when new user will register he/she will get Pre-designed Profile page from where user can update profile.

View 5 Replies

User Controls :: Upload Image And Display On User Profile Page?

Jan 8, 2014

I am making a Human resource Management system in which i have to make  employee profiles, there is a page in which i am entering employee name and uploading a rofile picture and i want the next page to show that image on a left corner of every employee...after clicking on the submit button of the previous page !

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved