Posts
 
Reputation
Joined
Last Seen
Ranked #495
Strength to Increase Rep
+6
Strength to Decrease Rep
-1
95% Quality Score
Upvotes Received
17
Posts with Upvotes
15
Upvoting Members
15
Downvotes Received
1
Posts with Downvotes
1
Downvoting Members
1
7 Commented Posts
7 Endorsements
Ranked #260
Ranked #425
~67.4K People Reached
Favorite Forums

97 Posted Topics

Member Avatar for airhalynn101

give thisread [Click Here](http://www.codeproject.com/Tips/311959/Format-a-textbox-for-currency-input-VB-NET)

Member Avatar for airhalynn101
0
1K
Member Avatar for xile27

If your CSV File has headers you can Just get the columns you want by the SELECT Query. Dim objCmdSelect As New OleDbCommand("SELECT Col1,Col2,col3... FROM " & fi.Name, objConn)

Member Avatar for tinstaafl
0
593
Member Avatar for jalmeida

I haven't had a chance to test this but I'm pretty sure you can ->Instead of deleting your record from the datatable. ` Me.TransmissoesDataSet.Tables("utilizador_Avancado").Rows(itemFound).Delete()` Remove the item from the BindingSource and call ResetBindings(False) Method. bs.RemoveAt(itemFound) bs.ResetBindings(False) Then Accept changes method on the table. You should be able to use the …

Member Avatar for kRod
0
428
Member Avatar for Start4me

Can you show some code where your error is happening. From the message it would seem you are trying to execute a query with the connection Closed.

Member Avatar for kRod
0
1K
Member Avatar for missy_mi

The following code shows how to put a table and some other minor things into a word doc. It's part of a database schema app. displaying the table name column names and their datatype ordinal position and if nullable. So the dbname and the table name are not important just …

Member Avatar for missy_mi
0
324
Member Avatar for kRod

I have a question about the string.intersect method. I am not getting the results I expect. Dim lstChars1() As Char = "hello dolly" 'TextBox1.Text.ToCharArray Dim lstchars2() As Char = "help melanie" 'TextBox2.Text.ToCharArray Dim lst1 As New List(Of String) Dim lst2 As New List(Of String) For Each c In lstChars1 lst1.Add(c.ToString) …

Member Avatar for kRod
0
1K
Member Avatar for christan

What exactly are you trying to do? You have an array of Button then you give a variable btnName a type Button without using it. Then you take your button in the array and try to create a new button without the array index. Not sure what event handler you …

Member Avatar for hainguyen81
0
235
Member Avatar for ignnniter

ignnniter, see if this helps you get your head around it. I have a button and two textboxes on a form use the default names in the click event put this. Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click Dim lstChars1() As Char = TextBox1.Text.ToCharArray Dim lstchars2() As …

Member Avatar for kRod
0
198
Member Avatar for Mr.M

You didn't provide the name for the file in the destination My.Computer.FileSystem.CopyFile("C:\Users\coder\Desktop\EXCEL PROJECT\excel\1_2012.xlsx", My.Computer.FileSystem.SpecialDirectories.Desktop & "\TestCopy.xlsx", True) [Click Here](http://msdn.microsoft.com/en-us/library/ms127964(v=vs.110).aspx)

Member Avatar for Mr.M
0
3K
Member Avatar for Eternal Newbie

Probably shouldn't help dredge up this post but it was never actually answered in VB so here goes. Intellisense will give you 10 choices of how you want to Align your header text. VS2008 / 2012 DataGridView1.ColumnHeadersDefaultCellStyle.Alignment = DataGridViewContentAlignment.BottomCenter

Member Avatar for kRod
0
2K
Member Avatar for Jeline_1

Why not bind the datagridview to a bindingsource. the reset the bindingsource. You will need a datatable or a collection but that should give you what you want. All you have to do is clear the datasource of the bindingsource and call the ResetBindings(False) method on the bindingsource

Member Avatar for G_Waddell
0
176
Member Avatar for Pickletronic

Try the following in your code. If it doesn't work take the single quotes from around searchStr it is probably Type integer in the Database Table Dim cmd As New OleDbCommand Dim da As OleDbDataAdapter With cmd .CommandText = "select * from car where Renter_ID = '" & searchStr & …

Member Avatar for G_Waddell
0
2K
Member Avatar for AnooooPower

Why not look for the LastIndexOf("0") [Click Here](http://msdn.microsoft.com/en-us/library/system.string(v=vs.110).aspx)

Member Avatar for AnooooPower
0
355
Member Avatar for Jimmy_1

Hello Jimmy_1, Just want to ask a few questions. From each of the worksheets how many Columns are you totaling and Are you Creating a new Worksheet in a new workbook from the others or do you just need the totals of the columns? For the Daily run you could …

Member Avatar for kRod
0
125
Member Avatar for kRod

I've been working on a Textbox that only accepts 0-9, Decimal Point, and the Backspace Keys. Also keeps it in the base form 0.00. Max value is 999999.99 can be set as needed. It works as expected, but I have to ask if I have remade the wheel. This sub …

Member Avatar for kRod
2
1K
Member Avatar for thannu07

You could use a BindingSource with the DataGridView. Then when your records are inserted successfully call the ResetBindings() Method. [Click Here](http://msdn.microsoft.com/en-us/library/system.windows.forms.bindingsource.resetbindings(v=vs.110).aspx?cs-save-lang=1&cs-lang=vb#code-snippet-1) Add the item to the Combox Items List.

Member Avatar for kRod
0
221
Member Avatar for johmolan

This is free [Click Here](http://www.dotnetheaven.com/article/sql-server-database-programmatically-in-vb.net)

Member Avatar for kRod
0
194
Member Avatar for Mike Bishop

See if the following will help Dim lstTextboxes As New List(Of TextBox) Private Sub LoadTextBoxList() lstTextboxes.Add(txtCustomername) lstTextboxes.Add(txtPartcode) lstTextboxes.Add(txtinvo) End Sub Private Sub btnTEST_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnTEST.Click Dim query = From tb In lstTextboxes _ Where tb.Text = "" _ Select tb.Name 'CALL SQL METHOD …

Member Avatar for kRod
0
122
Member Avatar for tatacco
Member Avatar for lrhimma

Im not sure about using the "AND"'s in your UPDATE statement there should be commas seperaing your fields and values. Here is a test query(StoredProcedure) I have in one of my access DB's. If you are going to be using this UPDATE query often you should create a stored procedure …

Member Avatar for kRod
0
160
Member Avatar for jared.geli

I see in 3 subs you are creating the same named dataset--> `DtSet`. The DataSet needs to be Global enough for the consumers of it within the project. This is probably why you are getting the * object reference not set to an instance of an object* error.

Member Avatar for jared.geli
0
763
Member Avatar for Aspir_1

I believe you need to set the combobox properties in the proper order. .DisplayMember = "Need to set this one too" .ValueMember = "ItemName" .DataSource = ds.Tables(0) Also how are you accessing the selecdt item/value when a combobox item is selected? the variables datatype needs to be the same as …

Member Avatar for kRod
0
191
Member Avatar for gmmorpheus

For starters In your Select Query you will need to add a Parameter for @Course. cmd.Connection = conn cmd.CommandType = CommandType.Text cmd.CommandText = sSQL cmd.Parameters.AddWithValue("@Course",value of Course) I also wouldn't open the connection until you have the Command Initialized but thats just me.

Member Avatar for Mr.M
0
164
Member Avatar for jennafher

You could query the worksheet to a datatable. Then loop thru the rows getting the items you want into the ComboBox. After that its just a matter of using the index of the ComboBox Item to get the value for your TextBox. dt.Rows(comboIndex).Item(columnNumber of value you want).ToString.

Member Avatar for kRod
0
170
Member Avatar for sachintha

myconnection = New OleDbConnection("provider=microsoft.ACE.OLEDB.12.0;data source=C:\Users\DELL\Documents\Visual Studio 2012\Projects\WindowsApplication9\WindowsApplication9\NIBM.accdb") myAdapter = New OleDbDataAdapter("select*from Driverdetails", myconnection) myAdapter.Fill(Ds, "Driverdetails") myconnection.Close() ** DataGridView1.DataSource = Ds.Tables(tableName or index)** DataGridView1.DataMember = "Driverdetails" End Sub You need to Set the DataSource of the DataGridView to a particular table of the dataset

Member Avatar for kRod
0
229
Member Avatar for Gus_19

Give the following a read [Click Here](http://msdn.microsoft.com/en-us/library/bb404903.aspx?cs-save-lang=1&cs-lang=vb#code-snippet-5)

Member Avatar for kRod
0
141
Member Avatar for jason.craft.5439

In your Sub newGame() You are Dim(ing) a variable named randomNumber instead of just reassigning your global variable new value. Since it's scope is local to only the Sub newGame it will have no effect on the global variable randomNumber and it will be whatever you assigned it in the …

Member Avatar for kRod
0
459
Member Avatar for JohnKelly
Member Avatar for UKnod

Give the following Link a try [Click Here](http://www.authorcode.com/search-text-in-word-document-in-vb-net/)

Member Avatar for kRod
0
85
Member Avatar for gayzlein

Have you written anything yet? You should read this post http://www.daniweb.com/software-development/vbnet/threads/460782/help-with-accessing-data-from-an-ms-access-database-with-vb

Member Avatar for gayzlein
0
8K
Member Avatar for said ahmed

I did a search on MSDN and Google and couldn't find one entry for the " exchange text box control"... must be something new coming in VS.Net 2014?

Member Avatar for Reverend Jim
0
115
Member Avatar for nikki05

You might try something like this..... Private Sub addSelectedClickHandlers(ByVal gb As GroupBox) Try For Each selectedControl As Control In gb.Controls AddHandler selectedControl.MouseMove, AddressOf selectedControl_MouseMove AddHandler selectedControl.MouseLeave, AddressOf selectedControl_MouseLeave Next Catch ex As Exception Debug.Print(ex.ToString) End Try End Sub

Member Avatar for kRod
0
302
Member Avatar for kRod

Good Day all, My question is When I get the schema of an EXCEL worksheet with Column headers I get what's expected the names of the columns but when I get the schema of a worksheet without headers I get the first row of data as the Column Names. The …

Member Avatar for kRod
0
495
Member Avatar for docgrid

I could not reproduce the problem you are having without using `Me.Activate` Then I got a list of the Processes Names and ID's into a Dictionary and used The 'EXCEL' Process ID to Activate the WorkBook with **AppActivate(procId)** Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click TextBox1.Text = …

Member Avatar for kRod
0
796
Member Avatar for drmangeshajoshi

Give this page a Look [Click Here](http://www.codeproject.com/Questions/621533/How-to-import-the-excel-data-to-MS-access-database)

Member Avatar for kRod
0
132
Member Avatar for Fangling

If all your tables are actually filled with data then DataGridView3.DataSource = query.ToList should load your DataGridView

Member Avatar for kRod
0
241
Member Avatar for Mireya B.

Im suprised these two commands didn't throw errors. Me.PlannedDurationTextBox = "" Me.PlannedRemarksTextBox = "" Anyway I do not see where you are calling Me.FourPPMCheckBox1.Value = False

Member Avatar for kRod
0
400
Member Avatar for yagelnnn1

How about reworking your code to say For Each Item In ComboBox1.Items If ListBox1.Items.Contains(Item) Then MsgBox("You can't add those items twice.", MsgBoxStyle.Exclamation) Else ListBox1.Items.Add(Item) End If Next

Member Avatar for tinstaafl
0
151
Member Avatar for sunilkumarasem

What is the datatype of your UserID in the "User" table? You are providing String Type to check against them in your table.

Member Avatar for kRod
0
321
Member Avatar for Jake.20

I'm working on a small database app to organize my song files and threw together this little sub to demonstrate a Null value in one of the columns of a record. It's OldeDB but should easily be adapted to SQL. I purposely left the Album name out on one of …

Member Avatar for kRod
0
267
Member Avatar for Ancient Dragon

When I use a DataAdapter and the CommandBuilder with a BindingSource I call the Update on the DataAdapter as follows. da.Update(ds, "TableName")

Member Avatar for Ancient Dragon
0
951
Member Avatar for carlbutler7

You are creating a new DataSet each time you run this code so the table your DataGridView is using gets refreshed with only the record queried for. You might try using the Datareader to fill the DataTable you're using for your DataGridViews DataSource. You can create some variables to hold …

Member Avatar for GeekPlease
0
647
Member Avatar for spyros.lois

If you used a DataAdapter DataSet and bound your datagrid with a BindingSource all you would have to do is call bindingSource1.ResetBindings(False) you would get the functionality you're looking for. Here is some sample code to point you in that direction. Imports System.Data.OleDb Public Class Form1 Dim conn As New …

Member Avatar for GeekPlease
0
161
Member Avatar for kipslem

I'm not trying to step on any toes, I just wanted to offer another approach. Also love the way Regex works. Imports System.Text.RegularExpressions Module Module1 Sub Main() Dim s As String = "ajasasaj$testing%878788%%$lkshhajsjah" Console.WriteLine("The Number Of Records in the line = " & NumberOfRecords(s, "$").ToString) Console.WriteLine() Console.WriteLine("Records with the $ …

Member Avatar for kRod
0
212
Member Avatar for kindofsudden

Why do you need to create an entire new database? Why not just create a new table to hold the new year's data? If you are set on creating a new DB then check out this link [Click Here](http://www.freevbcode.com/ShowCode.asp?ID=5797)

Member Avatar for kindofsudden
0
327
Member Avatar for 404notfound
Member Avatar for 404notfound
-1
246
Member Avatar for Unused Mass

If your DataGridView has a datatable as its datasource why not make use of the datatable read and write xml methods

Member Avatar for tinstaafl
0
4K
Member Avatar for PM312

Try using the GetValue method and the ordinal position of the field you want from the query. This would be "Select Field From Table" you are requesting 1 field so that's position 0 ComboBox1.Items.Add(CStr(DataReader.GetValue(0)))

Member Avatar for PM312
0
218
Member Avatar for samuel terngu

Hope this gets you started, it creates the insert query "q". You will need a connection and a command object.... You should read up on Datasets - Datatables - Datagridview - MS ACCESS. There are much easier ways of doing what you want. Please show what you have tried. For …

Member Avatar for kRod
0
2K
Member Avatar for SLMQC

You could just put Exit Sub or Function when you get to the Else after the Error Message. You should break them up into 2 different Functions, A Labor Function and A Parts Price Function Return A Boolean and then when both Return True Execute the rest of your code.

Member Avatar for SLMQC
0
269

The End.