.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Register
 
Win Surprise Gifts!!!
Congratulations!!!


Top 5 Contributors of the Month
MarieAdela
Imran Ghani
Post New Web Links

Create user is creating aspxxxx.mdf database in my app_data folder

Posted By:      Posted Date: August 25, 2010    Points: 0   Category :ASP.Net
 

I had already setup roles for my pages and requirements call for ability to manage and create users.

So i was looking at code that allows you to do so using membership, even though i got the page to work, it was creating a database in my app_data folder.. i already have SQLExpress setup with the asp schema, but cant figure out how to get my application to use that instead of creating the db in the folder?

What am i missing or doing wrong?

I have the following setup in my web.config file..

		<authentication mode="Windows"/>
		<authorization>
			<deny users="?"/>
		</authorization>
    <membership>
      <providers>
        <add name="SqlMembershipProvider" type="System.Web.Security.SqlMembershipProvider, System.Web, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"
        connectionStringName="connectn"
        enablePasswordRetrieval="false"
        enablePasswordReset="true"
        requiresQuestionAndAnswer="true"
        applicationName="MyApplication"
        requiresUniqueEmail="false"
        passwordFormat="Hashed"
        maxInvalidPasswordAttempts="5"
        minRequiredPasswordLength="7"
        minRequiredNo


View Complete Post


More Related Resource Links

Create new database as a user instance

  
Hello...Is there any way to create a new database directly as a user instance. I guess this means creating a new mdf/ldf pair which is detached from the server after its created.Thank you...

Create report that lists every user with permissions for each folder

  
I would like to have a report that will list each user with it's roles for every folder. We have a very large RS database with a lot of folders, we need some better way to keep track of permissions. I created a report that utilizes "GetPolicies" from http://localhost/reportserver/ReportService2005.asmx but I have to feed a folder name to get list of users. I can also (by using subreport) list all folders with users. However, I am not able to produce a report where I have it broken by user. any idea?

Restricting user permission to upload doc but not create new folder

  

Hi all,

was wondering if it's possible to allow a user to upload documents but not be able to create a new folder...

Any help is greatly appreciated.

thanks


Create App_Data Folder Grayed Out?

  

I have a few questions regarding the "special" ASP.NET folders in Visual Studio web projects.

  1. Adding an App_Data folder in Visual Studio is present, but grayed out in my C# web project, why?
  2. What are the meanings of the various ASP.NET "special" folders?
    • App_GlobalResources
    • App_LocalResources
    • App_Data
    • App_Browsers
    • Themes - I know this is used to contain stylesheets for a particular theme and is then specified in the web.config or page (if I remember right).
    • App_Code - Were these classes that were pre-compiled?
  3. Do these ASP.NET folders retain their special meaning if you manually create a folder with the same name instead using the "Add ASP.NET Folder" feature in Visual Studio?

Error to Add a Database to a Visual Studio 2010 Project via the App_Data Folder

  

I am trying to add a new database via the App_Data Folder and I receive an error described below.

When I attempt to add ANY TYPE OF SQL SERVER DATABASE through the App_Data folder I receive this error "Connections to SQL Server Files (*.mdf) require SQL Server Express 2008 to function properly.  Please verify the installation of the component or download from the URl."

I can create a db via SQL Server Mgmt Studio, it connects fine, and I can see tables.

Visual Studio- Server Explorer connects fine to the Database, I can see the tables.

Im running XP SP3 w/ Visual Studio 2010 and SQL Server 2008 R2 Developer.  I had previously removed SQL Server Express.

Why cant I access the database within my project, when Im able to connect to this fine within Visual Studio Server Explorer?


Error to Add a Database to a Visual Studio 2010 Project via the App_Data Folder

  

I am trying to add a new database via the App_Data Folder and I receive an error described below.

When I attempt to add ANY TYPE OF SQL SERVER DATABASE through the App_Data folder I receive this error "Connections to SQL Server Files (*.mdf) require SQL Server Express 2008 to function properly.  Please verify the installation of the component or download from the URl."

I can create a db via SQL Server Mgmt Studio, it connects fine, and I can see tables.

Visual Studio- Server Explorer connects fine to the Database, I can see the tables.

Im running XP SP3 w/ Visual Studio 2010 and SQL Server 2008 R2 Developer.  I had previously removed SQL Server Express.

Why cant I access the database within my project, when Im able to connect to this fine within Visual Studio Server Explorer?


How to place a MYSQL database in my ASP.NET site App_Data folder?

  

Hi!

How to place a MYSQL database in my ASP.NET site?

In what format I produces the file to my APP_DATA
database folder to place it.
How to build CONNECTION STRING to  database located in APP_DATA
I created a site  conncted with a LOCALHOST database.
Now I want to import it into my website folder APP_DATA
Please help.


how to create dropdownlist user control(acsx) and fill from database

  


how to create dropdownlist user control(acsx) and fill from database


Database create error due to folder access right

  

I have SQL Server  and had that  problem Below .

When i try to create database having different folder it is not working

This directory works:
C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data

Anything else like

C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\OtherFolder

generated  error.

 

CREATE FILE encountered operating system error 5(Access is denied.) while attempting to open or create the physical file

CREATE DATABASE failed. Some file names listed could not be created. Check related errors.

 

Any body has idea how to resolve this.


Unable to create database in particualr folder

  
Hi,

When i am trying to create a database in Sql Server in my PC, i am not allowed to create database in a particular folder. It gives an error saying that,

Msg 1802, Level 16, State 4, Line 1

CREATE DATABASE failed. Some file names listed could not be created. Check related errors.

Msg 5123, Level 16, State 1, Line 1

CREATE FILE encountered operating system error 5(Access is denied.) while attempting to open or create the physical file 'C:\Program Files\Test\Database\CheckCreation.mdf'.

I am having the administrator access in that PC but still not allowed.


I am able to create it in all other folders.

Can anyone help me in this issue?

Thanks & Regards,
Subalakshmi Vijayarajan.


I need help with adding membership tables to app_data folder database

  

The following code is used to add the asp membership tables to an already existing database instead of creating a seperate database for membership and having two databases in the application.

aspnet_regsql.exe -S .SQLEXPRESS -U username -P password -d databsename -A all

It works fine by adding the membership tables to the existing database that is located in the c drive, program files  sqlserver folder.

But my database however is not in the c drive but located in my asp website app_data folder, so the above code does not give any error and the tables are not added after I run it.

Please how can I now add the membership tables using the above code when my database is located in the website app_data folder, thanks



need to get value of Port ,Database Name and Database Server while creating "Create New Web Applica

  

hi..

1> i need to get the value of PORT ,Database Name  and Database Server while creating "Create    New Web Application" using Central Admin under "Application Management "  on "OK" button.

2> how to get these value on OK button click, i need to retrive these value and wirte it into text file.

3> Any other idea to get these filed value ?

 

thanks in advance

 

 


User Profile Synchronization - Creating AD Connection "Unable to process Create message"

  

Hi,

I have the following error when I try to create a new synchronization connection:  "Unable to process Create message".  Microsoft reports this error as being due to a SUN LDAP error which does not make sense.  While we do have some SUN machines in our environment, I used an LDAP browser to confirm that the Windows AD LDAP  was returning information fine.  We are using a mixed Windows 2008 R2/Windows 2003 domain.

I've searched the internet for the solution and have tried all suggestions.  Have tried recreating the User Profile Service.  Have tried not using the wizard and set everything up manually according to the "Rational User Profile" blog.  Have done as much as I can think of.

Any help would be awesome and very appreciated.

The recurring errors in the Event Log are 3 errors:

FIMSynchronizationService Event 6303

Forefront Identity Manager Event 3 (occurs twice)

 

 

 

 

Here are the verbage for each error

FIMSynchronizationService Event 6303

-------------------------------------------------------

The server encountered an unexpected error while performing an operation for the client.
 
 "BAIL: MMS(4228): parser.cpp(3182): 0x80230910 (E_MMS_SCHEMA_CYCLE_IN_CLASS_HIERA

How to get user to create a folder from a Windows service

  

Good afternoon everyone,

The question is very simple. I created a Windows service with c # 

MS SQL Server: Disconnect Users From Database - Kill User Session

  
If you ever wanted to restore your database from a SQL backup file (.bak), but there are still users connected to your database, the backup operation will fail causing the error: Exclusive access could not be obtained because the database is in use.

Creating Sites/Lists/List Items under Current User Context in SharePoint By Using SPUserToken

  
Usually we do this by performing the action under RunWithElevatedPrivileges method and updating the listitem using SPListItem.SystemUpdate() method (see here). but this approach has its own flaws like (RunWithElevatedPrivileges will run under system account, we cannot use SystemUpdate for SPSite,SPWeb,SPList, since it runs under system we will "CreatedBy" by as SystemAccount).

Connestion string create any database server

  
This links important to how to create connection string to any data base sever.
Categories: 
ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend