2,383 Posted Topics

Member Avatar for LeNenne

[Read this article](http://support.microsoft.com/kb/253171) and [this article](http://www.vb-helper.com/howto_mdi_mru_list.html). Hope it helps and solved your question.

Member Avatar for Jx_Man
0
89
Member Avatar for VIPER5646
Member Avatar for VIPER5646
0
933
Member Avatar for codesly

First you must add the component. (ctrl+T or project->component) then select for **Windows Media Player**. You will see new control and just add it to your form. try this to play a video : WindowsMediaPlayer1.openPlayer "D:\father.mp4"

Member Avatar for xarhang
0
261
Member Avatar for Aven.Seven

Add this lines : FirstNameTF.AutoCompleteSource = AutoCompleteSource.CustomSource LastNameTF.AutoCompleteSource = AutoCompleteSource.CustomSource

Member Avatar for Jx_Man
0
234
Member Avatar for ChemE_Programma

> > @ Lee > > Hey man thanks alot for responding. I have decided to go another route on this project and am not sure of I can close this thread. But... I relized after I posted that I didnt need a 2D array. I am now takeing a …

Member Avatar for Jx_Man
0
464
Member Avatar for aisha.edris1

[Visual Basic .NET Programming for Beginners](http://www.homeandlearn.co.uk/NET/vbNet.html)

Member Avatar for Jx_Man
0
114
Member Avatar for LEAN.HEART.YOU
Member Avatar for Sturdy

> I want it in 4 columns (First name, last name, age and blood type). > There are 4 arrays that i want it to written in list view but the point is how i can read it form text file and use listview to show it. This should working …

Member Avatar for Sturdy
0
2K
Member Avatar for ponnu

Try this : Private Sub Form_Load() Dim Conn As New ADODB.Connection Dim rs As ADODB.Recordset Set Conn = New ADODB.Connection Conn.Provider = "Microsoft.ACE.OLEDB.12.0" Conn.CursorLocation = adUseClient Conn.Open "D:\database.accdb" Set rs = New ADODB.Recordset rs.Open "select * from mytable", Conn, adOpenDynamic, adLockBatchOptimistic While Not rs.EOF Combo1.AddItem rs!name rs.MoveNext Wend rs.Close End …

Member Avatar for ponnu
0
266
Member Avatar for molti

Welcome to daniweb larsquestion.. [Please make your own thread](http://www.daniweb.com/software-development/vbnet/58/contribute). Don't rise dead thread. You will get help from many members with new thread. Thank you :)

Member Avatar for Jx_Man
0
236
Member Avatar for LeNenne
Member Avatar for Ann95

Try : Dim temp As Long = 0 For i = 0 To DataGridView1.Rows.Count - 1 temp = temp + DataGridView1.Item(6, i).Value 'Column 6 is Amount Next Total.Text = temp

Member Avatar for Ann95
0
165
Member Avatar for mcoliver88
Member Avatar for bklynman01

Try to set Combobox SelectionIndex = -1 to make it not select any items on Form Load event. Combobox1.SelectionIndex = -1

Member Avatar for Reverend Jim
0
193
Member Avatar for Unused Mass

See this example : This is the xml file named student.xml : <?xml version="1.0" standalone="yes"?> <Table> <Students> <No>1</No> <Name>Jery</Name> <Address>New York</Address> </Students> <Students> <No>2</No> <Name>Dewi</Name> <Address>Olympus</Address> </Students> <Students> <No>3</No> <Name>Me</Name> <Address>earth</Address> </Students> <Students> <No>4</No> <Name>Craig</Name> <Address>Jogja</Address> </Students> </Table> This how to read and write it through datagridview : Just add …

Member Avatar for tinstaafl
0
4K
Member Avatar for ChargrO

Or you can check if the textbox input is numeric using IsNumeric() function Also [read this snippet](http://www.daniweb.com/software-development/vbnet/code/414248/textbox-validation)

Member Avatar for Rahul47
0
214
Member Avatar for ponnu
Member Avatar for november_pooh

> I already build a program with vb6. The problem is when the program is running and user click the exe file again then it makes program running twice in same time. > Is there a way to restrict this happened? Something like this should working : Private Sub Form_Load() …

Member Avatar for Jx_Man
0
408
Member Avatar for HibaPro

> how i can check if text box value exist in data base or not plzzz helppp It's better to understand if you post your code. How far you doing this.

Member Avatar for Jx_Man
0
313
Member Avatar for xLuFeT
Member Avatar for LeNenne

Try : Private Sub Command2_Click() Kill (App.Path & "\backup\PhoneTel.mdb") End Sub Or you can do like this : Private Sub filedelete(filename As String) Dim filesystemobject As Object Set filesystemobject = CreateObject("Scripting.filesystemobject") filesystemobject.deletefile filename, True End Sub Private Sub Command2_Click() filedelete (App.Path & "\backup\PhoneTel.mdb") End Sub

Member Avatar for Jx_Man
0
124
Member Avatar for haseeb001

Wow.. How about make some effort here. We have rules in daniweb :) Post your code and many members here trying to help you.

Member Avatar for Jx_Man
0
145
Member Avatar for Papa_Don

> dIndex = myText.IndexOf("|") ... > So, is there a "length" command to find the total number of characters in the string? To get total character/length : sLength = myText.Length But if you want to get string after | sign then you can use substring function : PrinterId = myText.Substring(myText.IndexOf("|") …

Member Avatar for Papa_Don
0
8K
Member Avatar for subrata.roy.7583992

> DLP/001/2013-2014 > DLP/002/2013-2014 > DLP/003/2013-2014 I don't recomended to make autonumber to an Id like this but you can split it. Get the Last Invoice number from database and Split it by "/". Extract the second value in array and you will get the existing invoice num. Add it …

Member Avatar for subrata.roy.7583992
0
195
Member Avatar for Sturdy

Something like this should working : Function ReadFileText(ByVal filename As String) As String Dim handle As Integer ' ensure that the file exists If Len(Dir$(filename)) = 0 Then Err.Raise 53 ' File not found End If ' open in binary mode handle = FreeFile Open filename$ For Binary As #handle …

Member Avatar for Sturdy
0
2K
Member Avatar for blaze007

> while ((line = sr.ReadLine()) != null) > { > string[] values = line.Split(new string[] {","}, StringSplitOptions.None); > for (int i = 0; i < values.Length; i++) > { > ....... > } > > i dont know how to add values to the array > I'm little confused here. …

Member Avatar for ddanbe
0
341
Member Avatar for subrata.roy.7583992

Datagridview? Are you use Vb.Net? Also what you get so far? Post your code here. Make some efforts.

Member Avatar for Jx_Man
0
275
Member Avatar for LeNenne
Member Avatar for Hazuan Nazri

Try : For i As Integer = 0 To DataGridView1.RowCount - 1 If DataGridView1.Rows(i).Index Mod 2 = 0 Then DataGridView1.Rows(i).DefaultCellStyle.BackColor = Color.LightBlue Else DataGridView1.Rows(i).DefaultCellStyle.BackColor = Color.LemonChiffon End If Next i

Member Avatar for Hazuan Nazri
0
452
Member Avatar for imBaCodes
Member Avatar for LeNenne

See this : > Set rs = db.OpenRecordset("select * from phone where eftn + ' ' + namn = '" & _ Trim(LstData1.List(LstData1.ListIndex)) & "'") Your sql query is wrong. You want to display data in textbox when you select listbox but you never get *eftn* and *namn* value from …

Member Avatar for LeNenne
0
157
Member Avatar for Papa_Don

You can change the width or height of controls and follow the form width or height. Use Form resize event to make it works. Eg : Private Sub Form1_Resize(ByVal sender As Object, ByVal e As System.EventArgs) Handles Me.Resize TextBox1.Width = Me.Width - 40 End Sub

Member Avatar for Papa_Don
0
554
Member Avatar for imBaCodes

Try : `SendKeys "%s"` [Read this for more information](http://msdn.microsoft.com/en-us/library/aa266279%28v=vs.60%29.aspx)

Member Avatar for imBaCodes
0
906
Member Avatar for ppstyle
Member Avatar for LeNenne
Member Avatar for subrata.roy.7583992

I will recommend you to use ADODB method. It's more easy to handling database path and connection with database.

Member Avatar for Jx_Man
0
853
Member Avatar for mlesniak

> I wanted to know if there was a tidy way of starting from column 1 to begin with Remove one column when form load. Private Sub Form_Load() DataGrid1.Columns.Remove 0 End Sub

Member Avatar for imBaCodes
0
249
Member Avatar for nitos

Specify what is Recall. If recall just string then put double quote around it and confirm the case sensitive input from the textbox.

Member Avatar for Jx_Man
0
287
Member Avatar for LeNenne

Set textbox **MaxLength** when form load or you can set **MaxLength** in **textbox Properties** : Private Sub Form_Load() Text1.MaxLength = 2 End Sub

Member Avatar for Jx_Man
0
103
Member Avatar for kimangel
Member Avatar for kwng

App.Path is return path of your program. It will return path where the project is saved. Just take a test. Create a new project and display a path of project (Msgbox App.Path) in form load event and save it. It will return path of project. Move the project to another …

Member Avatar for fsshah
0
884
Member Avatar for joramkaku

> Is it possible to store Data(Word;Type;Sentence) in textfile and to display in the Listbox and textbox. Yes, It's possible. Imports System.IO ' This will add Data as new line in txt file. Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim writer As StreamWriter writer …

Member Avatar for tinstaafl
0
322
Member Avatar for vinodita

Try : Dim regTime As New System.Text.RegularExpressions.Regex("^([0-1][0-9]|[2][0-3]):([0-5][0-9]):([0-5][0-9])$") Dim t1 As String = "25:12:12" Dim t2 As String = "12:45:34" Dim t3 As String = "01:12:92" MsgBox(regTime.IsMatch(t1).ToString) MsgBox(regTime.IsMatch(t2).ToString) MsgBox(regTime.IsMatch(t3).ToString)

Member Avatar for Jx_Man
0
131
Member Avatar for ScarWars9

Selectedrow need you to select full row. In datagridview properties, change datagridview **SelectionMode** to **FullRowSelect**.

Member Avatar for ScarWars9
0
2K
Member Avatar for Start4me

When write a code you must know what the value of variables. > Label1.Text = "First digit:" & TextBox1.Text.Substring(0, 1) > Label2.Text = "Second digit:" & TextBox1.Text.Substring(1, 1) > > Label3.Text = (Label1.Text) ^ 2 Ex : TextBox1 = 12 Now **Label1.Text** will contain **"First digit:1"** So you can't square …

Member Avatar for Jx_Man
0
282
Member Avatar for Nebil

Try : `str = "DELETE FROM AdigratT WHERE Bridge_Number = '" & ListView1.Items(x).SubItems(0).Text & "'"`

Member Avatar for Begginnerdev
0
355
Member Avatar for ASWEDAN
Member Avatar for zawpai

> Is it possible to select multiple records (rows) in "DataGrid" > Because I can't find any properties to enable for multiple selection. Yes.. Just press ctrl while you selecting items. > delete all selected items? I not sure you can do this. Your code just remove bookmark not remove …

Member Avatar for zawpai
0
3K
Member Avatar for EkoX

Try this : Add 1 Command Button to your form. Add 1 reference to Microsoft Excel 12.0 Object Library **Project -> References -> mark the Microsoft Excel 12.0 Object Library** Private Sub Command1_Click() Dim xlApp As Excel.Application Dim xlWB As Excel.Workbook Dim xlWS As Excel.Worksheet Set xlApp = New Excel.Application …

Member Avatar for EkoX
0
457
Member Avatar for november_pooh

Try : Private Sub Command1_Click() If Dir$("D:\Daniweb\", vbDirectory) = "" Then MkDir "D:\Daniweb\" Else MsgBox "Duplicate Folder" End If End Sub Private Sub Command2_Click() If Dir$("D:\Daniweb\", vbDirectory) = "" Then MsgBox "Folder not found" Else RmDir "D:\Daniweb\" End If End Sub

Member Avatar for rishif2
0
355

The End.