Forum: VB.NET 3 Days Ago |
| Replies: 2 Views: 219 See this sample,
ListView1.Columns.Add("One")
ListView1.Columns.Add("Two")
ListView1.Columns.Add("Three")
Dim item As New ListViewItem("v1")
... |
Forum: VB.NET 3 Days Ago |
| Replies: 2 Views: 155 >How can I do this with the code I have so far?
Think about ReadAllLines() method.
.....
Dim s() As String = System.IO.File.ReadAllLines("file1.txt")
Dim i As... |
Forum: VB.NET 15 Days Ago |
| Replies: 1 Views: 396 Take a look at code snippet,
Dim dt As New Data.DataTable
dt.Columns.Add("Name")
dt.Columns.Add("Status")
dt.Rows.Add("A", "Paid")
dt.Rows.Add("B",... |
Forum: VB.NET 27 Days Ago |
| Replies: 8 Views: 493 Set SelectedIndex property,
listBox2.SelectedIndex = 0; |
Forum: VB.NET 27 Days Ago |
| Replies: 2 Views: 459 Take a look at this tutorial - http://www.dreamincode.net/forums/showtopic37361.htm |
Forum: VB.NET 34 Days Ago |
| Replies: 3 Views: 389 Try it,
Dim s As String = "This is an example"
s = String.Join(" ", s.Split(" ").ToArray().Reverse().ToArray()) |
Forum: VB.NET Nov 4th, 2009 |
| Replies: 2 Views: 247 Take a look at this thread - http://www.daniweb.com/forums/thread211516.html |
Forum: VB.NET Oct 17th, 2009 |
| Replies: 3 Views: 246 xfrolox,
I think you want to code which allows single instance of an application. Please take a look at this article - http://www.codeproject.com/KB/vb/sing_inistan.aspx |
Forum: VB.NET Sep 18th, 2009 |
| Replies: 7 Views: 677 You can't really parse HTML with regular expressions. It's too complex. Regular expression won't handle <![CDATA[ sections and reference enities correctly at all.
I recommend Html Agility Pack... |
Forum: VB.NET Sep 17th, 2009 |
| Replies: 3 Views: 533 If your dynamic array is integer then,
Dim a() As Integer = {11, 22, 33, 44}
System.IO.File.WriteAllLines("file.txt", Array.ConvertAll(a, New Converter(Of Integer, String)(Function(t As... |
Forum: VB.NET Sep 9th, 2009 |
| Replies: 7 Views: 828 By comparing references,
Dim btn As Button = CType(sender, Button)
Dim i As Integer
For i = 0 To bttonArray.Length - 1
If btn.Equals(bttonArray(i)) Then
... |
Forum: VB.NET Sep 9th, 2009 |
| Replies: 7 Views: 828 By sender reference,
CType(sender,Button).Text="Click" |
Forum: VB.NET Sep 7th, 2009 |
| Replies: 2 Views: 403 Use,
Dim S As String = TextBox1.Text
S = S.Trim()
Dim ar() As String = S.Split(New Char() {vbCr, vbLf}, StringSplitOptions.RemoveEmptyEntries)
S = "" & Join(ar,... |
Forum: VB.NET Sep 1st, 2009 |
| Replies: 1 Views: 534 Don't put .exe extension.
Dim p() As System.Diagnostics.Process = System.Diagnostics.Process.GetProcessesByName("calc")
If p.Length = 1 Then
p(0).Kill()
End If |
Forum: VB.NET Aug 28th, 2009 |
| Replies: 2 Views: 725 1. Create New Win Project
2. Add a class file into project - Create a sub class of DataSet
Imports System.Data.DataSet
Public Class DBO
Inherits DataSet
Private dt As DataTable
... |
Forum: VB.NET Aug 24th, 2009 |
| Replies: 3 Views: 384 sql = "SELECT DISTINCT year(dates) as MYear FROM summary WHERE plants = '" & yieldsummary.cbPlant.Text & "'"
da = New OleDb.OleDbDataAdapter(sql, con)
Dim Dt as New DataTable
da.Fill(Dt)... |
Forum: VB.NET Aug 22nd, 2009 |
| Replies: 3 Views: 205 Please look at - http://sqlserver-qa.net/google_bart.gif |
Forum: VB.NET Aug 19th, 2009 |
| Replies: 1 Views: 399 Select the property of Report or Page footer and set NewPageAfter=True or NewPageBefore=True |
Forum: VB.NET Jul 17th, 2009 |
| Replies: 3 Views: 244 babbu,
Set
dataGridView2.AllowUserToAddRows = False.
Why not DataAdapter?
.....
Dim oledbcom As New OleDb.OleDbCommand
oledbcom.CommandText = "Select... |
Forum: VB.NET Jul 2nd, 2009 |
| Replies: 5 Views: 355 Here is sample:
Dim col1 As New DataGridViewTextBoxColumn
col1.DefaultCellStyle.Format = "t" 'Time format
col1.DataPropertyName = "ColumnName"
... |
Forum: VB.NET Jun 25th, 2009 |
| Replies: 6 Views: 1,203 I said "post your complete code".
If DataTimeOff is an instance of DataTable then use following code:
CmbEmployee.DataSource = DataTimeOff
CmbEmployee.DisplayMember =... |
Forum: VB.NET May 28th, 2009 |
| Replies: 6 Views: 2,109 Label1.Parent = PictureBox1
Label1.BackColor = Color.Transparent
Label1.BringToFront()
Label1.Location = New Point(20, 20) |