2,383 Posted Topics
Re: [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. | |
Re: In the properties of the MdiParent look for IsMdiContainer and set it to true. | |
Re: 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" | |
Re: Add this lines : FirstNameTF.AutoCompleteSource = AutoCompleteSource.CustomSource LastNameTF.AutoCompleteSource = AutoCompleteSource.CustomSource | |
Re: > > @ 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 … | |
Re: [Visual Basic .NET Programming for Beginners](http://www.homeandlearn.co.uk/NET/vbNet.html) | |
Re: Provide more information. What you want to print? | |
Re: > 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 … | |
Re: 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 … | |
Re: 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 :) | |
Re: 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 | |
Re: save the binary picture to the access database. | |
Re: Try to set Combobox SelectionIndex = -1 to make it not select any items on Form Load event. Combobox1.SelectionIndex = -1 | |
Re: 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 … | |
![]() | Re: 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) ![]() |
Re: Post your code. How far you doing this. | |
Re: > 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() … | |
Re: > 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. | |
Re: What you got so far? Post your code here. | |
Re: 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 | |
Re: Wow.. How about make some effort here. We have rules in daniweb :) Post your code and many members here trying to help you. | |
Re: > 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("|") … | |
Re: > 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 … | |
Re: 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 … | |
Re: > 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. … | |
Re: Datagridview? Are you use Vb.Net? Also what you get so far? Post your code here. Make some efforts. | |
Re: What you mean about clear the screen? what screen? | |
Re: 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 | |
Re: [Reat this](http://www.excelguru.ca/content.php?161) | |
Re: 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 … | |
Re: 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 | |
Re: Try : `SendKeys "%s"` [Read this for more information](http://msdn.microsoft.com/en-us/library/aa266279%28v=vs.60%29.aspx) | |
Re: [Read this](http://www.connectionstrings.com/excel-2007) | |
Re: Try : MsgBox Mid$(Text1.Text, 1, 4) | |
Re: I will recommend you to use ADODB method. It's more easy to handling database path and connection with database. | |
Re: > 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 | |
Re: Specify what is Recall. If recall just string then put double quote around it and confirm the case sensitive input from the textbox. | |
Re: Set textbox **MaxLength** when form load or you can set **MaxLength** in **textbox Properties** : Private Sub Form_Load() Text1.MaxLength = 2 End Sub | |
Re: > thank you sir TnTinMN. Then mark this thread as solved :) | |
Re: 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 … | |
Re: > 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 … | |
Re: 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) | |
Re: Selectedrow need you to select full row. In datagridview properties, change datagridview **SelectionMode** to **FullRowSelect**. | |
Re: 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 … | |
Re: Try : `str = "DELETE FROM AdigratT WHERE Bridge_Number = '" & ListView1.Items(x).SubItems(0).Text & "'"` | |
Re: Then try to change SavingSalaryDetails to viruses_analysis. | |
Re: > 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 … | |
Re: 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 … | |
Re: 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 |
The End.