2,634 Topics
![]() | |
Hi All, I'm taking a different approach to importing the csv to access and trying to import the csv to the dataset. I've found the following code but it's giving me an error Dim fileToOpen As String Dim da As New OleDbDataAdapter() Dim ds As New DataSet() fileToOpen = ImportFiles.SelectedItem … | |
Hi All, I'm trying to import the contents of a csv file to an access database. I have a database named myDatabase with a table named myTable. It has columns A-E say. I have a csv file with headings in the first row which are called say S-Z. I want … | |
Hi Guys, wondering if someone could help me please, this is probably easy for most, but im a beginner :) i want to make an array from my dataset dataset is from (tbl_Employees) i want the array to hold 3 columns/items = item 1 (Username), item 2 (password) item 3 … | |
I have this code Dim con = New SqlConnection("Data Source=.\SQLEXPRESS;AttachDbFilename=C:\Users\Danial\documents\visual studio 2010\Projects\ESI_PF_Payroll_V1\ESI_PF_Payroll_V1\Pay.mdf;Integrated Security=True;Connect Timeout=30;User Instance=True") con.Open() cmd.CommandText = "SELECT Firstname,Lastname FROM Employee where Firstname = @Firstname and Lastname = @Lastname" cmd.Parameters.Add(New SqlParameter("@Firstname", TextBox1.Text)) .Value = TextBox1.Text cmd.Parameters.Add(New SqlParameter("@Lastname", Lname_txt.Text)) .Value = Lname_txt.Text dr = cmd.ExecuteReader While dr.Read Label4.Text = dr(0) … | |
I create small database and I want to show all information about the students when a techer enter Students ID I caret my database using visual studio 2008 Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim constr as new OleDb.OleDbConnection constr.ConnectionString = "Provider=localhost;data source=C:\USERS\USER\DOCUMENTS\VISUAL STUDIO … | |
While creating a module within my program, I created a second Dataset (and it's called DesignDataSet2). I would like to delete it from the database altogether. I have already removed the one datatable that was within this dataset. I now want to eliminate this completely. How do I go about … | |
![]() | Hello all, First, if I may, a comment. This is my first post. I have been a member of another forum and found that users are treated with little respect... assumptions are made, stupid questions are not allowed patience, etc. I work for a large IT corporation (if I told … |
Hi everyone! I'm trying to display the logo for a particular supplier but I always end up with an error picture. here's my code: Imports System.Data.OleDb Imports System.Data Public Class SupplierDetails Dim objConnection As New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\Users\Cristy\Desktop\InventorySystem\InventorySystem\inventory.mdb") Dim objDataAdapter As New OleDbDataAdapter( _ "SELECT Supplier, ContactPerson, PhoneNumber, FaxNumber, " & … | |
In a table,in first row consist of static html control (1 select control and 5 textboxes).From second row onwards i created the rows dynamically(consist of 1 select control and 5 textboxes) on click of html button.Creation is successfull.But problem arised when i wanted to attach dataset table data to html … ![]() | |
Hi to every one .. I have Access database Access 2007 . and i need to connect with ASp.net ..nad i put database in db folder but it gives errors ... if provide Database1.accdb in connection string (following error) Unrecognized database format 'C:\Documents and Settings\erum.mirza\My Documents\Visual Studio 2008\Projects\ajax\ajax\db\Database1.accdb'. if provide … ![]() | |
I have limited knowledge in coding. can anyone tell me what is worng with my code? the firstrow result in the database is not updated, but it is updated in datagridview. For i As Integer = 0 To DataGridView1.RowCount - 1 DataGridView1.Rows(i).Cells(11).Value = "true" Next SmsdDataSet.AcceptChanges() | |
I have a problem with retrieving data from access databse. I make the connection and retrieve the data no problem. But when the data changes from another use of the database, I cannot get the new changed data without reloading the complete programme. Even repeating the load functions does not … | |
Hi, IF I run my application was created in vb.net, it Shows an error like "Incorrect syntax near '3/15/2013 12:00:00 AM'." I neeed to Display the data in Gridview Based on date.. The code is Private Sub File_Request_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Form1.Visible = False … | |
hello guys, i have an sql statement that is supposed to be returning data from two tables that i have joined. Here is the code below: sql = "SELECT rooms.roomID, rooms.roomNumber, rooms.roomStatus, " & _ "roomType.roomType, roomType.adultRate, roomType.childrenRate, roomType.roomTypeID FROM rooms " & _ "JOIN roomType on rooms.roomType = roomType.roomTypeID" … | |
Hi Guys, I have a Dataset which has been populated correctly now (after a bit of a blonde moment earlier). I've decided to go for a ComboBox Drop-Down option which currently is showing the "companyname" Column of the DataSet. However, How do I go about Getting Text boxes to To … | |
Hi Guys... Putting together a Tiny little app which shows VPN Details for use 'In-House' but for some strange reason my DataSet won't fill? Can anyone spot the mistake? :S private void Form1_Load(object sender, EventArgs e) { //XML Load of Document. This loads the XML Document and the value of … | |
Hi All, I am hoping someone can help me with this and/or point me in the right direction. I am developing a quiz application and have run into a problem when the question being pulled from the database is a true/false question it produces an error, straight multiple choice questions … | |
This code creates XML File Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim connetionString As String Dim connection As SqlConnection Dim adapter As SqlDataAdapter Dim ds As New DataSet Dim sql As String connetionString = "Data Source=.\SQLEXPRESS;AttachDbFilename=C:\Users\Danial\documents\visual studio 2010\Projects\ESI_PF_Payroll_V1\ESI_PF_Payroll_V1\Pay.mdf;Integrated Security=True;Connect Timeout=30;User Instance=True" connection = New … | |
Hello, I am trying to divide my dataset(iris dataset) into training and test sets randomly. My dataset contains 150 patterns. And I need to divide 90 patterns to test set, and the rest to training set. How can I do this? Help me with the C code. Thank you | |
I'm trying to populate a dataset from an excel sheet but I keep getting a "could not find installable ISAM" error. (In order to evaluate an indexed property, the property must be qualified and the arguments must be explicitly supplied by the user.) on the adapter.Fill line. Already tried changing … | |
Hi everyone, please i am writing a program in C# for connecting to a microsoft access database using visual studio 2005 and ADO.NET. i want to be able to use Dataset to update,delete,insert and edit records in the database.please how do i go about this.I already have aform with a … | |
I am having trouble with my login and receive this warning 'noOfRows = da.Fill(ds, "tblCustomers");' No value given for one or more required parameters. I want My Login to search my database for the correct pin and account number but my program doesnt seem to work. My code for form1 … | |
CODE: Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim con = New SqlConnection("Data Source=.\SQLEXPRESS;AttachDbFilename=C:\Users\Danial\documents\visual studio 2010\Projects\ESI_PF_Payroll_V1\ESI_PF_Payroll_V1\Pay.mdf;Integrated Security=True;Connect Timeout=30;User Instance=True") Dim adaptor As New SqlDataAdapter Dim dataset As New DataSet con.Open() con.Close() con.Open() cmd = New SqlCommand(str, con) cmd.Connection = con cmd.CommandText = "SELECT Firstname FROM … | |
Dim conn As New OleDb.OleDbConnection Dim ds As New DataSet Dim dt As New OleDb.OleDbDataAdapter conn.ConnectionString = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=C:\Users\admin\Documents\Visual Studio 2010\Projects\office software\office software\bin\Debug\Office1.accdb;Persist Security Info=False; " Try cmd.Connection = conn conn.Open() cmd.CommandText = "insert into Office Values('" & CInt(TBID.Text) & "','" & TBSupplierName.Text & "', " & TBProductName.Text & "," … | |
Ok so I have a class for all my database connections, what I want to do is populate my gridview from my select statment within my database class. How do I do this? Code can be seen below: Database.cs public static string DeleteChild(string Ssession) { string surname = string.Empty; cmd … ![]() | |
Hi guys... I have a radio button that one checked will connect to an ADO Connection. The following code being used is: private void radioButton3_CheckedChanged(object sender, EventArgs e) { //Fields Disabled until a new Account is created.// txtAccRef.Enabled = false; txtAccName.Enabled = false; txtAccAddr1.Enabled = false; txtAccAddr2.Enabled = false; txtAccTown.Enabled … | |
Hy all, I'm new at using sql server compact,so I don't know yet if what I want to do is possible:)? I have the following setup: 1.Datatable created from a table from my database(this is the table that I want to update later); 2.Make modification on datatable and save it; … | |
string location = Environment.CurrentDirectory; string connectionString = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source =" + location + "\\harita.accdb"; // get records from the Shippers table string commandString = "Select x from map"; //create the data set command object and the DataSet OleDbDataAdapter DataAdapter = new OleDbDataAdapter(commandString, connectionString); DataSet ds = new DataSet(); // fill … | |
string location = Environment.CurrentDirectory; string connectionString = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source =" + location + "\\harita.accdb"; // get records from the Shippers table string commandString = "Select x from map"; //create the data set command object and the DataSet OleDbDataAdapter DataAdapter = new OleDbDataAdapter(commandString, connectionString); DataSet ds = new DataSet(); // fill … | |
Hi Guys, Is there a best practise when having an ADO connection to speed up the process? Currently the method I am using below works fine but it's a little slow in getting the data. Is there any hints, tips or tricks I can utilise to speed this up? //Opens … | |
Hello, I have made an Employee Time clock application. I have been working on connecting my application to a MySQL database, I have a textbox wich is used to add an employee name to my database (this is working perfectly.), but I also a combobox where I want the list … | |
Hi guys, I'm hoping you can help here with a problem I am having with regards to filling a Dataset. It was working fine but have had to amend the code to read a different data set and structure. Basics are 2 tables.. one customers, 1 orders. Joined on there … | |
![]() | Hi, Here is the code I’m trying to execute using MS Access database to return a dataset. And i get the error "No value given for one or more required parameters". Public Class Main_Form Dim conn As New OleDb.OleDbConnection Private Sub btnReset_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles … |
Good evening! I'm trying to figure out how to retrieve and display data from MS Access to my project's DataGridView. So far I have the codes to make the options for the CheckedListBox appear. SAMPLE: (Codes for other categories are not included since they're all basically the same) 'view client … | |
Hi i am developing a website to downlod softwares online.From general page of softwares user is allowed to download software after login or register.after login it must be go to user panel's main download page with taking id of software on which a person has clicked..i code below at login … | |
Hello Every One, When i run my project i get Error "There is no row at position 0", please help. Here is my code: Private Sub PopulateDepartmentHead() 'Fill data in comboBox Dim SqlDataAdapter As OleDbDataAdapter Dim DSet As New DataSet Dim strSelect As String SQLConn.Close() SQLConn.ConnectionString = oFunc.GetConnectionString(sINIFile) 'myConn = … | |
Good day! I have this datasets format in sql server! AccountID AccountName 1/30/2013 2/30/2013 3/30/2013 4 Credit Cards 20,000 30,000 12,000 5 Loans Payable 5,000 6,000 5,000 How can I load all this data to listview? The colums are dynamic. It could be 6, 7, 8, or 12, or higher. … | |
I have two tables Employer Employee Employer Table: I have one field EmployerID (pk Key assigned to it) Employee Table: EmployerID(pk Key assigned to it) IDEmployer(fk key assigned to it,and Allow Nulls:Checked) Now my question is how to relate two tables ,that I will now that who works for who? … | |
Once I have logged in, the "loggedIn.aspx" page is to display: IP Address: Contact: Date: I am able to get the IP address to display, but really have no clue on how to show both the username and current date. This was a conversion from .asp to c#.net Here is … ![]() | |
I need to consume a web service in VS 2010 using VB.NET that gives a result of a class type. I've already added the reference and called it with: Dim mag As New Magento.ecommerce I can create a variable as the class: Dim Stockcodes As New List(Of Magento.clsStockcode) I just … | |
Hi how can i pass if my connection is false? i have a code here Dim con As New OleDbConnection Dim dt As New DataTable Dim ds As New DataSet con.ConnectionString = ("provider=Microsoft.Jet.OLEDB.4.0; Data Source='" & ConMonthEndLocation & "';Extended Properties=Excel 8.0;") con.Open() dt.Clear() ds.Tables.Add(dt) With Form_Month_End_Report .ListView_LOB.Columns.Clear() .ListView_LOB.Items.Clear() Dim da … | |
I have done the following codes to create a bar chart with the data from DB, and save it as an JPEG file. I wanted to add percentage value anywhere in the table, JDBCCategoryDataset dataset = new JDBCCategoryDataset("", "oracle.jdbc.OracleDriver", "", ""); String query = "SELECT std,id from table"; dataset.executeQuery(query); JFreeChart … | |
Hi guys, I've been cracking on with this project for a few days now and had lots of useful pointers to help along the way. I've now hit a little snag where I think I have written the correct update Statement but It seems to error at the last point. … | |
Hello i'm getting theses to error with my sql code can anyone help me ot at all i'm really lost and can't find much to help where i'm going wrong.Code is below Error 3 The best overloaded method match for 'System.Data.SqlClient.SqlCommandBuilder.SqlCommandBuilder(System.Data.SqlClient.SqlDataAdapter)' has some invalid arguments Error 4 Argument 1: cannot … | |
Hi Guys, The reason for my message was to do with UPDATE and DELETE Statements from within C# when contacting a MDB file. I currently have the INSERT INTO SQL Query working perfectly The Code I used for this is below: else if (radioButton2.Checked == true) { //Creates new versions … | |
Hi guys, I am building a program which has 5 forms, 1 mainmenuform with 4 buttons and each of them buttons have a form corrisponding to that button and this program is connected to my access database. The problem I have is I've put all my code into my first … | |
Hi again guys... I have a little but of an issue with a select statement I cannot seem to fathem out. Below is the code: else if (radioButton3.Checked == true) ; { //Looks at the row Selected in the GridView and then takes the Account Number and Stores in a … | |
Hi Guys, Have a random problem as to why my headers are not being shown properly in the form? Possibly a simple anwser but can't see the wood for the tree's at the moment and another pair of eyes is always great. Code below: private void radioButton1_Click(object sender, EventArgs e) … | |
Good day, I have a module that upload a record using excel file, and that excel file will be save into the table.. actually i already created that but one ofmy requirement is to clear first the record in excel before it will be uploaded.. how could i clear the … | |
Good day,, I am having problem with the autocompleteextender in my application. i already created a webservice.. here is my code <asp:TextBox ID="txtSKU" runat="server"></asp:TextBox> <cc1:AutoCompleteExtender ID="aceSKU" runat="server" Enabled="True" ServicePath="http://localhost:3099/WebService1.asmx" ServiceMethod="GetMaterialName" TargetControlID="txtSKU" MinimumPrefixLength="2" CompletionInterval="100" EnableCaching="true" ShowOnlyCurrentWordInCompletionListItem="true" > </cc1:AutoCompleteExtender> and here is my whole webservice code using System; using System.Collections; using System.ComponentModel; … |
The End.