2,634 Topics
![]() | |
Most databases have multiple users. For these databases it is a good idea to auto-increment the identity column. I understand that an SQL identity column is not incremented until the newly-created record is inserted. I guess this means the identity column is incremented when you actually reconnect to the database … | |
Ok, I have a homework problem that I'm needing some help with. The program has to Allow the user to specify the number of integers to be inputted into the array read a data set of number of integers into the array Determine the sum find the largest integer and … | |
Hi guys I have a problem in my project.Below I mention the coding I wrote it for testing purpose. In below coding the second while loop never run,only [CODE] SqlDataReader reader = DbCon.Get_Invoices(); int x = 0; while (reader.Read()) { x++; [B][COLOR="Red"] 1[/COLOR][/B] } MessageBox.Show(x.ToString()); chart2.DataBindCrossTable(reader, "ExecutiveCode", "Date1", "Total", ""); … | |
Hi, I am creating a data access layer through Visual Studio 2005 (dataset in appcode folder) for my asp.net (vb.net based) application connected with SQL server 2005 db. I have already created easy tableadapters for brands, categories tables. Right now I am creating Product tableadapter for product table. The product … | |
HI, Im using the components as below 1. msaccess db 2. vb 2008 3. dataset 4.bindingsource 5.tableadapter. the forl has one combobox one text box and one command button when i click the button the insert command will work and update the dataset with the data in the textbox, which … | |
This problem is causing me a massive headache! I'm sure I can't be the first person to do this but I have searched the internet high and low for answers about this. I want to be able to display in a list as seperate fields: - A product name - … | |
[COLOR="Red"]StreamWriter sw = new StreamWriter("D:\\sss.txt"); DataTable dt = new DataTable(); DataColumn dc = new DataColumn("ID", typeof(string)); dc.AllowDBNull = false; dc.Unique = true; dt.Columns.Add(dc); dt.Columns.Add("FirstName", typeof(string)); dt.Columns.Add("LastName", typeof(string)); dt.Rows.Add(1, "aaa", "bbb"); dt.Rows.Add(2, "ccc", "dddd"); int length = dt.Columns.Count; int length1 = dt.Rows.Count; for (int i = 0; i < length; i++) … | |
Hello all, I have a datagridview, and I have 2 columns, a comboboxcolumn and a textboxcolumn,Now I want to bind this columns to my Dataset. how do I do this??? | |
I can read in an SQL table ("Person.Contact") from AdventureWorks and step through it one row at a time, but when I try to save a record, either one I'm inserting or one I'm editting, I get the following exception: Incorrect syntax near ','. Must declare scalar variable "@ContactID". Here's … | |
I have an application that accepts around 20 fields of data (string/int) from the user. Then allows the user to edit a dataset in a datagrid, and sort this dataset to display the updated dataset. I now need to take the fields of user input (textboxes) and the applicable dataset … | |
OleDbConnection thisConnection = new OleDbConnection( @"Provider = Microsoft.Jet.OLEDB.4.0;Data Source=e:\DataMoney.mdb"); OleDbDataAdapter thisAdapter = new OleDbDataAdapter( "SELECT * FROM SchoolMoney", thisConnection); DataSet thisDataSet = new DataSet(); thisAdapter.Fill(thisDataSet, "SchoolMoney"); OleDbCommandBuilder thisBuilder = new OleDbCommandBuilder(thisAdapter); thisBuilder.QuotePrefix = "["; thisBuilder.QuoteSuffix = "]"; //set up keys object for defining primary key DataColumn[] keys = new DataColumn[1]; … | |
Hi guys, I am struggling to discover what the right syntax for my code would be. I use VWebDeveloper Express 2005 and I have a web form .On the Web form I have three dropdowns that are bound through datasets and a textbox.Dropdowns are linked to display only the info … | |
I am trying to make an application that sorts a database with user input and returns a form. This form then accepts some user input, and then needs to be sorted in another event. I am using ado.net, and am attempting to complete this task by cloning a dataset and … | |
Another XML question. I am ably to load a XML file (via a filepath) to a datatable. See code below. However, I'd like to be able to load a in-memory XML document to a datatable. Can anyone help me out? [code] Public Function XmlToDataTable(ByRef filePath As String) As DataTable Dim … | |
I’m trying to learn how to connect to an SQL Server database (I’m using the AdventureWorks sample database), but I’m having problems. Here’s the code I’m using: [code] // define connection string for database server string connectionString = "server=<server name>; database=AdventureWorks; uid=<user name>; pwd=;"; // no password // define SqlConnection … | |
Looking for some help! I have loaded XML doc into a dataset (see below). That went ok. So now I can put the DS in a grid and change it. However, after changing the DS I want to export it back to a XML doc. That only succeeds partially. I … | |
Ive got an RSS parser using the DOM. Its got a loop to display each item. I want to have a hidden field on each item then post this to another page. Im having trouble counting each item in the loop. Help please :) This is what ive got: [code=php]<?php … | |
Sir, I am using front end as a VB.net 2005 and I am a beginner in this language. I am creating Desktop application and using controls TAB controls 1st tab control is Contact in contact I am using one text box, two button and one datagrid while I am using … | |
I am trying to import data from an excel file. I get this right and display it in a datagrid view easily. My problem comes in when it comes to the fact that the gallons column should only contain double values above 0 and below 1000; However the excel file … | |
do you know how it is useful to use dataset.begininit method? Thanks | |
I am developing a windows based application in vb.net 2005 and data base is SQL2000 I have database named new base and table name is Trick and fields are ItId, ItName, ItPrice, ItQuantity, itstock Problem is that I want to populate data gridview through search data from text box but … | |
Hello, I have a form where I have to say two dropdown lists. Firts dropdown list is populated based on query from a table in access database. I have another dropdown list .I woud like in that second dropdown to show only values that are relevant to the selection in … | |
I created a dataset in the Dataset Designer by draging a database table into it, then I added a new select SQL query to the DataTable. Check the pics I think it helps explain it better. [URL="http://i43.tinypic.com/2qs7707.jpg""]http://i43.tinypic.com/2qs7707.jpg"[/URL] Now the problem comes when I try to use an ObjectDataSource, it sees … | |
I am creating a website using ASP.net with C# 2005 as the language. In my ASP.net page, I have displayed a GridView. I have dynamically populated the GridView during runtime using Dataset and SQLDataAdapter. Since the GridView displays ALL columns at a fixed width, it does not look pretty to … | |
Hi There I get the following error when clicking on btn This code works perfectly on some machines but does not work on others [code=C#] protected void btnSave_Click(object sender, EventArgs e) { if (btnSave.Text.ToUpper() == "CREATE") this.InsertInvoice(); else if (btnSave.Text.ToUpper() == "SAVE CHANGES") this.UpdateInvoice(); } private void InsertInvoice() { String … | |
I have a solutin with forms that use table adapters to input data into sql tables and that all works fine. My trouble comes when I have another form that uses a sql stored procedure. When I try to connect to the server I get an error that the login … | |
I want to simply insert a few string values which i have successfully retrieved from an Excel Sheet. I have tried the "stored procedure" method but am not able to get what what i want. Just a simple C# code to insert value in SQL server 2005 using the SQLquery … | |
hi. i need to send nearly 700 email at a time using asp.net., the email address will be in dataset, using for loop i had taken the email address one by one., but i dont know whether it will send the email without timeout thread or something else. For testing … | |
Hei, Im using ASP.NET as Front end and SQL Server as Backend. the codings are.. [code=asp.net]imports system imports system.data imports system.data.sqlclient [/code] After inherits...... some connectin codingd are there [code=asp.net]dim con as SqlConnection dim adp as SqlDataAdapter dim com as SqlCommand dim data as Dataset[/code] after the connection codings in … | |
any1 help, basically iv wrote the code to search for a client name in a database(in access) and this is the code:[quote] Private Sub BtnSearch_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) 'search If txtSearch.Text = "" Then MsgBox("Please type Client Name", MsgBoxStyle.Critical, "Enter Text") : Exit Sub Dim MYDA … | |
I have a program with about 20 forms, almost all of which use the data from a tables in a dataset (from a datasource I added to the project). So I have made a global variable in a module: [code] Public TTData As New TTDataSet [/code] And a DataAdapter for … | |
Hi all i am having some problem with the logic. can someone help me with it please. i am doing a vb.net project say for example a company has a lot of branches. I need to print the sales report for all the branches. so when printing it should print … | |
Hi, Is it somehow possible to determine the TableAdapter related to the given table?? I have DataSet with one strong-typed DataTable and related TableAdapter. Please, don't ask why :) but I need to determine related TableAdapter of given DataTable or DataTable of given TableAdapter having only one of them. Possible?? … | |
Hello! Please bear with me because I'm an amateur and this is difficult to explain. I have a data table of about 40000 records, with a primary key column that is a long integer value from 0 to ~40000. The records in the table are in sequential order based on … | |
Hi, I need to build a datagrid dynamically, entirely in c# so no asp tags can be used. I need my datagrid to contain a textbox in each cell; pre-populated with the corresponding value from the datatable. My code creates the text box in each cell perfectly BUT every value … | |
I am working in VB 2005. I want user input in textboxes. On user last textbox lost focus all data entered inthe textboxes shold shift to datagridview. User input as many data as he want. when he finish all his enteries. Click on save butto all data of datagridview insert … | |
Help Me, Please..VERY URGENT I have this cenario: I have a form(NewcomplaintForm.vb that will collect informations for ComplaintTable(complaintid, ComplaintType, date, desc, status, recommendation, etc..); ComplainantTable(complainantid, last, first, etc..); OffenderTable(offenderid, last, first, etc..) DutyofficerTable(dutyofficerid, last, first, etc..) and insert data into these tables respectively. when NewComplaint, check for complainant last and … | |
I have a small app im working on that allows users to input data into an access database. This data represents incoming and outgoing items. Currently, the user can input all incoming and outgoing transactions, but I haven't been able to set them up to cancel each other. What I … | |
Hello All. Can someone please help me? I have been at this code for two weeks. I am a newbie at creating the following code in VB6. I want to open a database (SQL), read from the data tables, and write the data into an existing excel spreadsheet cell by … | |
Hello Everyone, I am working a project that have three grid two of them load excel sheet and one is to reconcile the data of both gird. I have button Reconcile When press its works fine. My problem is this I have to made some changes in second datagrid and … | |
Hi, I have two XML files with different sturctures. Can I merge them into one dataset and how? Further, I want to bind them both to an editable datagrid. I am trying all sorts of options but not getting through. How can I do this? -Aditi | |
hi, i am doing a project using C#. i haven't much knowledge in C#. i stored some information in Dataset like named as (Table). i do't know how to collect the data from dataset(like Table) using DML (query). i do't know about the connection information. please kindly provide the notes … | |
Hi! I have 2 XML files with different structures. Can I 'merge' them into 2 different datasets and then bind to the datagrid? I tried doing that but it's merging all the data. Do i have a way out to exclude some of the data? I am skeptical as I … | |
I can't figure out how to email the password from a sql database I have a formview on my webpage can I pull it from there? or can I pull it directly on my backend code? Using C# I tried + passwordlabel + I tried using findcontrol.formview I can seem … | |
Hey Guys I have 2 DropDownList, with country and Province so I select country from the DDL provinces belong to that country should be populated to the Province DDL but instead Im get an Error with "INVALID COLUMN NAME fieldname" which is HK for Hong Kong, the following is the … | |
i have a checkbox(chkBoxMgr) on a windows form that i have already linked to a bindingsource(staffBindingSource). the value on the Staff table for the Mananger field is a "Y" how do i get the chkBoxMgr checkbox in a CHECKED state seeing that the value of the Manager field on the … | |
I've read up on attaching a dataset to a datagrid and followed all the code snippets I can, but I am still having problems viewing data. Have a look at this code: [code="VB"] Private Sub ViewCustomers(ByVal vRegion As String) conn.Open() Dim SQLComm = New SqlCommand("SELECT * FROM ViewCustomers('" & vRegion … | |
Hello, everybody. I have typed DataSet ([icode]dsMain[/icode]), that contains table ([icode]ReferenceCycle[/icode]). In the program I make changes in that table, using generated by VS typed table adapter ([icode]taReferenceCycle[/icode]) and values seems to gets inserted. And when I'm trying to update database with this - nothing happens. Here's part of my … | |
I’m building a tagger that searches through a corpus of IM data and tags any instances of words that occur on a wordlist. I've run into a problem and was hoping to find help. I'd like to try and understand exactly why it's not working, so I've laid out everything … | |
Hi! I'm using VS 2003 and MS Access. I have this Form1 that displays Record details on textboxes (they are databinded).. The records are retrieved from MS Access using the code: [CODE] Public Sub loadFund() '[Load Items] Dim selectAllSQL as string = "SELECT * FROM Table1" Dim selectAllCMD As OleDbCommand … |
The End.