how to create an ASPNET.mdf file?

Discussion in 'ASP .Net Security' started by Mich, Apr 8, 2007.

  1. Mich

    Mich Guest

    Hi,

    i'm building an web application for anonymous users. They can take a look in
    the website, nothing more. In order to perform other actions, the anonymous
    user must be logged. So i create an aspx page with the CreateUserWizard
    control. The user can fill his username, password etc ....

    My problem is: when an user fills everything and clicks on button "create an
    account", nothing happens (no error, but no user account created).
    I thought asp.net would create in App_Data an ASPNET.MDF file for storing
    user and membership information and add automatically a new connection
    string in web.config. But it doesn't happen.

    I know i can go in design mode (n VWD) and click on "administer the site",
    but all the users are anonymous, so i can't create user in advance.
    Do i have to put some configuration code in web.config? Or something else?

    Thanks for help
    Mich
    Mich, Apr 8, 2007
    #1
    1. Advertising

  2. Run aspnet_regsql.exe from a command window in your .Net Framework 2.0 directory.




    Juan T. Llibre, asp.net MVP
    asp.net faq : http://asp.net.do/faq/
    foros de asp.net, en español : http://asp.net.do/foros/
    ===================================
    "Mich" <> wrote in message news:Og6O%...
    > Hi,
    >
    > i'm building an web application for anonymous users. They can take a look in the website, nothing
    > more. In order to perform other actions, the anonymous user must be logged. So i create an aspx
    > page with the CreateUserWizard control. The user can fill his username, password etc ....
    >
    > My problem is: when an user fills everything and clicks on button "create an account", nothing
    > happens (no error, but no user account created).
    > I thought asp.net would create in App_Data an ASPNET.MDF file for storing user and membership
    > information and add automatically a new connection string in web.config. But it doesn't happen.
    >
    > I know i can go in design mode (n VWD) and click on "administer the site", but all the users are
    > anonymous, so i can't create user in advance.
    > Do i have to put some configuration code in web.config? Or something else?
    >
    > Thanks for help
    > Mich
    >
    Juan T. Llibre, Apr 8, 2007
    #2
    1. Advertising

  3. Mich

    Mich Guest

    Hi Juan, thanks for replying..

    I did this and an mdf file ASPNETDB.MDF was created in the sql server
    directory.
    So i copied both files (mdf and log) into APP_Data of my application.
    I added a connection string in web.config like this:
    <add name="aspnetdb" connectionString="Data
    Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    Security=True;User Instance=True" providerName="System.Data.SqlClient"/>

    Now, when starting the aspx page containing the createuserwizard and filling
    all texboxes, again, nothing happens (user is not created). If i try it
    within VWDev., the user is then created.
    What do i forget or do wrong?
    Thanks



    "Juan T. Llibre" <> schreef in bericht
    news:...
    > Run aspnet_regsql.exe from a command window in your .Net Framework 2.0
    > directory.
    >
    >
    >
    >
    > Juan T. Llibre, asp.net MVP
    > asp.net faq : http://asp.net.do/faq/
    > foros de asp.net, en español : http://asp.net.do/foros/
    > ===================================
    > "Mich" <> wrote in message
    > news:Og6O%...
    >> Hi,
    >>
    >> i'm building an web application for anonymous users. They can take a look
    >> in the website, nothing more. In order to perform other actions, the
    >> anonymous user must be logged. So i create an aspx page with the
    >> CreateUserWizard control. The user can fill his username, password etc
    >> ....
    >>
    >> My problem is: when an user fills everything and clicks on button "create
    >> an account", nothing happens (no error, but no user account created).
    >> I thought asp.net would create in App_Data an ASPNET.MDF file for storing
    >> user and membership information and add automatically a new connection
    >> string in web.config. But it doesn't happen.
    >>
    >> I know i can go in design mode (n VWD) and click on "administer the
    >> site", but all the users are anonymous, so i can't create user in
    >> advance.
    >> Do i have to put some configuration code in web.config? Or something
    >> else?
    >>
    >> Thanks for help
    >> Mich
    >>

    >
    >
    Mich, Apr 8, 2007
    #3
  4. Mich

    David Guest

    I notice you ahve integrated security rather than user names and passwords.
    I may be wrong but I think integrated security will require the current user
    to have permission in the database. When you are doing it through VWDev, you
    are probably carrying your username through, but when doing it from ASP.NET,
    you are using the ASP.NET user account, which may not have permission.

    --
    Best regards,
    Dave Colliver.
    http://www.AshfieldFOCUS.com
    ~~
    http://www.FOCUSPortals.com - Local franchises available


    "Mich" <> wrote in message
    news:Ox%...
    > Hi Juan, thanks for replying..
    >
    > I did this and an mdf file ASPNETDB.MDF was created in the sql server
    > directory.
    > So i copied both files (mdf and log) into APP_Data of my application.
    > I added a connection string in web.config like this:
    > <add name="aspnetdb" connectionString="Data
    > Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    > Security=True;User Instance=True" providerName="System.Data.SqlClient"/>
    >
    > Now, when starting the aspx page containing the createuserwizard and
    > filling all texboxes, again, nothing happens (user is not created). If i
    > try it within VWDev., the user is then created.
    > What do i forget or do wrong?
    > Thanks
    >
    >
    >
    > "Juan T. Llibre" <> schreef in bericht
    > news:...
    >> Run aspnet_regsql.exe from a command window in your .Net Framework 2.0
    >> directory.
    >>
    >>
    >>
    >>
    >> Juan T. Llibre, asp.net MVP
    >> asp.net faq : http://asp.net.do/faq/
    >> foros de asp.net, en español : http://asp.net.do/foros/
    >> ===================================
    >> "Mich" <> wrote in message
    >> news:Og6O%...
    >>> Hi,
    >>>
    >>> i'm building an web application for anonymous users. They can take a
    >>> look in the website, nothing more. In order to perform other actions,
    >>> the anonymous user must be logged. So i create an aspx page with the
    >>> CreateUserWizard control. The user can fill his username, password etc
    >>> ....
    >>>
    >>> My problem is: when an user fills everything and clicks on button
    >>> "create an account", nothing happens (no error, but no user account
    >>> created).
    >>> I thought asp.net would create in App_Data an ASPNET.MDF file for
    >>> storing user and membership information and add automatically a new
    >>> connection string in web.config. But it doesn't happen.
    >>>
    >>> I know i can go in design mode (n VWD) and click on "administer the
    >>> site", but all the users are anonymous, so i can't create user in
    >>> advance.
    >>> Do i have to put some configuration code in web.config? Or something
    >>> else?
    >>>
    >>> Thanks for help
    >>> Mich
    >>>

    >>
    >>

    >
    >
    David, Apr 9, 2007
    #4
  5. Mich

    Mich Guest

    Account ASPNET has R/W rights on the APP_Data dir.
    And if it was not so, i would get an error, but here, no error, nothing
    happens ...

    "David" <> schreef in bericht
    news:...
    >I notice you ahve integrated security rather than user names and passwords.
    >I may be wrong but I think integrated security will require the current
    >user to have permission in the database. When you are doing it through
    >VWDev, you are probably carrying your username through, but when doing it
    >from ASP.NET, you are using the ASP.NET user account, which may not have
    >permission.
    >
    > --
    > Best regards,
    > Dave Colliver.
    > http://www.AshfieldFOCUS.com
    > ~~
    > http://www.FOCUSPortals.com - Local franchises available
    >
    >
    > "Mich" <> wrote in message
    > news:Ox%...
    >> Hi Juan, thanks for replying..
    >>
    >> I did this and an mdf file ASPNETDB.MDF was created in the sql server
    >> directory.
    >> So i copied both files (mdf and log) into APP_Data of my application.
    >> I added a connection string in web.config like this:
    >> <add name="aspnetdb" connectionString="Data
    >> Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    >> Security=True;User Instance=True" providerName="System.Data.SqlClient"/>
    >>
    >> Now, when starting the aspx page containing the createuserwizard and
    >> filling all texboxes, again, nothing happens (user is not created). If i
    >> try it within VWDev., the user is then created.
    >> What do i forget or do wrong?
    >> Thanks
    >>
    >>
    >>
    >> "Juan T. Llibre" <> schreef in bericht
    >> news:...
    >>> Run aspnet_regsql.exe from a command window in your .Net Framework 2.0
    >>> directory.
    >>>
    >>>
    >>>
    >>>
    >>> Juan T. Llibre, asp.net MVP
    >>> asp.net faq : http://asp.net.do/faq/
    >>> foros de asp.net, en español : http://asp.net.do/foros/
    >>> ===================================
    >>> "Mich" <> wrote in message
    >>> news:Og6O%...
    >>>> Hi,
    >>>>
    >>>> i'm building an web application for anonymous users. They can take a
    >>>> look in the website, nothing more. In order to perform other actions,
    >>>> the anonymous user must be logged. So i create an aspx page with the
    >>>> CreateUserWizard control. The user can fill his username, password etc
    >>>> ....
    >>>>
    >>>> My problem is: when an user fills everything and clicks on button
    >>>> "create an account", nothing happens (no error, but no user account
    >>>> created).
    >>>> I thought asp.net would create in App_Data an ASPNET.MDF file for
    >>>> storing user and membership information and add automatically a new
    >>>> connection string in web.config. But it doesn't happen.
    >>>>
    >>>> I know i can go in design mode (n VWD) and click on "administer the
    >>>> site", but all the users are anonymous, so i can't create user in
    >>>> advance.
    >>>> Do i have to put some configuration code in web.config? Or something
    >>>> else?
    >>>>
    >>>> Thanks for help
    >>>> Mich
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    Mich, Apr 9, 2007
    #5
  6. Mich

    David Guest

    but what about your database?

    just having access to the directory does not give database permission.

    Set up a user in your database. Give that user permission to see the table
    you want to view. Put that users username/password into your connection
    string.

    --
    Best regards,
    Dave Colliver.
    http://www.AshfieldFOCUS.com
    ~~
    http://www.FOCUSPortals.com - Local franchises available


    "Mich" <> wrote in message
    news:...
    > Account ASPNET has R/W rights on the APP_Data dir.
    > And if it was not so, i would get an error, but here, no error, nothing
    > happens ...
    >
    > "David" <> schreef in bericht
    > news:...
    >>I notice you ahve integrated security rather than user names and
    >>passwords. I may be wrong but I think integrated security will require the
    >>current user to have permission in the database. When you are doing it
    >>through VWDev, you are probably carrying your username through, but when
    >>doing it from ASP.NET, you are using the ASP.NET user account, which may
    >>not have permission.
    >>
    >> --
    >> Best regards,
    >> Dave Colliver.
    >> http://www.AshfieldFOCUS.com
    >> ~~
    >> http://www.FOCUSPortals.com - Local franchises available
    >>
    >>
    >> "Mich" <> wrote in message
    >> news:Ox%...
    >>> Hi Juan, thanks for replying..
    >>>
    >>> I did this and an mdf file ASPNETDB.MDF was created in the sql server
    >>> directory.
    >>> So i copied both files (mdf and log) into APP_Data of my application.
    >>> I added a connection string in web.config like this:
    >>> <add name="aspnetdb" connectionString="Data
    >>> Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    >>> Security=True;User Instance=True" providerName="System.Data.SqlClient"/>
    >>>
    >>> Now, when starting the aspx page containing the createuserwizard and
    >>> filling all texboxes, again, nothing happens (user is not created). If i
    >>> try it within VWDev., the user is then created.
    >>> What do i forget or do wrong?
    >>> Thanks
    >>>
    >>>
    >>>
    >>> "Juan T. Llibre" <> schreef in bericht
    >>> news:...
    >>>> Run aspnet_regsql.exe from a command window in your .Net Framework 2.0
    >>>> directory.
    >>>>
    >>>>
    >>>>
    >>>>
    >>>> Juan T. Llibre, asp.net MVP
    >>>> asp.net faq : http://asp.net.do/faq/
    >>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>> ===================================
    >>>> "Mich" <> wrote in message
    >>>> news:Og6O%...
    >>>>> Hi,
    >>>>>
    >>>>> i'm building an web application for anonymous users. They can take a
    >>>>> look in the website, nothing more. In order to perform other actions,
    >>>>> the anonymous user must be logged. So i create an aspx page with the
    >>>>> CreateUserWizard control. The user can fill his username, password etc
    >>>>> ....
    >>>>>
    >>>>> My problem is: when an user fills everything and clicks on button
    >>>>> "create an account", nothing happens (no error, but no user account
    >>>>> created).
    >>>>> I thought asp.net would create in App_Data an ASPNET.MDF file for
    >>>>> storing user and membership information and add automatically a new
    >>>>> connection string in web.config. But it doesn't happen.
    >>>>>
    >>>>> I know i can go in design mode (n VWD) and click on "administer the
    >>>>> site", but all the users are anonymous, so i can't create user in
    >>>>> advance.
    >>>>> Do i have to put some configuration code in web.config? Or something
    >>>>> else?
    >>>>>
    >>>>> Thanks for help
    >>>>> Mich
    >>>>>
    >>>>
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    David, Apr 9, 2007
    #6
  7. Mich

    Mich Guest

    David, i did all those things but i found it:
    the map security of the standard website in the IIS was set on Windows
    Integrated Auth.
    The map security of my website (one level lower in the IIS as all other
    websites) is set on Anonymous.
    This is the reason why login and createuserwizard doesn't work.
    I changed the map security of the standard website into Anonymous and
    everything works.
    Amazing, no?
    Do you have an explanation for that?


    "David" <> schreef in bericht
    news:e%...
    > but what about your database?
    >
    > just having access to the directory does not give database permission.
    >
    > Set up a user in your database. Give that user permission to see the table
    > you want to view. Put that users username/password into your connection
    > string.
    >
    > --
    > Best regards,
    > Dave Colliver.
    > http://www.AshfieldFOCUS.com
    > ~~
    > http://www.FOCUSPortals.com - Local franchises available
    >
    >
    > "Mich" <> wrote in message
    > news:...
    >> Account ASPNET has R/W rights on the APP_Data dir.
    >> And if it was not so, i would get an error, but here, no error, nothing
    >> happens ...
    >>
    >> "David" <> schreef in bericht
    >> news:...
    >>>I notice you ahve integrated security rather than user names and
    >>>passwords. I may be wrong but I think integrated security will require
    >>>the current user to have permission in the database. When you are doing
    >>>it through VWDev, you are probably carrying your username through, but
    >>>when doing it from ASP.NET, you are using the ASP.NET user account, which
    >>>may not have permission.
    >>>
    >>> --
    >>> Best regards,
    >>> Dave Colliver.
    >>> http://www.AshfieldFOCUS.com
    >>> ~~
    >>> http://www.FOCUSPortals.com - Local franchises available
    >>>
    >>>
    >>> "Mich" <> wrote in message
    >>> news:Ox%...
    >>>> Hi Juan, thanks for replying..
    >>>>
    >>>> I did this and an mdf file ASPNETDB.MDF was created in the sql server
    >>>> directory.
    >>>> So i copied both files (mdf and log) into APP_Data of my application.
    >>>> I added a connection string in web.config like this:
    >>>> <add name="aspnetdb" connectionString="Data
    >>>> Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    >>>> Security=True;User Instance=True"
    >>>> providerName="System.Data.SqlClient"/>
    >>>>
    >>>> Now, when starting the aspx page containing the createuserwizard and
    >>>> filling all texboxes, again, nothing happens (user is not created). If
    >>>> i try it within VWDev., the user is then created.
    >>>> What do i forget or do wrong?
    >>>> Thanks
    >>>>
    >>>>
    >>>>
    >>>> "Juan T. Llibre" <> schreef in bericht
    >>>> news:...
    >>>>> Run aspnet_regsql.exe from a command window in your .Net Framework 2.0
    >>>>> directory.
    >>>>>
    >>>>>
    >>>>>
    >>>>>
    >>>>> Juan T. Llibre, asp.net MVP
    >>>>> asp.net faq : http://asp.net.do/faq/
    >>>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>>> ===================================
    >>>>> "Mich" <> wrote in message
    >>>>> news:Og6O%...
    >>>>>> Hi,
    >>>>>>
    >>>>>> i'm building an web application for anonymous users. They can take a
    >>>>>> look in the website, nothing more. In order to perform other actions,
    >>>>>> the anonymous user must be logged. So i create an aspx page with the
    >>>>>> CreateUserWizard control. The user can fill his username, password
    >>>>>> etc ....
    >>>>>>
    >>>>>> My problem is: when an user fills everything and clicks on button
    >>>>>> "create an account", nothing happens (no error, but no user account
    >>>>>> created).
    >>>>>> I thought asp.net would create in App_Data an ASPNET.MDF file for
    >>>>>> storing user and membership information and add automatically a new
    >>>>>> connection string in web.config. But it doesn't happen.
    >>>>>>
    >>>>>> I know i can go in design mode (n VWD) and click on "administer the
    >>>>>> site", but all the users are anonymous, so i can't create user in
    >>>>>> advance.
    >>>>>> Do i have to put some configuration code in web.config? Or something
    >>>>>> else?
    >>>>>>
    >>>>>> Thanks for help
    >>>>>> Mich
    >>>>>>
    >>>>>
    >>>>>
    >>>>
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    Mich, Apr 9, 2007
    #7
  8. Hello Mich.

    I'm trying to follow along in this thread beacuse i think i'm having the
    same problem.

    Can you explain where you went to change your "map security"?

    Is it in the IIS Administration?

    Any help would be gratefully appreciated.

    Thanks,
    Tony

    "Mich" <> wrote in message
    news:eZES%...
    > David, i did all those things but i found it:
    > the map security of the standard website in the IIS was set on Windows
    > Integrated Auth.
    > The map security of my website (one level lower in the IIS as all other
    > websites) is set on Anonymous.
    > This is the reason why login and createuserwizard doesn't work.
    > I changed the map security of the standard website into Anonymous and
    > everything works.
    > Amazing, no?
    > Do you have an explanation for that?
    >
    >
    > "David" <> schreef in bericht
    > news:e%...
    >> but what about your database?
    >>
    >> just having access to the directory does not give database permission.
    >>
    >> Set up a user in your database. Give that user permission to see the
    >> table you want to view. Put that users username/password into your
    >> connection string.
    >>
    >> --
    >> Best regards,
    >> Dave Colliver.
    >> http://www.AshfieldFOCUS.com
    >> ~~
    >> http://www.FOCUSPortals.com - Local franchises available
    >>
    >>
    >> "Mich" <> wrote in message
    >> news:...
    >>> Account ASPNET has R/W rights on the APP_Data dir.
    >>> And if it was not so, i would get an error, but here, no error, nothing
    >>> happens ...
    >>>
    >>> "David" <> schreef in bericht
    >>> news:...
    >>>>I notice you ahve integrated security rather than user names and
    >>>>passwords. I may be wrong but I think integrated security will require
    >>>>the current user to have permission in the database. When you are doing
    >>>>it through VWDev, you are probably carrying your username through, but
    >>>>when doing it from ASP.NET, you are using the ASP.NET user account,
    >>>>which may not have permission.
    >>>>
    >>>> --
    >>>> Best regards,
    >>>> Dave Colliver.
    >>>> http://www.AshfieldFOCUS.com
    >>>> ~~
    >>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>
    >>>>
    >>>> "Mich" <> wrote in message
    >>>> news:Ox%...
    >>>>> Hi Juan, thanks for replying..
    >>>>>
    >>>>> I did this and an mdf file ASPNETDB.MDF was created in the sql server
    >>>>> directory.
    >>>>> So i copied both files (mdf and log) into APP_Data of my application.
    >>>>> I added a connection string in web.config like this:
    >>>>> <add name="aspnetdb" connectionString="Data
    >>>>> Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    >>>>> Security=True;User Instance=True"
    >>>>> providerName="System.Data.SqlClient"/>
    >>>>>
    >>>>> Now, when starting the aspx page containing the createuserwizard and
    >>>>> filling all texboxes, again, nothing happens (user is not created). If
    >>>>> i try it within VWDev., the user is then created.
    >>>>> What do i forget or do wrong?
    >>>>> Thanks
    >>>>>
    >>>>>
    >>>>>
    >>>>> "Juan T. Llibre" <> schreef in bericht
    >>>>> news:...
    >>>>>> Run aspnet_regsql.exe from a command window in your .Net Framework
    >>>>>> 2.0 directory.
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>> Juan T. Llibre, asp.net MVP
    >>>>>> asp.net faq : http://asp.net.do/faq/
    >>>>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>>>> ===================================
    >>>>>> "Mich" <> wrote in message
    >>>>>> news:Og6O%...
    >>>>>>> Hi,
    >>>>>>>
    >>>>>>> i'm building an web application for anonymous users. They can take a
    >>>>>>> look in the website, nothing more. In order to perform other
    >>>>>>> actions, the anonymous user must be logged. So i create an aspx page
    >>>>>>> with the CreateUserWizard control. The user can fill his username,
    >>>>>>> password etc ....
    >>>>>>>
    >>>>>>> My problem is: when an user fills everything and clicks on button
    >>>>>>> "create an account", nothing happens (no error, but no user account
    >>>>>>> created).
    >>>>>>> I thought asp.net would create in App_Data an ASPNET.MDF file for
    >>>>>>> storing user and membership information and add automatically a new
    >>>>>>> connection string in web.config. But it doesn't happen.
    >>>>>>>
    >>>>>>> I know i can go in design mode (n VWD) and click on "administer the
    >>>>>>> site", but all the users are anonymous, so i can't create user in
    >>>>>>> advance.
    >>>>>>> Do i have to put some configuration code in web.config? Or something
    >>>>>>> else?
    >>>>>>>
    >>>>>>> Thanks for help
    >>>>>>> Mich
    >>>>>>>
    >>>>>>
    >>>>>>
    >>>>>
    >>>>>
    >>>>
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    Tony Girgenti, Apr 9, 2007
    #8
  9. re:
    > Can you explain where you went to change your "map security"?


    He meant "the mapped security".

    Use the IIS Manager for that.
    Right-click and select "Properties"; then select the "Directory Security" tab.




    Juan T. Llibre, asp.net MVP
    asp.net faq : http://asp.net.do/faq/
    foros de asp.net, en español : http://asp.net.do/foros/
    ===================================
    "Tony Girgenti" <tony(nospam)@lakesideos.com> wrote in message
    news:...
    > Hello Mich.
    >
    > I'm trying to follow along in this thread beacuse i think i'm having the same problem.
    >
    > Can you explain where you went to change your "map security"?
    >
    > Is it in the IIS Administration?
    >
    > Any help would be gratefully appreciated.
    >
    > Thanks,
    > Tony
    >
    > "Mich" <> wrote in message news:eZES%...
    >> David, i did all those things but i found it:
    >> the map security of the standard website in the IIS was set on Windows Integrated Auth.
    >> The map security of my website (one level lower in the IIS as all other websites) is set on
    >> Anonymous.
    >> This is the reason why login and createuserwizard doesn't work.
    >> I changed the map security of the standard website into Anonymous and everything works.
    >> Amazing, no?
    >> Do you have an explanation for that?
    >>
    >>
    >> "David" <> schreef in bericht
    >> news:e%...
    >>> but what about your database?
    >>>
    >>> just having access to the directory does not give database permission.
    >>>
    >>> Set up a user in your database. Give that user permission to see the table you want to view. Put
    >>> that users username/password into your connection string.
    >>>
    >>> --
    >>> Best regards,
    >>> Dave Colliver.
    >>> http://www.AshfieldFOCUS.com
    >>> ~~
    >>> http://www.FOCUSPortals.com - Local franchises available
    >>>
    >>>
    >>> "Mich" <> wrote in message news:...
    >>>> Account ASPNET has R/W rights on the APP_Data dir.
    >>>> And if it was not so, i would get an error, but here, no error, nothing happens ...
    >>>>
    >>>> "David" <> schreef in bericht
    >>>> news:...
    >>>>>I notice you ahve integrated security rather than user names and passwords. I may be wrong but
    >>>>>I think integrated security will require the current user to have permission in the database.
    >>>>>When you are doing it through VWDev, you are probably carrying your username through, but when
    >>>>>doing it from ASP.NET, you are using the ASP.NET user account, which may not have permission.
    >>>>>
    >>>>> --
    >>>>> Best regards,
    >>>>> Dave Colliver.
    >>>>> http://www.AshfieldFOCUS.com
    >>>>> ~~
    >>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>
    >>>>>
    >>>>> "Mich" <> wrote in message news:Ox%...
    >>>>>> Hi Juan, thanks for replying..
    >>>>>>
    >>>>>> I did this and an mdf file ASPNETDB.MDF was created in the sql server directory.
    >>>>>> So i copied both files (mdf and log) into APP_Data of my application.
    >>>>>> I added a connection string in web.config like this:
    >>>>>> <add name="aspnetdb" connectionString="Data
    >>>>>> Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    >>>>>> Security=True;User Instance=True" providerName="System.Data.SqlClient"/>
    >>>>>>
    >>>>>> Now, when starting the aspx page containing the createuserwizard and filling all texboxes,
    >>>>>> again, nothing happens (user is not created). If i try it within VWDev., the user is then
    >>>>>> created.
    >>>>>> What do i forget or do wrong?
    >>>>>> Thanks
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>> "Juan T. Llibre" <> schreef in bericht
    >>>>>> news:...
    >>>>>>> Run aspnet_regsql.exe from a command window in your .Net Framework 2.0 directory.
    >>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>> Juan T. Llibre, asp.net MVP
    >>>>>>> asp.net faq : http://asp.net.do/faq/
    >>>>>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>>>>> ===================================
    >>>>>>> "Mich" <> wrote in message news:Og6O%...
    >>>>>>>> Hi,
    >>>>>>>>
    >>>>>>>> i'm building an web application for anonymous users. They can take a look in the website,
    >>>>>>>> nothing more. In order to perform other actions, the anonymous user must be logged. So i
    >>>>>>>> create an aspx page with the CreateUserWizard control. The user can fill his username,
    >>>>>>>> password etc ....
    >>>>>>>>
    >>>>>>>> My problem is: when an user fills everything and clicks on button "create an account",
    >>>>>>>> nothing happens (no error, but no user account created).
    >>>>>>>> I thought asp.net would create in App_Data an ASPNET.MDF file for storing user and
    >>>>>>>> membership information and add automatically a new connection string in web.config. But it
    >>>>>>>> doesn't happen.
    >>>>>>>>
    >>>>>>>> I know i can go in design mode (n VWD) and click on "administer the site", but all the
    >>>>>>>> users are anonymous, so i can't create user in advance.
    >>>>>>>> Do i have to put some configuration code in web.config? Or something else?
    >>>>>>>>
    >>>>>>>> Thanks for help
    >>>>>>>> Mich
    >>>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>
    >>>>>>
    >>>>>
    >>>>>
    >>>>
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    Juan T. Llibre, Apr 9, 2007
    #9
  10. Mich

    Mich Guest

    Yes.

    Rightclick on Standard website (maybe diffferent in windows 2003, i use xp
    prof.), then take properties and then Map security. There you can choose
    anonymous or win. int. auth.

    "Tony Girgenti" <tony(nospam)@lakesideos.com> schreef in bericht
    news:...
    > Hello Mich.
    >
    > I'm trying to follow along in this thread beacuse i think i'm having the
    > same problem.
    >
    > Can you explain where you went to change your "map security"?
    >
    > Is it in the IIS Administration?
    >
    > Any help would be gratefully appreciated.
    >
    > Thanks,
    > Tony
    >
    > "Mich" <> wrote in message
    > news:eZES%...
    >> David, i did all those things but i found it:
    >> the map security of the standard website in the IIS was set on Windows
    >> Integrated Auth.
    >> The map security of my website (one level lower in the IIS as all other
    >> websites) is set on Anonymous.
    >> This is the reason why login and createuserwizard doesn't work.
    >> I changed the map security of the standard website into Anonymous and
    >> everything works.
    >> Amazing, no?
    >> Do you have an explanation for that?
    >>
    >>
    >> "David" <> schreef in bericht
    >> news:e%...
    >>> but what about your database?
    >>>
    >>> just having access to the directory does not give database permission.
    >>>
    >>> Set up a user in your database. Give that user permission to see the
    >>> table you want to view. Put that users username/password into your
    >>> connection string.
    >>>
    >>> --
    >>> Best regards,
    >>> Dave Colliver.
    >>> http://www.AshfieldFOCUS.com
    >>> ~~
    >>> http://www.FOCUSPortals.com - Local franchises available
    >>>
    >>>
    >>> "Mich" <> wrote in message
    >>> news:...
    >>>> Account ASPNET has R/W rights on the APP_Data dir.
    >>>> And if it was not so, i would get an error, but here, no error, nothing
    >>>> happens ...
    >>>>
    >>>> "David" <> schreef in
    >>>> bericht news:...
    >>>>>I notice you ahve integrated security rather than user names and
    >>>>>passwords. I may be wrong but I think integrated security will require
    >>>>>the current user to have permission in the database. When you are doing
    >>>>>it through VWDev, you are probably carrying your username through, but
    >>>>>when doing it from ASP.NET, you are using the ASP.NET user account,
    >>>>>which may not have permission.
    >>>>>
    >>>>> --
    >>>>> Best regards,
    >>>>> Dave Colliver.
    >>>>> http://www.AshfieldFOCUS.com
    >>>>> ~~
    >>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>
    >>>>>
    >>>>> "Mich" <> wrote in message
    >>>>> news:Ox%...
    >>>>>> Hi Juan, thanks for replying..
    >>>>>>
    >>>>>> I did this and an mdf file ASPNETDB.MDF was created in the sql server
    >>>>>> directory.
    >>>>>> So i copied both files (mdf and log) into APP_Data of my application.
    >>>>>> I added a connection string in web.config like this:
    >>>>>> <add name="aspnetdb" connectionString="Data
    >>>>>> Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    >>>>>> Security=True;User Instance=True"
    >>>>>> providerName="System.Data.SqlClient"/>
    >>>>>>
    >>>>>> Now, when starting the aspx page containing the createuserwizard and
    >>>>>> filling all texboxes, again, nothing happens (user is not created).
    >>>>>> If i try it within VWDev., the user is then created.
    >>>>>> What do i forget or do wrong?
    >>>>>> Thanks
    >>>>>>
    >>>>>>
    >>>>>>
    >>>>>> "Juan T. Llibre" <> schreef in bericht
    >>>>>> news:...
    >>>>>>> Run aspnet_regsql.exe from a command window in your .Net Framework
    >>>>>>> 2.0 directory.
    >>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>> Juan T. Llibre, asp.net MVP
    >>>>>>> asp.net faq : http://asp.net.do/faq/
    >>>>>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>>>>> ===================================
    >>>>>>> "Mich" <> wrote in message
    >>>>>>> news:Og6O%...
    >>>>>>>> Hi,
    >>>>>>>>
    >>>>>>>> i'm building an web application for anonymous users. They can take
    >>>>>>>> a look in the website, nothing more. In order to perform other
    >>>>>>>> actions, the anonymous user must be logged. So i create an aspx
    >>>>>>>> page with the CreateUserWizard control. The user can fill his
    >>>>>>>> username, password etc ....
    >>>>>>>>
    >>>>>>>> My problem is: when an user fills everything and clicks on button
    >>>>>>>> "create an account", nothing happens (no error, but no user account
    >>>>>>>> created).
    >>>>>>>> I thought asp.net would create in App_Data an ASPNET.MDF file for
    >>>>>>>> storing user and membership information and add automatically a new
    >>>>>>>> connection string in web.config. But it doesn't happen.
    >>>>>>>>
    >>>>>>>> I know i can go in design mode (n VWD) and click on "administer the
    >>>>>>>> site", but all the users are anonymous, so i can't create user in
    >>>>>>>> advance.
    >>>>>>>> Do i have to put some configuration code in web.config? Or
    >>>>>>>> something else?
    >>>>>>>>
    >>>>>>>> Thanks for help
    >>>>>>>> Mich
    >>>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>
    >>>>>>
    >>>>>
    >>>>>
    >>>>
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    Mich, Apr 9, 2007
    #10
  11. Hello Mich.

    I'm sorry for sounding so stupid but i'm not sure about where to go. By
    "Standard website", do you mean "Default Web Site"? I have XP Pro, SP1
    also.

    Also, after right-clicking and selecting properties, do you mean the
    "Directory Security" tab, then click "Edit" for the Authentication Methods
    screen? I don't see a "Map secutiry".

    Thanks,
    Tony

    "Mich" <> wrote in message
    news:...
    > Yes.
    >
    > Rightclick on Standard website (maybe diffferent in windows 2003, i use xp
    > prof.), then take properties and then Map security. There you can choose
    > anonymous or win. int. auth.
    >
    > "Tony Girgenti" <tony(nospam)@lakesideos.com> schreef in bericht
    > news:...
    >> Hello Mich.
    >>
    >> I'm trying to follow along in this thread beacuse i think i'm having the
    >> same problem.
    >>
    >> Can you explain where you went to change your "map security"?
    >>
    >> Is it in the IIS Administration?
    >>
    >> Any help would be gratefully appreciated.
    >>
    >> Thanks,
    >> Tony
    >>
    >> "Mich" <> wrote in message
    >> news:eZES%...
    >>> David, i did all those things but i found it:
    >>> the map security of the standard website in the IIS was set on Windows
    >>> Integrated Auth.
    >>> The map security of my website (one level lower in the IIS as all other
    >>> websites) is set on Anonymous.
    >>> This is the reason why login and createuserwizard doesn't work.
    >>> I changed the map security of the standard website into Anonymous and
    >>> everything works.
    >>> Amazing, no?
    >>> Do you have an explanation for that?
    >>>
    >>>
    >>> "David" <> schreef in bericht
    >>> news:e%...
    >>>> but what about your database?
    >>>>
    >>>> just having access to the directory does not give database permission.
    >>>>
    >>>> Set up a user in your database. Give that user permission to see the
    >>>> table you want to view. Put that users username/password into your
    >>>> connection string.
    >>>>
    >>>> --
    >>>> Best regards,
    >>>> Dave Colliver.
    >>>> http://www.AshfieldFOCUS.com
    >>>> ~~
    >>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>
    >>>>
    >>>> "Mich" <> wrote in message
    >>>> news:...
    >>>>> Account ASPNET has R/W rights on the APP_Data dir.
    >>>>> And if it was not so, i would get an error, but here, no error,
    >>>>> nothing happens ...
    >>>>>
    >>>>> "David" <> schreef in
    >>>>> bericht news:...
    >>>>>>I notice you ahve integrated security rather than user names and
    >>>>>>passwords. I may be wrong but I think integrated security will require
    >>>>>>the current user to have permission in the database. When you are
    >>>>>>doing it through VWDev, you are probably carrying your username
    >>>>>>through, but when doing it from ASP.NET, you are using the ASP.NET
    >>>>>>user account, which may not have permission.
    >>>>>>
    >>>>>> --
    >>>>>> Best regards,
    >>>>>> Dave Colliver.
    >>>>>> http://www.AshfieldFOCUS.com
    >>>>>> ~~
    >>>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>>
    >>>>>>
    >>>>>> "Mich" <> wrote in message
    >>>>>> news:Ox%...
    >>>>>>> Hi Juan, thanks for replying..
    >>>>>>>
    >>>>>>> I did this and an mdf file ASPNETDB.MDF was created in the sql
    >>>>>>> server directory.
    >>>>>>> So i copied both files (mdf and log) into APP_Data of my
    >>>>>>> application.
    >>>>>>> I added a connection string in web.config like this:
    >>>>>>> <add name="aspnetdb" connectionString="Data
    >>>>>>> Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    >>>>>>> Security=True;User Instance=True"
    >>>>>>> providerName="System.Data.SqlClient"/>
    >>>>>>>
    >>>>>>> Now, when starting the aspx page containing the createuserwizard and
    >>>>>>> filling all texboxes, again, nothing happens (user is not created).
    >>>>>>> If i try it within VWDev., the user is then created.
    >>>>>>> What do i forget or do wrong?
    >>>>>>> Thanks
    >>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>> "Juan T. Llibre" <> schreef in bericht
    >>>>>>> news:...
    >>>>>>>> Run aspnet_regsql.exe from a command window in your .Net Framework
    >>>>>>>> 2.0 directory.
    >>>>>>>>
    >>>>>>>>
    >>>>>>>>
    >>>>>>>>
    >>>>>>>> Juan T. Llibre, asp.net MVP
    >>>>>>>> asp.net faq : http://asp.net.do/faq/
    >>>>>>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>>>>>> ===================================
    >>>>>>>> "Mich" <> wrote in message
    >>>>>>>> news:Og6O%...
    >>>>>>>>> Hi,
    >>>>>>>>>
    >>>>>>>>> i'm building an web application for anonymous users. They can take
    >>>>>>>>> a look in the website, nothing more. In order to perform other
    >>>>>>>>> actions, the anonymous user must be logged. So i create an aspx
    >>>>>>>>> page with the CreateUserWizard control. The user can fill his
    >>>>>>>>> username, password etc ....
    >>>>>>>>>
    >>>>>>>>> My problem is: when an user fills everything and clicks on button
    >>>>>>>>> "create an account", nothing happens (no error, but no user
    >>>>>>>>> account created).
    >>>>>>>>> I thought asp.net would create in App_Data an ASPNET.MDF file for
    >>>>>>>>> storing user and membership information and add automatically a
    >>>>>>>>> new connection string in web.config. But it doesn't happen.
    >>>>>>>>>
    >>>>>>>>> I know i can go in design mode (n VWD) and click on "administer
    >>>>>>>>> the site", but all the users are anonymous, so i can't create user
    >>>>>>>>> in advance.
    >>>>>>>>> Do i have to put some configuration code in web.config? Or
    >>>>>>>>> something else?
    >>>>>>>>>
    >>>>>>>>> Thanks for help
    >>>>>>>>> Mich
    >>>>>>>>>
    >>>>>>>>
    >>>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>
    >>>>>>
    >>>>>
    >>>>>
    >>>>
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    Tony Girgenti, Apr 9, 2007
    #11
  12. re:
    !> Also, after right-clicking and selecting properties, do you mean the
    !> "Directory Security" tab, then click "Edit" for the Authentication Methods screen?

    Yes, he means that.



    Juan T. Llibre, asp.net MVP
    asp.net faq : http://asp.net.do/faq/
    foros de asp.net, en español : http://asp.net.do/foros/
    ===================================
    "Tony Girgenti" <tony(nospam)@lakesideos.com> wrote in message
    news:...
    > Hello Mich.
    >
    > I'm sorry for sounding so stupid but i'm not sure about where to go. By "Standard website", do
    > you mean "Default Web Site"? I have XP Pro, SP1 also.
    >
    > Also, after right-clicking and selecting properties, do you mean the "Directory Security" tab,
    > then click "Edit" for the Authentication Methods screen? I don't see a "Map secutiry".
    >
    > Thanks,
    > Tony
    >
    > "Mich" <> wrote in message news:...
    >> Yes.
    >>
    >> Rightclick on Standard website (maybe diffferent in windows 2003, i use xp prof.), then take
    >> properties and then Map security. There you can choose anonymous or win. int. auth.
    >>
    >> "Tony Girgenti" <tony(nospam)@lakesideos.com> schreef in bericht
    >> news:...
    >>> Hello Mich.
    >>>
    >>> I'm trying to follow along in this thread beacuse i think i'm having the same problem.
    >>>
    >>> Can you explain where you went to change your "map security"?
    >>>
    >>> Is it in the IIS Administration?
    >>>
    >>> Any help would be gratefully appreciated.
    >>>
    >>> Thanks,
    >>> Tony
    >>>
    >>> "Mich" <> wrote in message news:eZES%...
    >>>> David, i did all those things but i found it:
    >>>> the map security of the standard website in the IIS was set on Windows Integrated Auth.
    >>>> The map security of my website (one level lower in the IIS as all other websites) is set on
    >>>> Anonymous.
    >>>> This is the reason why login and createuserwizard doesn't work.
    >>>> I changed the map security of the standard website into Anonymous and everything works.
    >>>> Amazing, no?
    >>>> Do you have an explanation for that?
    >>>>
    >>>>
    >>>> "David" <> schreef in bericht
    >>>> news:e%...
    >>>>> but what about your database?
    >>>>>
    >>>>> just having access to the directory does not give database permission.
    >>>>>
    >>>>> Set up a user in your database. Give that user permission to see the table you want to view.
    >>>>> Put that users username/password into your connection string.
    >>>>>
    >>>>> --
    >>>>> Best regards,
    >>>>> Dave Colliver.
    >>>>> http://www.AshfieldFOCUS.com
    >>>>> ~~
    >>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>
    >>>>>
    >>>>> "Mich" <> wrote in message news:...
    >>>>>> Account ASPNET has R/W rights on the APP_Data dir.
    >>>>>> And if it was not so, i would get an error, but here, no error, nothing happens ...
    >>>>>>
    >>>>>> "David" <> schreef in bericht
    >>>>>> news:...
    >>>>>>>I notice you ahve integrated security rather than user names and passwords. I may be wrong
    >>>>>>>but I think integrated security will require the current user to have permission in the
    >>>>>>>database. When you are doing it through VWDev, you are probably carrying your username
    >>>>>>>through, but when doing it from ASP.NET, you are using the ASP.NET user account, which may
    >>>>>>>not have permission.
    >>>>>>>
    >>>>>>> --
    >>>>>>> Best regards,
    >>>>>>> Dave Colliver.
    >>>>>>> http://www.AshfieldFOCUS.com
    >>>>>>> ~~
    >>>>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>>>
    >>>>>>>
    >>>>>>> "Mich" <> wrote in message news:Ox%...
    >>>>>>>> Hi Juan, thanks for replying..
    >>>>>>>>
    >>>>>>>> I did this and an mdf file ASPNETDB.MDF was created in the sql server directory.
    >>>>>>>> So i copied both files (mdf and log) into APP_Data of my application.
    >>>>>>>> I added a connection string in web.config like this:
    >>>>>>>> <add name="aspnetdb" connectionString="Data
    >>>>>>>> Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    >>>>>>>> Security=True;User Instance=True" providerName="System.Data.SqlClient"/>
    >>>>>>>>
    >>>>>>>> Now, when starting the aspx page containing the createuserwizard and filling all texboxes,
    >>>>>>>> again, nothing happens (user is not created). If i try it within VWDev., the user is then
    >>>>>>>> created.
    >>>>>>>> What do i forget or do wrong?
    >>>>>>>> Thanks
    >>>>>>>>
    >>>>>>>>
    >>>>>>>>
    >>>>>>>> "Juan T. Llibre" <> schreef in bericht
    >>>>>>>> news:...
    >>>>>>>>> Run aspnet_regsql.exe from a command window in your .Net Framework 2.0 directory.
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>> Juan T. Llibre, asp.net MVP
    >>>>>>>>> asp.net faq : http://asp.net.do/faq/
    >>>>>>>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>>>>>>> ===================================
    >>>>>>>>> "Mich" <> wrote in message news:Og6O%...
    >>>>>>>>>> Hi,
    >>>>>>>>>>
    >>>>>>>>>> i'm building an web application for anonymous users. They can take a look in the website,
    >>>>>>>>>> nothing more. In order to perform other actions, the anonymous user must be logged. So i
    >>>>>>>>>> create an aspx page with the CreateUserWizard control. The user can fill his username,
    >>>>>>>>>> password etc ....
    >>>>>>>>>>
    >>>>>>>>>> My problem is: when an user fills everything and clicks on button "create an account",
    >>>>>>>>>> nothing happens (no error, but no user account created).
    >>>>>>>>>> I thought asp.net would create in App_Data an ASPNET.MDF file for storing user and
    >>>>>>>>>> membership information and add automatically a new connection string in web.config. But
    >>>>>>>>>> it doesn't happen.
    >>>>>>>>>>
    >>>>>>>>>> I know i can go in design mode (n VWD) and click on "administer the site", but all the
    >>>>>>>>>> users are anonymous, so i can't create user in advance.
    >>>>>>>>>> Do i have to put some configuration code in web.config? Or something else?
    >>>>>>>>>>
    >>>>>>>>>> Thanks for help
    >>>>>>>>>> Mich
    >>>>>>>>>>
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>
    >>>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>
    >>>>>>
    >>>>>
    >>>>>
    >>>>
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    Juan T. Llibre, Apr 9, 2007
    #12
  13. Hello Juan.

    Well, changing that security settings didn't help me, but thanks for all
    your help.

    Tony

    "Juan T. Llibre" <> wrote in message
    news:...
    > re:
    > !> Also, after right-clicking and selecting properties, do you mean the
    > !> "Directory Security" tab, then click "Edit" for the Authentication
    > Methods screen?
    >
    > Yes, he means that.
    >
    >
    >
    > Juan T. Llibre, asp.net MVP
    > asp.net faq : http://asp.net.do/faq/
    > foros de asp.net, en español : http://asp.net.do/foros/
    > ===================================
    > "Tony Girgenti" <tony(nospam)@lakesideos.com> wrote in message
    > news:...
    >> Hello Mich.
    >>
    >> I'm sorry for sounding so stupid but i'm not sure about where to go. By
    >> "Standard website", do you mean "Default Web Site"? I have XP Pro, SP1
    >> also.
    >>
    >> Also, after right-clicking and selecting properties, do you mean the
    >> "Directory Security" tab, then click "Edit" for the Authentication
    >> Methods screen? I don't see a "Map secutiry".
    >>
    >> Thanks,
    >> Tony
    >>
    >> "Mich" <> wrote in message
    >> news:...
    >>> Yes.
    >>>
    >>> Rightclick on Standard website (maybe diffferent in windows 2003, i use
    >>> xp prof.), then take properties and then Map security. There you can
    >>> choose anonymous or win. int. auth.
    >>>
    >>> "Tony Girgenti" <tony(nospam)@lakesideos.com> schreef in bericht
    >>> news:...
    >>>> Hello Mich.
    >>>>
    >>>> I'm trying to follow along in this thread beacuse i think i'm having
    >>>> the same problem.
    >>>>
    >>>> Can you explain where you went to change your "map security"?
    >>>>
    >>>> Is it in the IIS Administration?
    >>>>
    >>>> Any help would be gratefully appreciated.
    >>>>
    >>>> Thanks,
    >>>> Tony
    >>>>
    >>>> "Mich" <> wrote in message
    >>>> news:eZES%...
    >>>>> David, i did all those things but i found it:
    >>>>> the map security of the standard website in the IIS was set on Windows
    >>>>> Integrated Auth.
    >>>>> The map security of my website (one level lower in the IIS as all
    >>>>> other websites) is set on Anonymous.
    >>>>> This is the reason why login and createuserwizard doesn't work.
    >>>>> I changed the map security of the standard website into Anonymous and
    >>>>> everything works.
    >>>>> Amazing, no?
    >>>>> Do you have an explanation for that?
    >>>>>
    >>>>>
    >>>>> "David" <> schreef in
    >>>>> bericht news:e%...
    >>>>>> but what about your database?
    >>>>>>
    >>>>>> just having access to the directory does not give database
    >>>>>> permission.
    >>>>>>
    >>>>>> Set up a user in your database. Give that user permission to see the
    >>>>>> table you want to view. Put that users username/password into your
    >>>>>> connection string.
    >>>>>>
    >>>>>> --
    >>>>>> Best regards,
    >>>>>> Dave Colliver.
    >>>>>> http://www.AshfieldFOCUS.com
    >>>>>> ~~
    >>>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>>
    >>>>>>
    >>>>>> "Mich" <> wrote in message
    >>>>>> news:...
    >>>>>>> Account ASPNET has R/W rights on the APP_Data dir.
    >>>>>>> And if it was not so, i would get an error, but here, no error,
    >>>>>>> nothing happens ...
    >>>>>>>
    >>>>>>> "David" <> schreef in
    >>>>>>> bericht news:...
    >>>>>>>>I notice you ahve integrated security rather than user names and
    >>>>>>>>passwords. I may be wrong but I think integrated security will
    >>>>>>>>require the current user to have permission in the database. When
    >>>>>>>>you are doing it through VWDev, you are probably carrying your
    >>>>>>>>username through, but when doing it from ASP.NET, you are using the
    >>>>>>>>ASP.NET user account, which may not have permission.
    >>>>>>>>
    >>>>>>>> --
    >>>>>>>> Best regards,
    >>>>>>>> Dave Colliver.
    >>>>>>>> http://www.AshfieldFOCUS.com
    >>>>>>>> ~~
    >>>>>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>>>>
    >>>>>>>>
    >>>>>>>> "Mich" <> wrote in message
    >>>>>>>> news:Ox%...
    >>>>>>>>> Hi Juan, thanks for replying..
    >>>>>>>>>
    >>>>>>>>> I did this and an mdf file ASPNETDB.MDF was created in the sql
    >>>>>>>>> server directory.
    >>>>>>>>> So i copied both files (mdf and log) into APP_Data of my
    >>>>>>>>> application.
    >>>>>>>>> I added a connection string in web.config like this:
    >>>>>>>>> <add name="aspnetdb" connectionString="Data
    >>>>>>>>> Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    >>>>>>>>> Security=True;User Instance=True"
    >>>>>>>>> providerName="System.Data.SqlClient"/>
    >>>>>>>>>
    >>>>>>>>> Now, when starting the aspx page containing the createuserwizard
    >>>>>>>>> and filling all texboxes, again, nothing happens (user is not
    >>>>>>>>> created). If i try it within VWDev., the user is then created.
    >>>>>>>>> What do i forget or do wrong?
    >>>>>>>>> Thanks
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>> "Juan T. Llibre" <> schreef in bericht
    >>>>>>>>> news:...
    >>>>>>>>>> Run aspnet_regsql.exe from a command window in your .Net
    >>>>>>>>>> Framework 2.0 directory.
    >>>>>>>>>>
    >>>>>>>>>>
    >>>>>>>>>>
    >>>>>>>>>>
    >>>>>>>>>> Juan T. Llibre, asp.net MVP
    >>>>>>>>>> asp.net faq : http://asp.net.do/faq/
    >>>>>>>>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>>>>>>>> ===================================
    >>>>>>>>>> "Mich" <> wrote in message
    >>>>>>>>>> news:Og6O%...
    >>>>>>>>>>> Hi,
    >>>>>>>>>>>
    >>>>>>>>>>> i'm building an web application for anonymous users. They can
    >>>>>>>>>>> take a look in the website, nothing more. In order to perform
    >>>>>>>>>>> other actions, the anonymous user must be logged. So i create an
    >>>>>>>>>>> aspx page with the CreateUserWizard control. The user can fill
    >>>>>>>>>>> his username, password etc ....
    >>>>>>>>>>>
    >>>>>>>>>>> My problem is: when an user fills everything and clicks on
    >>>>>>>>>>> button "create an account", nothing happens (no error, but no
    >>>>>>>>>>> user account created).
    >>>>>>>>>>> I thought asp.net would create in App_Data an ASPNET.MDF file
    >>>>>>>>>>> for storing user and membership information and add
    >>>>>>>>>>> automatically a new connection string in web.config. But it
    >>>>>>>>>>> doesn't happen.
    >>>>>>>>>>>
    >>>>>>>>>>> I know i can go in design mode (n VWD) and click on "administer
    >>>>>>>>>>> the site", but all the users are anonymous, so i can't create
    >>>>>>>>>>> user in advance.
    >>>>>>>>>>> Do i have to put some configuration code in web.config? Or
    >>>>>>>>>>> something else?
    >>>>>>>>>>>
    >>>>>>>>>>> Thanks for help
    >>>>>>>>>>> Mich
    >>>>>>>>>>>
    >>>>>>>>>>
    >>>>>>>>>>
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>
    >>>>>>>>
    >>>>>>>
    >>>>>>>
    >>>>>>
    >>>>>>
    >>>>>
    >>>>>
    >>>>
    >>>>
    >>>
    >>>

    >>
    >>

    >
    >
    Tony Girgenti, Apr 9, 2007
    #13
  14. re:
    > Well, changing that security settings didn't help me, but thanks for all your help.


    1. What did you change...and to what ?
    2. What happened after you changed it ?
    3. Can you restate your problem ? ( Is it different than the OP's problem ? )




    Juan T. Llibre, asp.net MVP
    asp.net faq : http://asp.net.do/faq/
    foros de asp.net, en español : http://asp.net.do/foros/
    ===================================
    "Tony Girgenti" <tony(nospam)@lakesideos.com> wrote in message
    news:...
    > Hello Juan.
    >
    > Well, changing that security settings didn't help me, but thanks for all your help.
    >
    > Tony
    >
    > "Juan T. Llibre" <> wrote in message
    > news:...
    >> re:
    >> !> Also, after right-clicking and selecting properties, do you mean the
    >> !> "Directory Security" tab, then click "Edit" for the Authentication Methods screen?
    >>
    >> Yes, he means that.
    >>
    >>
    >>
    >> Juan T. Llibre, asp.net MVP
    >> asp.net faq : http://asp.net.do/faq/
    >> foros de asp.net, en español : http://asp.net.do/foros/
    >> ===================================
    >> "Tony Girgenti" <tony(nospam)@lakesideos.com> wrote in message
    >> news:...
    >>> Hello Mich.
    >>>
    >>> I'm sorry for sounding so stupid but i'm not sure about where to go. By "Standard website", do
    >>> you mean "Default Web Site"? I have XP Pro, SP1 also.
    >>>
    >>> Also, after right-clicking and selecting properties, do you mean the "Directory Security" tab,
    >>> then click "Edit" for the Authentication Methods screen? I don't see a "Map secutiry".
    >>>
    >>> Thanks,
    >>> Tony
    >>>
    >>> "Mich" <> wrote in message news:...
    >>>> Yes.
    >>>>
    >>>> Rightclick on Standard website (maybe diffferent in windows 2003, i use xp prof.), then take
    >>>> properties and then Map security. There you can choose anonymous or win. int. auth.
    >>>>
    >>>> "Tony Girgenti" <tony(nospam)@lakesideos.com> schreef in bericht
    >>>> news:...
    >>>>> Hello Mich.
    >>>>>
    >>>>> I'm trying to follow along in this thread beacuse i think i'm having the same problem.
    >>>>>
    >>>>> Can you explain where you went to change your "map security"?
    >>>>>
    >>>>> Is it in the IIS Administration?
    >>>>>
    >>>>> Any help would be gratefully appreciated.
    >>>>>
    >>>>> Thanks,
    >>>>> Tony
    >>>>>
    >>>>> "Mich" <> wrote in message news:eZES%...
    >>>>>> David, i did all those things but i found it:
    >>>>>> the map security of the standard website in the IIS was set on Windows Integrated Auth.
    >>>>>> The map security of my website (one level lower in the IIS as all other websites) is set on
    >>>>>> Anonymous.
    >>>>>> This is the reason why login and createuserwizard doesn't work.
    >>>>>> I changed the map security of the standard website into Anonymous and everything works.
    >>>>>> Amazing, no?
    >>>>>> Do you have an explanation for that?
    >>>>>>
    >>>>>>
    >>>>>> "David" <> schreef in bericht
    >>>>>> news:e%...
    >>>>>>> but what about your database?
    >>>>>>>
    >>>>>>> just having access to the directory does not give database permission.
    >>>>>>>
    >>>>>>> Set up a user in your database. Give that user permission to see the table you want to view.
    >>>>>>> Put that users username/password into your connection string.
    >>>>>>>
    >>>>>>> --
    >>>>>>> Best regards,
    >>>>>>> Dave Colliver.
    >>>>>>> http://www.AshfieldFOCUS.com
    >>>>>>> ~~
    >>>>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>>>
    >>>>>>>
    >>>>>>> "Mich" <> wrote in message news:...
    >>>>>>>> Account ASPNET has R/W rights on the APP_Data dir.
    >>>>>>>> And if it was not so, i would get an error, but here, no error, nothing happens ...
    >>>>>>>>
    >>>>>>>> "David" <> schreef in bericht
    >>>>>>>> news:...
    >>>>>>>>>I notice you ahve integrated security rather than user names and passwords. I may be wrong
    >>>>>>>>>but I think integrated security will require the current user to have permission in the
    >>>>>>>>>database. When you are doing it through VWDev, you are probably carrying your username
    >>>>>>>>>through, but when doing it from ASP.NET, you are using the ASP.NET user account, which may
    >>>>>>>>>not have permission.
    >>>>>>>>>
    >>>>>>>>> --
    >>>>>>>>> Best regards,
    >>>>>>>>> Dave Colliver.
    >>>>>>>>> http://www.AshfieldFOCUS.com
    >>>>>>>>> ~~
    >>>>>>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>> "Mich" <> wrote in message news:Ox%...
    >>>>>>>>>> Hi Juan, thanks for replying..
    >>>>>>>>>>
    >>>>>>>>>> I did this and an mdf file ASPNETDB.MDF was created in the sql server directory.
    >>>>>>>>>> So i copied both files (mdf and log) into APP_Data of my application.
    >>>>>>>>>> I added a connection string in web.config like this:
    >>>>>>>>>> <add name="aspnetdb" connectionString="Data
    >>>>>>>>>> Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    >>>>>>>>>> Security=True;User Instance=True" providerName="System.Data.SqlClient"/>
    >>>>>>>>>>
    >>>>>>>>>> Now, when starting the aspx page containing the createuserwizard and filling all
    >>>>>>>>>> texboxes, again, nothing happens (user is not created). If i try it within VWDev., the
    >>>>>>>>>> user is then created.
    >>>>>>>>>> What do i forget or do wrong?
    >>>>>>>>>> Thanks
    >>>>>>>>>>
    >>>>>>>>>>
    >>>>>>>>>>
    >>>>>>>>>> "Juan T. Llibre" <> schreef in bericht
    >>>>>>>>>> news:...
    >>>>>>>>>>> Run aspnet_regsql.exe from a command window in your .Net Framework 2.0 directory.
    >>>>>>>>>>>
    >>>>>>>>>>>
    >>>>>>>>>>>
    >>>>>>>>>>>
    >>>>>>>>>>> Juan T. Llibre, asp.net MVP
    >>>>>>>>>>> asp.net faq : http://asp.net.do/faq/
    >>>>>>>>>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>>>>>>>>> ===================================
    >>>>>>>>>>> "Mich" <> wrote in message news:Og6O%...
    >>>>>>>>>>>> Hi,
    >>>>>>>>>>>>
    >>>>>>>>>>>> i'm building an web application for anonymous users. They can take a look in the
    >>>>>>>>>>>> website, nothing more. In order to perform other actions, the anonymous user must be
    >>>>>>>>>>>> logged. So i create an aspx page with the CreateUserWizard control. The user can fill
    >>>>>>>>>>>> his username, password etc ....
    >>>>>>>>>>>>
    >>>>>>>>>>>> My problem is: when an user fills everything and clicks on button "create an account",
    >>>>>>>>>>>> nothing happens (no error, but no user account created).
    >>>>>>>>>>>> I thought asp.net would create in App_Data an ASPNET.MDF file for storing user and
    >>>>>>>>>>>> membership information and add automatically a new connection string in web.config. But
    >>>>>>>>>>>> it doesn't happen.
    >>>>>>>>>>>>
    >>>>>>>>>>>> I know i can go in design mode (n VWD) and click on "administer the site", but all the
    >>>>>>>>>>>> users are anonymous, so i can't create user in advance.
    >>>>>>>>>>>> Do i have to put some configuration code in web.config? Or something else?
    >>>>>>>>>>>>
    >>>>>>>>>>>> Thanks for help
    >>>>>>>>>>>> Mich
    Juan T. Llibre, Apr 10, 2007
    #14
  15. Hello Juan.

    I unchecked the "Anonymous access" box on the Authentication Methods screen.
    After doing so, nothing changed, so i just figured that it did not help.

    My problem is outlined in the next post down.

    Thanks,
    Tony

    "Juan T. Llibre" <> wrote in message
    news:...
    > re:
    >> Well, changing that security settings didn't help me, but thanks for all
    >> your help.

    >
    > 1. What did you change...and to what ?
    > 2. What happened after you changed it ?
    > 3. Can you restate your problem ? ( Is it different than the OP's problem
    > ? )
    >
    >
    >
    >
    > Juan T. Llibre, asp.net MVP
    > asp.net faq : http://asp.net.do/faq/
    > foros de asp.net, en español : http://asp.net.do/foros/
    > ===================================
    > "Tony Girgenti" <tony(nospam)@lakesideos.com> wrote in message
    > news:...
    >> Hello Juan.
    >>
    >> Well, changing that security settings didn't help me, but thanks for all
    >> your help.
    >>
    >> Tony
    >>
    >> "Juan T. Llibre" <> wrote in message
    >> news:...
    >>> re:
    >>> !> Also, after right-clicking and selecting properties, do you mean the
    >>> !> "Directory Security" tab, then click "Edit" for the Authentication
    >>> Methods screen?
    >>>
    >>> Yes, he means that.
    >>>
    >>>
    >>>
    >>> Juan T. Llibre, asp.net MVP
    >>> asp.net faq : http://asp.net.do/faq/
    >>> foros de asp.net, en español : http://asp.net.do/foros/
    >>> ===================================
    >>> "Tony Girgenti" <tony(nospam)@lakesideos.com> wrote in message
    >>> news:...
    >>>> Hello Mich.
    >>>>
    >>>> I'm sorry for sounding so stupid but i'm not sure about where to go.
    >>>> By "Standard website", do you mean "Default Web Site"? I have XP Pro,
    >>>> SP1 also.
    >>>>
    >>>> Also, after right-clicking and selecting properties, do you mean the
    >>>> "Directory Security" tab, then click "Edit" for the Authentication
    >>>> Methods screen? I don't see a "Map secutiry".
    >>>>
    >>>> Thanks,
    >>>> Tony
    >>>>
    >>>> "Mich" <> wrote in message
    >>>> news:...
    >>>>> Yes.
    >>>>>
    >>>>> Rightclick on Standard website (maybe diffferent in windows 2003, i
    >>>>> use xp prof.), then take properties and then Map security. There you
    >>>>> can choose anonymous or win. int. auth.
    >>>>>
    >>>>> "Tony Girgenti" <tony(nospam)@lakesideos.com> schreef in bericht
    >>>>> news:...
    >>>>>> Hello Mich.
    >>>>>>
    >>>>>> I'm trying to follow along in this thread beacuse i think i'm having
    >>>>>> the same problem.
    >>>>>>
    >>>>>> Can you explain where you went to change your "map security"?
    >>>>>>
    >>>>>> Is it in the IIS Administration?
    >>>>>>
    >>>>>> Any help would be gratefully appreciated.
    >>>>>>
    >>>>>> Thanks,
    >>>>>> Tony
    >>>>>>
    >>>>>> "Mich" <> wrote in message
    >>>>>> news:eZES%...
    >>>>>>> David, i did all those things but i found it:
    >>>>>>> the map security of the standard website in the IIS was set on
    >>>>>>> Windows Integrated Auth.
    >>>>>>> The map security of my website (one level lower in the IIS as all
    >>>>>>> other websites) is set on Anonymous.
    >>>>>>> This is the reason why login and createuserwizard doesn't work.
    >>>>>>> I changed the map security of the standard website into Anonymous
    >>>>>>> and everything works.
    >>>>>>> Amazing, no?
    >>>>>>> Do you have an explanation for that?
    >>>>>>>
    >>>>>>>
    >>>>>>> "David" <> schreef in
    >>>>>>> bericht news:e%...
    >>>>>>>> but what about your database?
    >>>>>>>>
    >>>>>>>> just having access to the directory does not give database
    >>>>>>>> permission.
    >>>>>>>>
    >>>>>>>> Set up a user in your database. Give that user permission to see
    >>>>>>>> the table you want to view. Put that users username/password into
    >>>>>>>> your connection string.
    >>>>>>>>
    >>>>>>>> --
    >>>>>>>> Best regards,
    >>>>>>>> Dave Colliver.
    >>>>>>>> http://www.AshfieldFOCUS.com
    >>>>>>>> ~~
    >>>>>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>>>>
    >>>>>>>>
    >>>>>>>> "Mich" <> wrote in message
    >>>>>>>> news:...
    >>>>>>>>> Account ASPNET has R/W rights on the APP_Data dir.
    >>>>>>>>> And if it was not so, i would get an error, but here, no error,
    >>>>>>>>> nothing happens ...
    >>>>>>>>>
    >>>>>>>>> "David" <> schreef in
    >>>>>>>>> bericht news:...
    >>>>>>>>>>I notice you ahve integrated security rather than user names and
    >>>>>>>>>>passwords. I may be wrong but I think integrated security will
    >>>>>>>>>>require the current user to have permission in the database. When
    >>>>>>>>>>you are doing it through VWDev, you are probably carrying your
    >>>>>>>>>>username through, but when doing it from ASP.NET, you are using
    >>>>>>>>>>the ASP.NET user account, which may not have permission.
    >>>>>>>>>>
    >>>>>>>>>> --
    >>>>>>>>>> Best regards,
    >>>>>>>>>> Dave Colliver.
    >>>>>>>>>> http://www.AshfieldFOCUS.com
    >>>>>>>>>> ~~
    >>>>>>>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>>>>>>
    >>>>>>>>>>
    >>>>>>>>>> "Mich" <> wrote in message
    >>>>>>>>>> news:Ox%...
    >>>>>>>>>>> Hi Juan, thanks for replying..
    >>>>>>>>>>>
    >>>>>>>>>>> I did this and an mdf file ASPNETDB.MDF was created in the sql
    >>>>>>>>>>> server directory.
    >>>>>>>>>>> So i copied both files (mdf and log) into APP_Data of my
    >>>>>>>>>>> application.
    >>>>>>>>>>> I added a connection string in web.config like this:
    >>>>>>>>>>> <add name="aspnetdb" connectionString="Data
    >>>>>>>>>>> Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    >>>>>>>>>>> Security=True;User Instance=True"
    >>>>>>>>>>> providerName="System.Data.SqlClient"/>
    >>>>>>>>>>>
    >>>>>>>>>>> Now, when starting the aspx page containing the createuserwizard
    >>>>>>>>>>> and filling all texboxes, again, nothing happens (user is not
    >>>>>>>>>>> created). If i try it within VWDev., the user is then created.
    >>>>>>>>>>> What do i forget or do wrong?
    >>>>>>>>>>> Thanks
    >>>>>>>>>>>
    >>>>>>>>>>>
    >>>>>>>>>>>
    >>>>>>>>>>> "Juan T. Llibre" <> schreef in bericht
    >>>>>>>>>>> news:...
    >>>>>>>>>>>> Run aspnet_regsql.exe from a command window in your .Net
    >>>>>>>>>>>> Framework 2.0 directory.
    >>>>>>>>>>>>
    >>>>>>>>>>>>
    >>>>>>>>>>>>
    >>>>>>>>>>>>
    >>>>>>>>>>>> Juan T. Llibre, asp.net MVP
    >>>>>>>>>>>> asp.net faq : http://asp.net.do/faq/
    >>>>>>>>>>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>>>>>>>>>> ===================================
    >>>>>>>>>>>> "Mich" <> wrote in message
    >>>>>>>>>>>> news:Og6O%...
    >>>>>>>>>>>>> Hi,
    >>>>>>>>>>>>>
    >>>>>>>>>>>>> i'm building an web application for anonymous users. They can
    >>>>>>>>>>>>> take a look in the website, nothing more. In order to perform
    >>>>>>>>>>>>> other actions, the anonymous user must be logged. So i create
    >>>>>>>>>>>>> an aspx page with the CreateUserWizard control. The user can
    >>>>>>>>>>>>> fill his username, password etc ....
    >>>>>>>>>>>>>
    >>>>>>>>>>>>> My problem is: when an user fills everything and clicks on
    >>>>>>>>>>>>> button "create an account", nothing happens (no error, but no
    >>>>>>>>>>>>> user account created).
    >>>>>>>>>>>>> I thought asp.net would create in App_Data an ASPNET.MDF file
    >>>>>>>>>>>>> for storing user and membership information and add
    >>>>>>>>>>>>> automatically a new connection string in web.config. But it
    >>>>>>>>>>>>> doesn't happen.
    >>>>>>>>>>>>>
    >>>>>>>>>>>>> I know i can go in design mode (n VWD) and click on
    >>>>>>>>>>>>> "administer the site", but all the users are anonymous, so i
    >>>>>>>>>>>>> can't create user in advance.
    >>>>>>>>>>>>> Do i have to put some configuration code in web.config? Or
    >>>>>>>>>>>>> something else?
    >>>>>>>>>>>>>
    >>>>>>>>>>>>> Thanks for help
    >>>>>>>>>>>>> Mich

    >
    >
    Tony Girgenti, Apr 10, 2007
    #15
  16. re:
    !> I unchecked the "Anonymous access" box on the Authentication Methods screen.

    Hi, Tony.

    The OP's problem was solved by *allowing* anonymous access,
    not by requiring authentication.

    When you *uncheck* the anonymous access box, you are -effectively- *requiring* authentication.

    Let's see if we can do a little detective work and find out which account
    ASP.NET is running as, so you can assign permissions to the correct account.

    First of all, are you using impersonation ?
    Knowing that will make a difference.

    Secondly, can you save this page and run it from the root directory of your app ?

    identity.aspx :
    --------------------
    <%@ Page Language="VB" %>
    <%@ Import NameSpace = System.Security.Principal %>
    <script runat="server">
    Sub Page_Load()
    Dim tmp As String = WindowsIdentity.GetCurrent.Name()
    Label1.Text = "ASP.NET is running as the account : " & tmp
    End Sub
    </script>
    <html>
    <head>
    <title>What account is ASP.NET running as ?</title>
    </head>
    <body>
    <form id="form1" runat="server">
    <div>
    <asp:Label ID="Label1" Runat="server" Text="Label"></asp:Label>
    </div>
    </form>
    </body>
    </html>
    ---------------------

    Whichever account is returned will be the account that needs access permission
    to the App_Data directory and database, if you're using a trusted connection,
    unless you are using a *specific* account to access your membership database.

    Please read through Scott Mitchell's tutorial :

    http://aspnet.4guysfromrolla.com/articles/120705-1.aspx

    It has invaluable background info which will make your life easier
    when trying to implement ASP.NET Membership.




    Juan T. Llibre, asp.net MVP
    asp.net faq : http://asp.net.do/faq/
    foros de asp.net, en español : http://asp.net.do/foros/
    ===================================
    "Tony Girgenti" <tony(nospam)@lakesideos.com> wrote in message
    news:...
    > Hello Juan.
    >
    > I unchecked the "Anonymous access" box on the Authentication Methods screen. After doing so,
    > nothing changed, so i just figured that it did not help.
    >
    > My problem is outlined in the next post down.
    >
    > Thanks,
    > Tony
    >
    > "Juan T. Llibre" <> wrote in message
    > news:...
    >> re:
    >>> Well, changing that security settings didn't help me, but thanks for all your help.

    >>
    >> 1. What did you change...and to what ?
    >> 2. What happened after you changed it ?
    >> 3. Can you restate your problem ? ( Is it different than the OP's problem ? )
    >>
    >>
    >>
    >>
    >> Juan T. Llibre, asp.net MVP
    >> asp.net faq : http://asp.net.do/faq/
    >> foros de asp.net, en español : http://asp.net.do/foros/
    >> ===================================
    >> "Tony Girgenti" <tony(nospam)@lakesideos.com> wrote in message
    >> news:...
    >>> Hello Juan.
    >>>
    >>> Well, changing that security settings didn't help me, but thanks for all your help.
    >>>
    >>> Tony
    >>>
    >>> "Juan T. Llibre" <> wrote in message
    >>> news:...
    >>>> re:
    >>>> !> Also, after right-clicking and selecting properties, do you mean the
    >>>> !> "Directory Security" tab, then click "Edit" for the Authentication Methods screen?
    >>>>
    >>>> Yes, he means that.
    >>>>
    >>>>
    >>>>
    >>>> Juan T. Llibre, asp.net MVP
    >>>> asp.net faq : http://asp.net.do/faq/
    >>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>> ===================================
    >>>> "Tony Girgenti" <tony(nospam)@lakesideos.com> wrote in message
    >>>> news:...
    >>>>> Hello Mich.
    >>>>>
    >>>>> I'm sorry for sounding so stupid but i'm not sure about where to go. By "Standard website", do
    >>>>> you mean "Default Web Site"? I have XP Pro, SP1 also.
    >>>>>
    >>>>> Also, after right-clicking and selecting properties, do you mean the "Directory Security" tab,
    >>>>> then click "Edit" for the Authentication Methods screen? I don't see a "Map secutiry".
    >>>>>
    >>>>> Thanks,
    >>>>> Tony
    >>>>>
    >>>>> "Mich" <> wrote in message news:...
    >>>>>> Yes.
    >>>>>>
    >>>>>> Rightclick on Standard website (maybe diffferent in windows 2003, i use xp prof.), then take
    >>>>>> properties and then Map security. There you can choose anonymous or win. int. auth.
    >>>>>>
    >>>>>> "Tony Girgenti" <tony(nospam)@lakesideos.com> schreef in bericht
    >>>>>> news:...
    >>>>>>> Hello Mich.
    >>>>>>>
    >>>>>>> I'm trying to follow along in this thread beacuse i think i'm having the same problem.
    >>>>>>>
    >>>>>>> Can you explain where you went to change your "map security"?
    >>>>>>>
    >>>>>>> Is it in the IIS Administration?
    >>>>>>>
    >>>>>>> Any help would be gratefully appreciated.
    >>>>>>>
    >>>>>>> Thanks,
    >>>>>>> Tony
    >>>>>>>
    >>>>>>> "Mich" <> wrote in message news:eZES%...
    >>>>>>>> David, i did all those things but i found it:
    >>>>>>>> the map security of the standard website in the IIS was set on Windows Integrated Auth.
    >>>>>>>> The map security of my website (one level lower in the IIS as all other websites) is set on
    >>>>>>>> Anonymous.
    >>>>>>>> This is the reason why login and createuserwizard doesn't work.
    >>>>>>>> I changed the map security of the standard website into Anonymous and everything works.
    >>>>>>>> Amazing, no?
    >>>>>>>> Do you have an explanation for that?
    >>>>>>>>
    >>>>>>>>
    >>>>>>>> "David" <> schreef in bericht
    >>>>>>>> news:e%...
    >>>>>>>>> but what about your database?
    >>>>>>>>>
    >>>>>>>>> just having access to the directory does not give database permission.
    >>>>>>>>>
    >>>>>>>>> Set up a user in your database. Give that user permission to see the table you want to
    >>>>>>>>> view. Put that users username/password into your connection string.
    >>>>>>>>>
    >>>>>>>>> --
    >>>>>>>>> Best regards,
    >>>>>>>>> Dave Colliver.
    >>>>>>>>> http://www.AshfieldFOCUS.com
    >>>>>>>>> ~~
    >>>>>>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>> "Mich" <> wrote in message news:...
    >>>>>>>>>> Account ASPNET has R/W rights on the APP_Data dir.
    >>>>>>>>>> And if it was not so, i would get an error, but here, no error, nothing happens ...
    >>>>>>>>>>
    >>>>>>>>>> "David" <> schreef in bericht
    >>>>>>>>>> news:...
    >>>>>>>>>>>I notice you ahve integrated security rather than user names and passwords. I may be
    >>>>>>>>>>>wrong but I think integrated security will require the current user to have permission in
    >>>>>>>>>>>the database. When you are doing it through VWDev, you are probably carrying your
    >>>>>>>>>>>username through, but when doing it from ASP.NET, you are using the ASP.NET user account,
    >>>>>>>>>>>which may not have permission.
    >>>>>>>>>>>
    >>>>>>>>>>> --
    >>>>>>>>>>> Best regards,
    >>>>>>>>>>> Dave Colliver.
    >>>>>>>>>>> http://www.AshfieldFOCUS.com
    >>>>>>>>>>> ~~
    >>>>>>>>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>>>>>>>
    >>>>>>>>>>>
    >>>>>>>>>>> "Mich" <> wrote in message news:Ox%...
    >>>>>>>>>>>> Hi Juan, thanks for replying..
    >>>>>>>>>>>>
    >>>>>>>>>>>> I did this and an mdf file ASPNETDB.MDF was created in the sql server directory.
    >>>>>>>>>>>> So i copied both files (mdf and log) into APP_Data of my application.
    >>>>>>>>>>>> I added a connection string in web.config like this:
    >>>>>>>>>>>> <add name="aspnetdb" connectionString="Data
    >>>>>>>>>>>> Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    >>>>>>>>>>>> Security=True;User Instance=True" providerName="System.Data.SqlClient"/>
    >>>>>>>>>>>>
    >>>>>>>>>>>> Now, when starting the aspx page containing the createuserwizard and filling all
    >>>>>>>>>>>> texboxes, again, nothing happens (user is not created). If i try it within VWDev., the
    >>>>>>>>>>>> user is then created.
    >>>>>>>>>>>> What do i forget or do wrong?
    >>>>>>>>>>>> Thanks
    >>>>>>>>>>>>
    >>>>>>>>>>>>
    >>>>>>>>>>>>
    >>>>>>>>>>>> "Juan T. Llibre" <> schreef in bericht
    >>>>>>>>>>>> news:...
    >>>>>>>>>>>>> Run aspnet_regsql.exe from a command window in your .Net Framework 2.0 directory.
    >>>>>>>>>>>>>
    >>>>>>>>>>>>>
    >>>>>>>>>>>>>
    >>>>>>>>>>>>>
    >>>>>>>>>>>>> Juan T. Llibre, asp.net MVP
    >>>>>>>>>>>>> asp.net faq : http://asp.net.do/faq/
    >>>>>>>>>>>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>>>>>>>>>>> ===================================
    >>>>>>>>>>>>> "Mich" <> wrote in message news:Og6O%...
    >>>>>>>>>>>>>> Hi,
    >>>>>>>>>>>>>>
    >>>>>>>>>>>>>> i'm building an web application for anonymous users. They can take a look in the
    >>>>>>>>>>>>>> website, nothing more. In order to perform other actions, the anonymous user must be
    >>>>>>>>>>>>>> logged. So i create an aspx page with the CreateUserWizard control. The user can fill
    >>>>>>>>>>>>>> his username, password etc ....
    >>>>>>>>>>>>>>
    >>>>>>>>>>>>>> My problem is: when an user fills everything and clicks on button "create an
    >>>>>>>>>>>>>> account", nothing happens (no error, but no user account created).
    >>>>>>>>>>>>>> I thought asp.net would create in App_Data an ASPNET.MDF file for storing user and
    >>>>>>>>>>>>>> membership information and add automatically a new connection string in web.config.
    >>>>>>>>>>>>>> But it doesn't happen.
    >>>>>>>>>>>>>>
    >>>>>>>>>>>>>> I know i can go in design mode (n VWD) and click on "administer the site", but all
    >>>>>>>>>>>>>> the users are anonymous, so i can't create user in advance.
    >>>>>>>>>>>>>> Do i have to put some configuration code in web.config? Or something else?
    >>>>>>>>>>>>>>
    >>>>>>>>>>>>>> Thanks for help
    >>>>>>>>>>>>>> Mich
    Juan T. Llibre, Apr 10, 2007
    #16
  17. Hello Juan.

    After posting my last rrply to you, i found an article on Google where a guy
    said he deleted the login control from the form and recreated it. I tried
    that and it worked for me.

    I can't explain it but it resolved my problem. Maybe you know why?

    Thanks again for all of your help.

    Tony

    "Juan T. Llibre" <> wrote in message
    news:%...
    > re:
    > !> I unchecked the "Anonymous access" box on the Authentication Methods
    > screen.
    >
    > Hi, Tony.
    >
    > The OP's problem was solved by *allowing* anonymous access,
    > not by requiring authentication.
    >
    > When you *uncheck* the anonymous access box, you are -effectively-
    > *requiring* authentication.
    >
    > Let's see if we can do a little detective work and find out which account
    > ASP.NET is running as, so you can assign permissions to the correct
    > account.
    >
    > First of all, are you using impersonation ?
    > Knowing that will make a difference.
    >
    > Secondly, can you save this page and run it from the root directory of
    > your app ?
    >
    > identity.aspx :
    > --------------------
    > <%@ Page Language="VB" %>
    > <%@ Import NameSpace = System.Security.Principal %>
    > <script runat="server">
    > Sub Page_Load()
    > Dim tmp As String = WindowsIdentity.GetCurrent.Name()
    > Label1.Text = "ASP.NET is running as the account : " & tmp
    > End Sub
    > </script>
    > <html>
    > <head>
    > <title>What account is ASP.NET running as ?</title>
    > </head>
    > <body>
    > <form id="form1" runat="server">
    > <div>
    > <asp:Label ID="Label1" Runat="server" Text="Label"></asp:Label>
    > </div>
    > </form>
    > </body>
    > </html>
    > ---------------------
    >
    > Whichever account is returned will be the account that needs access
    > permission
    > to the App_Data directory and database, if you're using a trusted
    > connection,
    > unless you are using a *specific* account to access your membership
    > database.
    >
    > Please read through Scott Mitchell's tutorial :
    >
    > http://aspnet.4guysfromrolla.com/articles/120705-1.aspx
    >
    > It has invaluable background info which will make your life easier
    > when trying to implement ASP.NET Membership.
    >
    >
    >
    >
    > Juan T. Llibre, asp.net MVP
    > asp.net faq : http://asp.net.do/faq/
    > foros de asp.net, en español : http://asp.net.do/foros/
    > ===================================
    > "Tony Girgenti" <tony(nospam)@lakesideos.com> wrote in message
    > news:...
    >> Hello Juan.
    >>
    >> I unchecked the "Anonymous access" box on the Authentication Methods
    >> screen. After doing so, nothing changed, so i just figured that it did
    >> not help.
    >>
    >> My problem is outlined in the next post down.
    >>
    >> Thanks,
    >> Tony
    >>
    >> "Juan T. Llibre" <> wrote in message
    >> news:...
    >>> re:
    >>>> Well, changing that security settings didn't help me, but thanks for
    >>>> all your help.
    >>>
    >>> 1. What did you change...and to what ?
    >>> 2. What happened after you changed it ?
    >>> 3. Can you restate your problem ? ( Is it different than the OP's
    >>> problem ? )
    >>>
    >>>
    >>>
    >>>
    >>> Juan T. Llibre, asp.net MVP
    >>> asp.net faq : http://asp.net.do/faq/
    >>> foros de asp.net, en español : http://asp.net.do/foros/
    >>> ===================================
    >>> "Tony Girgenti" <tony(nospam)@lakesideos.com> wrote in message
    >>> news:...
    >>>> Hello Juan.
    >>>>
    >>>> Well, changing that security settings didn't help me, but thanks for
    >>>> all your help.
    >>>>
    >>>> Tony
    >>>>
    >>>> "Juan T. Llibre" <> wrote in message
    >>>> news:...
    >>>>> re:
    >>>>> !> Also, after right-clicking and selecting properties, do you mean
    >>>>> the
    >>>>> !> "Directory Security" tab, then click "Edit" for the Authentication
    >>>>> Methods screen?
    >>>>>
    >>>>> Yes, he means that.
    >>>>>
    >>>>>
    >>>>>
    >>>>> Juan T. Llibre, asp.net MVP
    >>>>> asp.net faq : http://asp.net.do/faq/
    >>>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>>> ===================================
    >>>>> "Tony Girgenti" <tony(nospam)@lakesideos.com> wrote in message
    >>>>> news:...
    >>>>>> Hello Mich.
    >>>>>>
    >>>>>> I'm sorry for sounding so stupid but i'm not sure about where to go.
    >>>>>> By "Standard website", do you mean "Default Web Site"? I have XP
    >>>>>> Pro, SP1 also.
    >>>>>>
    >>>>>> Also, after right-clicking and selecting properties, do you mean the
    >>>>>> "Directory Security" tab, then click "Edit" for the Authentication
    >>>>>> Methods screen? I don't see a "Map secutiry".
    >>>>>>
    >>>>>> Thanks,
    >>>>>> Tony
    >>>>>>
    >>>>>> "Mich" <> wrote in message
    >>>>>> news:...
    >>>>>>> Yes.
    >>>>>>>
    >>>>>>> Rightclick on Standard website (maybe diffferent in windows 2003, i
    >>>>>>> use xp prof.), then take properties and then Map security. There you
    >>>>>>> can choose anonymous or win. int. auth.
    >>>>>>>
    >>>>>>> "Tony Girgenti" <tony(nospam)@lakesideos.com> schreef in bericht
    >>>>>>> news:...
    >>>>>>>> Hello Mich.
    >>>>>>>>
    >>>>>>>> I'm trying to follow along in this thread beacuse i think i'm
    >>>>>>>> having the same problem.
    >>>>>>>>
    >>>>>>>> Can you explain where you went to change your "map security"?
    >>>>>>>>
    >>>>>>>> Is it in the IIS Administration?
    >>>>>>>>
    >>>>>>>> Any help would be gratefully appreciated.
    >>>>>>>>
    >>>>>>>> Thanks,
    >>>>>>>> Tony
    >>>>>>>>
    >>>>>>>> "Mich" <> wrote in message
    >>>>>>>> news:eZES%...
    >>>>>>>>> David, i did all those things but i found it:
    >>>>>>>>> the map security of the standard website in the IIS was set on
    >>>>>>>>> Windows Integrated Auth.
    >>>>>>>>> The map security of my website (one level lower in the IIS as all
    >>>>>>>>> other websites) is set on Anonymous.
    >>>>>>>>> This is the reason why login and createuserwizard doesn't work.
    >>>>>>>>> I changed the map security of the standard website into Anonymous
    >>>>>>>>> and everything works.
    >>>>>>>>> Amazing, no?
    >>>>>>>>> Do you have an explanation for that?
    >>>>>>>>>
    >>>>>>>>>
    >>>>>>>>> "David" <> schreef in
    >>>>>>>>> bericht news:e%...
    >>>>>>>>>> but what about your database?
    >>>>>>>>>>
    >>>>>>>>>> just having access to the directory does not give database
    >>>>>>>>>> permission.
    >>>>>>>>>>
    >>>>>>>>>> Set up a user in your database. Give that user permission to see
    >>>>>>>>>> the table you want to view. Put that users username/password into
    >>>>>>>>>> your connection string.
    >>>>>>>>>>
    >>>>>>>>>> --
    >>>>>>>>>> Best regards,
    >>>>>>>>>> Dave Colliver.
    >>>>>>>>>> http://www.AshfieldFOCUS.com
    >>>>>>>>>> ~~
    >>>>>>>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>>>>>>
    >>>>>>>>>>
    >>>>>>>>>> "Mich" <> wrote in message
    >>>>>>>>>> news:...
    >>>>>>>>>>> Account ASPNET has R/W rights on the APP_Data dir.
    >>>>>>>>>>> And if it was not so, i would get an error, but here, no error,
    >>>>>>>>>>> nothing happens ...
    >>>>>>>>>>>
    >>>>>>>>>>> "David" <> schreef in
    >>>>>>>>>>> bericht news:...
    >>>>>>>>>>>>I notice you ahve integrated security rather than user names and
    >>>>>>>>>>>>passwords. I may be wrong but I think integrated security will
    >>>>>>>>>>>>require the current user to have permission in the database.
    >>>>>>>>>>>>When you are doing it through VWDev, you are probably carrying
    >>>>>>>>>>>>your username through, but when doing it from ASP.NET, you are
    >>>>>>>>>>>>using the ASP.NET user account, which may not have permission.
    >>>>>>>>>>>>
    >>>>>>>>>>>> --
    >>>>>>>>>>>> Best regards,
    >>>>>>>>>>>> Dave Colliver.
    >>>>>>>>>>>> http://www.AshfieldFOCUS.com
    >>>>>>>>>>>> ~~
    >>>>>>>>>>>> http://www.FOCUSPortals.com - Local franchises available
    >>>>>>>>>>>>
    >>>>>>>>>>>>
    >>>>>>>>>>>> "Mich" <> wrote in message
    >>>>>>>>>>>> news:Ox%...
    >>>>>>>>>>>>> Hi Juan, thanks for replying..
    >>>>>>>>>>>>>
    >>>>>>>>>>>>> I did this and an mdf file ASPNETDB.MDF was created in the sql
    >>>>>>>>>>>>> server directory.
    >>>>>>>>>>>>> So i copied both files (mdf and log) into APP_Data of my
    >>>>>>>>>>>>> application.
    >>>>>>>>>>>>> I added a connection string in web.config like this:
    >>>>>>>>>>>>> <add name="aspnetdb" connectionString="Data
    >>>>>>>>>>>>> Source=.\SQLEXPRESS;AttachDbFilename=|DataDirectory|\ASPNETDB.MDF;Integrated
    >>>>>>>>>>>>> Security=True;User Instance=True"
    >>>>>>>>>>>>> providerName="System.Data.SqlClient"/>
    >>>>>>>>>>>>>
    >>>>>>>>>>>>> Now, when starting the aspx page containing the
    >>>>>>>>>>>>> createuserwizard and filling all texboxes, again, nothing
    >>>>>>>>>>>>> happens (user is not created). If i try it within VWDev., the
    >>>>>>>>>>>>> user is then created.
    >>>>>>>>>>>>> What do i forget or do wrong?
    >>>>>>>>>>>>> Thanks
    >>>>>>>>>>>>>
    >>>>>>>>>>>>>
    >>>>>>>>>>>>>
    >>>>>>>>>>>>> "Juan T. Llibre" <> schreef in
    >>>>>>>>>>>>> bericht news:...
    >>>>>>>>>>>>>> Run aspnet_regsql.exe from a command window in your .Net
    >>>>>>>>>>>>>> Framework 2.0 directory.
    >>>>>>>>>>>>>>
    >>>>>>>>>>>>>>
    >>>>>>>>>>>>>>
    >>>>>>>>>>>>>>
    >>>>>>>>>>>>>> Juan T. Llibre, asp.net MVP
    >>>>>>>>>>>>>> asp.net faq : http://asp.net.do/faq/
    >>>>>>>>>>>>>> foros de asp.net, en español : http://asp.net.do/foros/
    >>>>>>>>>>>>>> ===================================
    >>>>>>>>>>>>>> "Mich" <> wrote in message
    >>>>>>>>>>>>>> news:Og6O%...
    >>>>>>>>>>>>>>> Hi,
    >>>>>>>>>>>>>>>
    >>>>>>>>>>>>>>> i'm building an web application for anonymous users. They
    >>>>>>>>>>>>>>> can take a look in the website, nothing more. In order to
    >>>>>>>>>>>>>>> perform other actions, the anonymous user must be logged. So
    >>>>>>>>>>>>>>> i create an aspx page with the CreateUserWizard control. The
    >>>>>>>>>>>>>>> user can fill his username, password etc ....
    >>>>>>>>>>>>>>>
    >>>>>>>>>>>>>>> My problem is: when an user fills everything and clicks on
    >>>>>>>>>>>>>>> button "create an account", nothing happens (no error, but
    >>>>>>>>>>>>>>> no user account created).
    >>>>>>>>>>>>>>> I thought asp.net would create in App_Data an ASPNET.MDF
    >>>>>>>>>>>>>>> file for storing user and membership information and add
    >>>>>>>>>>>>>>> automatically a new connection string in web.config. But it
    >>>>>>>>>>>>>>> doesn't happen.
    >>>>>>>>>>>>>>>
    >>>>>>>>>>>>>>> I know i can go in design mode (n VWD) and click on
    >>>>>>>>>>>>>>> "administer the site", but all the users are anonymous, so i
    >>>>>>>>>>>>>>> can't create user in advance.
    >>>>>>>>>>>>>>> Do i have to put some configuration code in web.config? Or
    >>>>>>>>>>>>>>> something else?
    >>>>>>>>>>>>>>>
    >>>>>>>>>>>>>>> Thanks for help
    >>>>>>>>>>>>>>> Mich

    >
    >
    Tony Girgenti, Apr 10, 2007
    #17
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. =?Utf-8?B?dGUgZ29vZHk=?=
    Replies:
    0
    Views:
    2,164
    =?Utf-8?B?dGUgZ29vZHk=?=
    Feb 8, 2006
  2. Mich
    Replies:
    16
    Views:
    1,456
    Tony Girgenti
    Apr 10, 2007
  3. Dave
    Replies:
    1
    Views:
    975
    Juan T. Llibre
    Jun 8, 2007
  4. Sunfire
    Replies:
    1
    Views:
    472
    Roland Dick
    Nov 10, 2007
  5. sravan_reddy001

    adding password for accessing ASPNET.MDF

    sravan_reddy001, Feb 3, 2008, in forum: ASP .Net
    Replies:
    1
    Views:
    375
    Norman Yuan
    Feb 3, 2008
Loading...

Share This Page