Click to See Complete Forum and Search --> : ASP.NET Tutorial
Memnoch1207
Dec 29th, 2004, 12:26 PM
I have created an ASP.NET tutorial. This tutorial is was designed in VS.NET 2003 using a SQL Server 2000 backend.
The tutorial contains the following.
1) A simple DML (Data Manipulation Layer) class containing common database functionality.
2) Examples of the following...
a) Datagrid Paging
b) Displaying images in a datagrid
c) Inserting/Updating/Deleting database records through stored procedure calls.
I have scripted out the database, so you can run the sql script in query analyzer and create all of the required database objects (tables, stored procedures, etc...).
I have also included a states.xls spreadsheet that can be imported into the "States" table (using DTS) once the database and all objects have been created.
If you have any questions let me know.
TSAR
Jan 31st, 2005, 09:46 AM
Seems intresting, but I cann't do anything except surfing (add/edit doesn't work even if I don't receive any message) :-(
Any idea ?
Memnoch1207
Jan 31st, 2005, 10:14 AM
What are you talking about?
TSAR
Jan 31st, 2005, 10:26 AM
Hmm, will give you an example.
When I start the application i receive the main screen, where i push "Departments". I receive a new screen whith one department (name 1). I try to add one, so i push "Add New Department". He asks me a name, i give in "2" and push on submit.
I receive the earlier screen of the departments, but only the "1" is on the screen. Same problem for positions and employees.
Memnoch1207
Jan 31st, 2005, 11:13 AM
Look in the database to see if the name is being inserted into the table.
TSAR
Jan 31st, 2005, 12:14 PM
Sorry, no.
TSAR
Jan 31st, 2005, 02:54 PM
I debugged it and in the function Query i get an exception : "Cannot insert the value NULL into column 'InActive', table 'VBFORUMS.dbo.Department'; column does not allow nulls. INSERT fails.
The statement has been terminated."
I modified this field so it would accept null value, but then i get this error :
"Cannot insert the value NULL into column 'DepartmentID', table 'VBFORUMS.dbo.Department'; column does not allow nulls. INSERT fails.
The statement has been terminated."
Do you see the problem ?
Memnoch1207
Feb 1st, 2005, 01:05 PM
Set the default value of the InActive field to 0.
TSAR
Feb 1st, 2005, 02:02 PM
Still ""Cannot insert the value NULL into column 'DepartmentID', table 'VBFORUMS.dbo.Department'; column does not allow nulls. INSERT fails.
The statement has been terminated.""
Memnoch1207
Feb 2nd, 2005, 09:36 AM
DepartmentID
Data Type: UniqueIdentifier
Default Value: (newid())
IsRowGUID: Yes
This should be the default of all of the Primary key fields in all three tables.
The default value for all varchar fields should be set to ('')
The default value for all int fields should be set to (0)
TSAR
Feb 3rd, 2005, 10:59 AM
Works fine, thanks !
anasalama
Apr 19th, 2005, 11:47 AM
The problem still happens with the employee entry form.!
when i fill the form and submit it nothing is saved in the table.
i put the initial values of the table fileds as you said but i still face the problem !!
?
Anddmx
Jun 7th, 2005, 01:37 AM
HI
I have question about the tutorial I made database named project from query on the .sql file and it created the table and everthing fine.
When I access the webpages file in IE but when i Click on Department it takes forever then errors out. He is the error
Error: SQL Server does not exist or access denied.
at System.Data.SqlClient.ConnectionPool.GetConnection(Boolean& isInTransaction) at System.Data.SqlClient.SqlConnectionPoolManager.GetPooledConnection(SqlConnectionString options, Boolean& isInTransaction) at System.Data.SqlClient.SqlConnection.Open() at System.Data.Common.DbDataAdapter.QuietOpen(IDbConnection connection, ConnectionState& originalState) at System.Data.Common.DbDataAdapter.FillFromCommand(Object data, Int32 startRecord, Int32 maxRecords, String srcTable, IDbCommand command, CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataTable dataTable, IDbCommand command, CommandBehavior behavior) at System.Data.Common.DbDataAdapter.Fill(DataTable dataTable) at ASPNETTesting.DataManipulationLayer.Query(String strProcedureName) in C:\Inetpub\wwwroot\www01\ASPNETTesting\clsDML.vb:line 29
I check the permissions on the database and the user I add to it was on there with admin rights. looked at the clsDML.vb and seen this line where it connects to the Sql server.
Public strConnectionString As String = "Server=(local);Database=Project;User ID=steve;Password=jensen;"
So I changed it to this to try and tried to connect the sql server but it didnt work.
Public strConnectionString As String = "Server=(local);Database=Project;User ID=admin;Password=xdmzx3065;"
thanks for the great tutorial so I am no expert but just trying to learn about asp.net with Sql server
Anddmx
Memnoch1207
Jun 7th, 2005, 07:12 PM
Make sure "Admin" is a valid user on the Project database, if not create it.
jignesh_1508
Aug 1st, 2007, 03:34 AM
i want to create a new website on which user can serch for job in short job serching web site .for this website i can't get idea what will be the different tables,database etc.. is anyone help me!!!
jignesh_1508
Aug 6th, 2007, 09:19 AM
how can i create dynamic header and footer for website ?? in asp.net??
angelica
Oct 28th, 2008, 05:06 AM
Hi I have downloaded ASP.net testing tutorial and built the conversion alothough it says that .vbproj was not converted successfully.
When I try to run the I get .
an error message saying :
Cannot open the file
How do I proceed from there please?
I am using VS 2005 . Thanks
HowTo
Jan 17th, 2010, 11:09 AM
i am also having the same problem..
is the start up page properly defined?
or need to set it up???
please help
gep13
Jan 19th, 2010, 05:19 AM
Hey,
With all respect, this tutorial is targeted at an older version of SQL Server and Visual Studio. Unless you are specifically using these versions, I would suggest you look elsewhere for samples, there are plenty available.
Gary
vbforums.com
Copyright Internet.com Inc., All Rights Reserved.