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

Top 5 Contributors of the Month
david stephan
Gaurav Pal
Post New Web Links

Create Table using Enterprise Library

Posted By:      Posted Date: April 10, 2011    Points: 0   Category :ASP.Net


I have a method through which i am creating a Table in DB as shown below,


View Complete Post

More Related Resource Links

unable to create new table in sql server 2000 enterprise manager on windows7(Operating system)

i have successfuly installed sql server 2000 on windows7 and i am able to browse all the tables and edit aswell(on enterprise manager) but i have a problem while creating new tables it says ' MMC has detected an error in a snap-in' and provides options to either continue with the error or send a report to microsoft ,   Please help regarding this compatibility issue   Thanks in advance !

Create new sql table at runtime VB.Net


I want to create a new table to sql database at runtime.  The column names would be "Name", "Date", "Event".  I would also like to have one more column name "Image" but the problem is that since the amount of images will vary, I want the application to count the amount of files in the Multiple fileuploader and then add a image column to the table for the respected amount of files. 

For example if i am uploading 3 files in the multiple fileuploader, the names should be "Name", "Date", "Event", "Image1", "image2", Image3"

I also would like that table name to be name dynamically from the textbox Name when the user enters the information.

I have the following code to make a new table, but I dont know how to name the fields at runtime like previously asked please help!!!

Dim objConn As New SqlConnection("Server=<servername>;uid=<userid>;pwd=<password>;database=master")


Create/add table from code to database



I create table:

                  DataSet data=new DataSet();

                  DataTable myTable = new DataTable("NewTable");

                   DataColumn[] keys = new DataColumn[1];

                   // create column
                   keys[0] = new DataColumn();
                   keys[0].DataType = System.Type.GetType("System.String");
                   keys[0].ColumnName = "PointID";
                   myTable.Columns.Add(keys[0]);    &nb

MVC + Enterprise Library


Not a MVC specific question, but as that's what I'm doing I thought I'll post here.

While looking into the source code of an existing application, I stumbled upon MS Enterprise Library, and as I only heard about these "application block" stuff decided to look into it.

From the theory it sounds like a pretty usefull thing and it made me wonder if other's are using it succesfully along with MVC projects (I know they are not really related!)?

Pro's and Con's? 

I like the database block, as I did not get to any real database development the last 1.5 years, for instance. (Bad excuse I know).  Having an IoC thrown in there (Unity) sounds like I can pretty much stop using 3rd party libraries like I do now all over the place.

Using the ConsoleTraceListener with the Enterprise Library 3.1 Logging Block


I'm new to using the Logging application block.  I think I have a pretty good handle on how things work.  However, I'm running into a problem.  I'm using the RollingFlatFileListener and I have formatted the logging template to be more like the logging we are replacing.  However, in our console apps when the ConsoleTraceListener is added it still logs it out in the default text template format.  Is there any way to get around this?  Currently it looks like I will have to create a new TraceListener called FormattedConsoleListener that allows a text formatter to be associated with it.  Is this the only way?

Data Truncation issue with Enterprise Library Logging WriteLog stored Proc


Hi ,

I'm using Enterprise Library Logging  feature for logging. The issue i am facing is when the Logging message is too large(more than 65534 chars) ,complete data  is not logged in the Formatted Mesage column which is  of data Type nText .

I am able insert complete data if i try inserting from Sql insert Query from sql management studio. Do i need to add any attributes to data base listener or do i need to change the sp.

 Is there any way to increase the WriteLog stored proc param size in EnterpriseLibrary.Logging config file ? . Please let me know.


Thanks In Advance.

Using Enterprise Library for first time



I wan to use the enterprise library for the first time. Is there any samples, quick start guide or ebook is available for a quick start and learn the basics.

I have vs2008, so which version of EL should I use?

And if somebody can just brief about Enterprise Library. Because as per my understanding, is this a mixture of design patterns and some pre-made blocks of source code.





Enterprise Library: Take Exception To Critical Errors With Custom Application Blocks


Enterprise Library is a collection of application functionality blocks that you can re-use in your application for common functionality you'd otherwise have to write again and again. Here Jay Hilyard explains how to use them.

Jay Hilyard

MSDN Magazine September 2006

Data Points: The Enterprise Library Data Access Application Block, Part 3


E nterprise applications can have a wide variety of data update requirements. Sometimes you need to save multiple rows of changes at once within a single transaction. Other times, the user must be allowed to enter multiple rows of data, send them to the database in a batch; and if a row or two fails, only the rows that succeeded should be committed and remain committed.

John Papa

MSDN Magazine October 2005

Data Points: The Enterprise Library Data Access Application Block, Part 2


Last month I explored the foundation of the Enterprise Library Data Access Application Block (DAAB) including how it all fits into an architecture (see Data Points: The Enterprise Library Data Access Application Block, Part 1).

John Papa

MSDN Magazine August 2005

Data Points: The Enterprise Library Data Access Application Block, Part 1


A solid data access later (DAL) can benefit an application by hiding redundant tasks, helping handle exceptions more gracefully, helping clean up resources more efficiently, and providing a layer of abstraction from the database.

John Papa

MSDN Magazine July 2005

Create table in the database using management studio


 I have database already on the server. However, when I created new table, the new created table Schema is not dbo. it is my user name. How to solve this?

It shows the new created table Schema is my username but not dbo.

Even though I rename it, it couldn't change. I can see this in table property.



generate create script of table using c# and SQL server 7.0, can anyone help me?


I want to generate create table script using c#.net, I want to connect sql server 7.0 and generate table create script. Its urgent kindly help me urgently.

How to create scrolling table for columns in a SharePoint Designer Data View


I have a fairly complex SharePoint Designer 2007 Data View they have added two more requirements.

1. Have the columns on the right side be able to scroll left to right as there is a large number of columns, while the first 3 columns on the left side stay locked in place.  This is only one list not two, and because of some other requirements I have it must remain to be just one list.

2. Then they also need to have scrolling up and down of the entire list with the headers locked in place.

The first requirement is more important than the second, but preferrably I need to do both.

I am new to XSL so not familar with the syntax. Is this something I can do on a custom Data View? Does anyone have any examples of how?

I have a drawing that show how it needs to look but I don't see an option here to upload a graphic.

So here is a link to my graphic example uploaded to my blog area: http://lindachapman.blogspot.com/  or just the image here: http://4.bp.blogspot.com/_aB01ue__NvQ/TGL42MOvrGI/AAAAAAAAAA4/c3xP4uCy4BU/s1600/Scrolling.png

I failed to mention that 3/4 of the columns are HTML Calculated fields wh

Can't perform Create, Update or Delete operations on 'Table(outbox)' because it has no primary ke



I'm a beginner in asp.net and I have some problem inserting data into sql server 2005 with linq.


my code is : 


        Dim Result As New SMS.SendResult
        If Result.status = 0 Then
            Label1.Text = "Your Message Sent Successfuly"
            Dim db As New IGSSDataContext
            Dim out As New outbox With {.ClientID = intRandomNumber, .From = User.Identity.Name, .TO = TextBox1.TabIndex, _
            .Time = Now, .Message = Message}
            out.ID = (ID)
            TextBox1.Text = ""

Using SQL Server 2008 R2 client with Enterprise Library



I am modifying an existing application that uses SQL Server 2008 as the database and Enterprise Library 4.1 for Data Access .

What I need to do is to make it use the SQL Server 2008 R2 client to take advantage of out of the box failover capabilities.

Any idea how I can accomplish this?


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