Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8667311
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T17:56:05+00:00 2026-06-12T17:56:05+00:00

I have a web role hosting a Unity3D application. In the application I have

  • 0

I have a web role hosting a Unity3D application. In the application I have a connection screen. Like any other connection screen you can fill your login and password to access the core of the application (a game for example).

All of those information are stored in a Windows Azure Database and I can create user using an admin panel. This panel is hosted in another Web Role and can access the database.

If I create a new user, I can connect with those information in my application. There is no problem. But now if I want to change the user password using the admin panel the value is well changed in the database but in my application I can’t connect with the new password, the old one is always used.

The user creation and password change are done with the Razor Entity Framework.

I don’t understand because in my Unity3D application I do a request to the web role and the user controller and the role returns the old password and not the new one. But in my db and my admin panel there is the new one… How can this be ? How can I solve this ?

Is it a Response caching problem ?

How I find and return User:

DatabaseContext db = DatabaseContextProvider.WebDatabase;
string login = Request.Form["login"]; //The login typed by user
var users = from u in db.Users where u.Login == login select u;
User[] userArray = users.ToArray<User>();

Then I fill the Response to Unity3D with some Header like
Response.AddHeader("data", userArray[0].data.ToString());

If you need any information that can help you solving my problem, just ask.

Thanks a lot for your help !

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T17:56:06+00:00Added an answer on June 12, 2026 at 5:56 pm

    Found the problem, this was caused by Entity Framework :
    Entity Framework and DbContext – Object Tracking
    http://msmvps.com/blogs/kevinmcneish/archive/2010/02/16/setting-entity-framework-mergeoptions-what-works-what-doesn-t.aspx

    Before

    DatabaseContext db = DatabaseContextProvider.WebDatabase;
    string login = Request.Form["login"];
    var users = from u in db.Users where u.Login == login select u;
    User[] userArray = users.ToArray<User>();
    

    Now

    DatabaseContext db = DatabaseContextProvider.WebDatabase;
    string login = Request.Form["login"];
    ObjectContext objectContext = ((IObjectContextAdapter)db).ObjectContext;
    ObjectSet<User> set = objectContext.CreateObjectSet<User>();
    set.MergeOption = MergeOption.OverwriteChanges;
    var users = from u in set where u.Login == login select u;
    User[] userArray = users.ToArray<User>();
    

    @Sandrino Di Mattia : Thanks for helping me finding the answer !

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

We have a Web Role that we are hosting in Windows Azure that uses
I have a web application that uses the asp.net membership and role providers to
I have a site running on an Azure web role and I can force
I have a relatively low bandwidth Azure Web Role application and also several processes
We have an windows Azure web role (typically ASP.NET application) with client side J-queries
I have a web application secured with Spring Security that needs two separate login
I have a front end MVC application in a web role, protected by WIF
I know that you can only have 1 web role per instance but does
I have a Web Role that is using the ASP.NET SQL Membership provider. Currently
I have a web role configured with SSL, which has a ReportViewer control that

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.