Psst! Did you know DevelopmentNow is a mobile web site design agency?

Contact us for help mobilizing your site, or to sign up for our beta Mobile Web SDK!


Archived Months
June 2003
July 2003
August 2003
September 2003
October 2003
November 2003
December 2003
January 2004
February 2004
March 2004
April 2004
May 2004
June 2004
July 2004
August 2004
September 2004
October 2004
November 2004
December 2004
January 2005
February 2005
March 2005
April 2005
May 2005
June 2005
July 2005
August 2005
September 2005
October 2005
November 2005
December 2005
January 2006
February 2006
March 2006
April 2006
May 2006
June 2006
July 2006
August 2006
September 2006
October 2006
November 2006
December 2006
January 2007
February 2007
March 2007
April 2007
May 2007
June 2007
July 2007
August 2007
September 2007
October 2007
November 2007
December 2007
January 2008
February 2008
March 2008
April 2008
August 2008
all groups > dotnet ado.net > april 2006

Filter by week: 1 2 3 4 5

VB Database Book Recommendation?
Posted by Tony K at 4/30/2006 6:31:27 PM
I'm looking for an Advanced Database Programming book strictly dealing with VB 2005. I'm looking for something specific such as: Customers > Orders > OrderDetails Being able to add an order with details for a new/existing customer. Any ideas? I've looked at some reviews on Amazon.com but ...more >>


Deleting a Row from Datatable and from Database
Posted by CMC at 4/30/2006 12:23:59 AM
Hi, I've a Datagridview binded with a Datatable. With this code: DataTable.rows.remove(current_datarow) DataAdapter.update(datatable) .... I manage to delete the row from the DataTable, it disapears from the DataGridView, but it doesn't delete it from he database (after updating the Data...more >>

Null in a Column when there is data
Posted by John Mark Howell at 4/29/2006 11:06:43 PM
I'm running .Net v1.1, C# against a SQL Server 2000 db. I've got a stored procedure that returns multiple columns. All but the first column are numeric(18,6). I have the standard SqlConnection/SqlCommand/SqlDataAdapter calls to retrieve the data and simply display in a DataGrid. The first ...more >>

Batch Update + Parent/Child + AutoIncrement/Identity = Yikes!
Posted by skavan at 4/29/2006 9:24:32 PM
Hi, I've seen about 2,345 messages on how to submit parent/child rows via ado.net. >From what I've gathered, the process goes: 1. Make Connection, Grab Tables/DataSet & Build CommandAdapters 2. Build relations 3. Make Changes 4. Post parent row with event handler (ms Access). 5. Grab new ...more >>

Missing post data in Internet Explorer (bug?)
Posted by Ian at 4/29/2006 7:03:44 PM
I had a really weird bug recently. I had a drop-down user control that would not fire the onselectedchange event server-side. After nearly twenty hours of debugging, I finally setup a local proxy (WebScarab, which rocks by the way) and noticed that IE was deciding not to POST the key/value pair ...more >>

Built-In JavaScript-Rendering Functions
Posted by Alex Maghen at 4/29/2006 2:15:01 PM
Hi. What's the most elegant way, in ASP.NET 2.0, to cause certain client-side things to happen without writing my own JavaScript? Here are some of the things I'd like to be able to do... * When I'm finished doing stuff in Page_Load(), I'd like the cause the page to scroll to a specific anch...more >>

Urgent:Newbie:Autoincrement violates foreign key con1straints
Posted by al at 4/29/2006 10:39:45 AM
Hi, I'm reading an xml file into a dataset and entering the data into an SQL server express database. I've got an employee table (empid as primary key) and an employee photo table (empid as foreign key) My xml file contains an employee element and multiple employee photo elements. I'm...more >>

VB 2005 & SQL
Posted by Tony K at 4/28/2006 10:34:56 PM
I am trying to write a VB.NET 2005 app using a similar setup of the infamous Northwind DB. I am using SQL 2005 Express on my laptop and will eventually upgrade to SQL 2005. My tables consists of: Customers Orders OrderDetails Category Products Suppliers My prob...more >>



How do I create a stand alone Dataset by ADO.NET?
Posted by Zoo at 4/28/2006 12:00:00 AM
Hi,All. I have the code written below which runs on VB6 and ADO. And I want migrate this onto VB.NET 2003 and ADO.NET. Could anybody give me a sample? Dim Rs As New ADODB.RecordSet With Rs $B!!!!(B.Fields.Append "ID", adLongVarChar, 10, adFldRowID $B!!!!(B.Fields.Append "Name", adChar...more >>

Populating typed datasets WITHOUT tableadapters
Posted by Chris Smedley at 4/27/2006 8:21:14 PM
Typed datasets are great, but in one respect, the move to use table adapters is a double edge sword. What I would like to be able to is to use the old fashion ds.tables() components to be able to iterate through each of the tables in the typed dataset and be able to fill them WITHOUT speci...more >>

How to open files automatically after download?
Posted by ad at 4/27/2006 7:56:45 PM
I used the codes below to send a Excel file form Web Server to client. The file is save to client's disk after download. How can I open the file automatically after saving it? ////////////////////////////////////////////////////////////////////////////////////////////////////////////// ...more >>

Adding collumn collation to a table in a data set
Posted by Fiddelm3742 at 4/27/2006 12:11:02 PM
So, here's my new issue. When I add data from my external datafile to my data table in my dataset I get an error on one of my columns because it thinks i have duplicate values (happens to be my PK of my table) in this specific column. Is it possible to add collation to a collumn in my data ...more >>

Changing from DropDown to DropDownList
Posted by Marty at 4/27/2006 11:27:19 AM
Why does my field not save when I change the control from DropDown to DropDownList? I used the data from wizard. Thanks. ...more >>

combobox binding problem
Posted by Fanor at 4/27/2006 10:34:38 AM
I have a combo box bound to a binding source wich is bound to a table. For some reason the selectedvalue of the combo box doesn't show the correctt value of the row the first time the form is showed. When I move to the next row using a binding navigator the combobox selectedvalue have the correct...more >>

Strongly Typed ConnectionString keeps disappearing
Posted by Aziz at 4/27/2006 8:53:32 AM
VB 2003, Access 2000 I have been using strongly typed Datasets/database connections, it works fine Now, I've added a OpenFileDialog functionality to my program so the user can select the database file. I've added & strCon & to this code (it's a Global variable): Me.conADOConnection....more >>

heirarchical recordsets
Posted by steven scaife at 4/27/2006 6:19:01 AM
I am converting my ASP sites to asp.net, one of the sites uses heirachical recordsets and i was wondering what the equivelant is in ado.net Also if there any sites with examples that i can study regards ...more >>

framed
Posted by barret bonden at 4/26/2006 9:43:26 PM
A client of mine has a young man who has written a web app (a CRM in dot.net 1.1) using many frames .it looks good , but is hard to maintain, passing, as it does, parameters from one frame to the next. These parameters allow the synchronization of datagirds, leading to my technically naive que...more >>

vb_2005_rowfilter_mit_den_10_letzten_datens=E4tzen
Posted by Georg at 4/26/2006 9:11:38 PM
hallo leute ich hoffe ihr k=F6nnt mir weiterhelfen. ich m=F6chte (muss) einen rowfilter bauen f=FCr die letzten 10 datens=E4tze meiner datenbank. wie kann ich das hinbekommen? gr=FC=DFe georg ...more >>

problem with no rows being returned - but rows are there
Posted by Marina Levit [MVP] at 4/26/2006 1:13:27 PM
Hi, It seems that this issue is occurring at several client sites, though never in house. At some point, some (all?) queries run by our software start returning no rows. But the rows are there in the database - and restarting IIS (this is a web product) seems to resolve the issue. Even ...more >>

Problems Using datasetObject.DefaultView for filtering and sorting.
Posted by Gary Rynearson at 4/26/2006 12:41:42 PM
I am using c# and VS2003 (.Net v1.1). I am trying to filter and / or sort a dataset and print out the results as shown below. I have seen several examples of using the DefaultView for the table, but the results were sent to a UI control's datasource property. Does anyone know how I can mak...more >>

ExecuteReader returns closed DataReader
Posted by PIEBALD at 4/26/2006 11:04:01 AM
Using .net 2 and Sql Server 2005, I am intermittently getting the exception: Invalid attempt to FieldCount when reader is closed. What I don't understand is how the DataReader could be closed when it was just created by ExecuteReader. As in: dr = cmd.ExecuteReader() ; Console.Write ( ...more >>

foreach behavior changed in Framework 2.0
Posted by Rich Wood at 4/26/2006 10:26:01 AM
I have the following code in a C# project: DataView dv = new DataView( dsModels.Tables[_INDVARS_TABLE_NAME], "", "", DataViewRowState.CurrentRows); foreach ( DataRowView drv in dv) drv.Row.Delete(); This code worked fine in VS 2003 (Framework 1.1). However in VS 2005 (Framework 2.0)...more >>

Conenctivity to Interbase Database
Posted by SSUK at 4/26/2006 4:10:02 AM
Greetings to all. How can we Perform database operations on INTERBASE using MS .NET 2005? We want to Insert few records on an existing INTERBASE Database using MS.NET ,how it’s possible ? Thanks for your support & time. ...more >>

Saving Changes To DataSet in memory (without updating Database)
Posted by Aziz at 4/26/2006 2:27:40 AM
Hello I have a system where a customer can order a metallic alloy product that is made from a variety of base metals. Every time the customer adds an alloy to their shopping list the system works out how much base metals are needed are deducts the relevant amount from the stocks table. I have...more >>

Transactions isn't rolled back, when using connecction pooling
Posted by Lars Berg at 4/26/2006 12:00:00 AM
I have a asp.net (1.1) Web Application. Connection pooling is on From that webapplication I execute this SQL with a commandtimeout of 10 seconds "BEGIN TRAN UPDATE XYZ set column1 = '3PU' where iid = 1234 WAITFOR DELAY '00:00:15 COMMIT TRAN" The SQL will timeout during the WAITFOR DELA...more >>

Getting Datarow from BindingSource
Posted by Andrew Oliner at 4/25/2006 6:08:36 PM
What's the best way to edit the Datarow which is referenced by BindingSource.Current? ...more >>

Addnew creating two records?
Posted by Andrew Oliner at 4/25/2006 6:05:42 PM
Hi, I have a SQL Server 2000 database with an Identity Column called IssueNum which auto-increments each time a new record is created. I'm using the ADO.net 2.0 tools, a BindingSource and a BindingNavigator. When I click on the AddNew button on the Binding Navigator, it adds two records ...more >>

Create empty datatable from SQL Server table?
Posted by David Tilman at 4/25/2006 3:54:02 PM
I'm using C# in Visual Studio 2003 and would like to create an empty datatable in my dataset based on a SQL Server table. I basically want to use the metadata of the SQL Server table without loading any data into my datatable. What is the best approach to do this?...more >>

CommandBehavior.SingleRow
Posted by Justin at 4/25/2006 2:07:40 PM
As far as performance is concerned, is it more efficient to set SqlCommand.ExecuteReader(CommandBehavior.SingleRow) when you are only dealing with single row? Thanks ...more >>

Compare Datarows
Posted by Toco at 4/25/2006 11:37:03 AM
Hello. I have in dataset, two datatables. Each table has only two columns. What I wish to do is to compare 1st table to see if the datarow can be found in 2nd table. For example, lets say we are comparing student last name and student ID, using both tables. Process is to retrieve the last...more >>

DbCommand against Oracle fails with string parameters
Posted by doug.setzer NO[at]SPAM gmail.com at 4/25/2006 10:47:58 AM
I have this code: Dim cmd As DbCommand = Me.Factory.CreateCommand() '** this is a valid OracleFactory object Dim param As DbParameter = Nothing Dim sql As String = "" sql = "SELECT ard.*" & Environment.NewLine & _ "FROM MyTable ard" & Environment.NewLine & _ "WHERE ard.Client_Nbr = :Clien...more >>

ADO.NET and Excel
Posted by rguarnieri at 4/25/2006 10:33:51 AM
Hi!!, I need to populate an excel sheet with a query, some people says that I can use CopyFromRecordset to do that but I need to add a reference to an ADODB.Recordset, my question is, le ADODB library is included in framework 2.0?, Do I have to make an extra instalation of this library for the e...more >>

How to find out the "GUID" of installed assembly?
Posted by Alvaro E. Gonzalez at 4/25/2006 9:23:18 AM
Hi; How to find out the "GUID" of installed assembly? Tks. Alvaro ...more >>

ContextSwitchDeadlock
Posted by OldButStillLearning at 4/25/2006 9:21:01 AM
Hello, I am getting this "ContextSwitchDeadlock" error message pop up in situations where I am doing a Data Reader loop, where I am processing about 40,000 records. For each record read via the data reader, I am creating another data reader to read another database table (can't join these tab...more >>

Converting between RowViews & Rows
Posted by Ant at 4/25/2006 7:45:01 AM
Hi, I'd like to use a typed row to iterate through a DatarowView array. I've used a view for its FindRows method. How (or where) can I cast this so that the rows & rowViews will work together. I've tried converting them in various places without success: Thanks for any ideas. I can use an...more >>

Two DropDownList controls inside one DataGrid cell
Posted by glenn at 4/25/2006 4:22:02 AM
Hi folks, I have two code test samples that I am trying out. I want to have two dropdownlist controls. The first ddl is databound with a list of company names. The second ddl is databound with a list of contact names that reside within the company that has been selected in the first ddl....more >>

Access File Lock
Posted by Geoff Murley at 4/25/2006 4:01:02 AM
I am trying to run a simple VB.NET application using an Access 2000 database as the OLEDB datasource directly from a CD. I have set the Locking mode = read. When I autorun the application from the CD I get the error message "Could not Lock File". When I run the same files from a folder on m...more >>

Displaying data from 2 tables in one datagridview
Posted by Lars E. at 4/25/2006 1:53:33 AM
Hi all. i am trying to display contents from 2 tables in one datagridview. It is not possible for me to do a join, so i have to combine 2 datatables to be able to show data from both tables. My tables are: "Customer" and "Customer Contact". The relation is: Customer.c-Customerno = Custo...more >>

Dataset converting date field accross time zones...
Posted by Subrata at 4/25/2006 12:00:00 AM
I need help wrt to the dataset converting the date (time) when passed from a web server to a client, both on different time zones. Lets assume that the Web Server is in NYC(EST). The client is in SFO(PST). The client is making a web service call to the WS in NYC, which returns a dataset conta...more >>

odbc & stream & excel file
Posted by rob at 4/24/2006 11:56:47 AM
I have to read a csv file. In order to avoid all the hassle with the parsing (some items are in quotes, others are not, some have quotes/comas in the items themselves, etc) I simply use odbc. The code is shown bellow. The problem is that the source is actually a string (a csv file downloaded fro...more >>

table versioning
Posted by Zen at 4/24/2006 11:07:19 AM
Hi, Since I don't know which group would be a right newsgroup to post for this problem and most likely that it would be involved with expertise coming from residents of different newsgroups, hope multiple-group posting is ok. Solving this problem means a lot to me and my team. Thank you v...more >>

Converting XMLDatadocument for dataset
Posted by srinivas at 4/24/2006 11:03:02 AM
Hi, I have to pass XML data to a procedure. I'm having xml data in XMLDataDocument datatype. Now i want to use this XMLDataDocument as an input to the dataset inside the procedure. But dataset.ReadXML accpets only Textreader/Stream/XMLReader. Can anyone pls tell me how to convert the XMLDataD...more >>

Copy a DataTable
Posted by roger.cantillo NO[at]SPAM gmail.com at 4/24/2006 8:19:15 AM
Hi, I'm running code that creates a new datatable based on filtered datatable. My code uses the Select method to filter the data and loops throw each row to copy its contents to the new datatable. My question is, is there a better/faster method of performing this task, rather than looping t...more >>

.NET Provider for DB2 8.2.1
Posted by Rusty at 4/24/2006 7:30:12 AM
Hi, I need to access a DB2 8.2.1 server on AIX64. Normally we access SQL Server, but I'd like to go directly to the DB2 server with a web service if possible. 1) is there an IBM .net data provider? if yes, is this the way to go? 2) does the data provider require me to use a license file or a...more >>

Listbox / Combobox with multiple fields as displaymember
Posted by Sergio Torres at 4/24/2006 6:14:01 AM
I need to populate a combobox and/or a listbox with several fields as displaymember. Both controls allow only one field as displaymember. I need the display member to look like this (the columns should be left aligned), where each columns represents a field in the underlying datatable: 001...more >>

Get SQL statement in a catch(SqlException)
Posted by martijndemunnik NO[at]SPAM gmail.com at 4/24/2006 4:42:09 AM
I'm debugging an application using log4net. When a SQL statement fails it is logged. One of the messages is Line 1: Incorrect syntax near ')'. but I'm not sure which SQL command is executed. Can I get the complete SQL command send to the database server from an SqlException? ...more >>

add row in binded datagridview
Posted by Clamara at 4/24/2006 3:56:01 AM
Hi, help me please for this issue: I have a master-details form binded to "Order" and "OrderDetails" A datagriedview is binded with the details. I want to fill the datagridview with a result of a query with fields that respect the orderdetails fields. I try to fill an array with the re...more >>

Updating Row value when PK is known
Posted by Aziz at 4/24/2006 2:21:18 AM
I am using VB.NET 2003 I have a simple Dataset DataTable (call it StockLevels) such as this: BaseMetalCode (PK) BaseMetalInStock Ag 1000 Zn 700 Si 1300 Cu ...more >>

Evaluating a condition in a string
Posted by Satya at 4/24/2006 12:27:01 AM
Hi All, I have a scenario as below. I have a data row like AcctNum CheckNum Amt Payee Date 9999999 125699 10370.25 ABCD...XYZ 04/24/06 Now I have to process this row basing on a condition. if (<Condition>) //Process The row else continue; The complexity here is, <Condition> ...more >>

Catching exception of System.Data.OleDb.OleDbException type
Posted by Nits at 4/23/2006 9:32:57 PM
Hello All, I wanted to know what kind of exceptions will be catched in the class type of System.Data.OleDb.OleDbException I was expecting the database constraints violations errors will fall into this type of exception handling, but it doesnt seem so. And if it cannot catch these exceptio...more >>


DevelopmentNow Blog