2,383 Posted Topics
Re: [code=vb]' Return True if a file exists Function FileExists(FileName As String) As Boolean On Error GoTo ErrorHandler ' get the attributes and ensure that it isn't a directory FileExists = (GetAttr(FileName) And vbDirectory) = 0 ErrorHandler: ' if an error occurs, this function returns False End Function Private Sub Form_Load() … | |
Re: try this following code : First Textboxt to input words = textbox2 Second to input certain char = textbox1 Button to execute and label to show result. [code=vb.net]Private Sub btnSearch_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnSearch.Click Dim jmlText, jmlChar, i As Integer jmlChar = 0 jmlText = … | |
Re: this will detect if mouse button clicked : [code=vb.net] Private Sub Form1_MouseDown(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles MyBase.MouseDown If e.Button = MouseButtons.Left Then MsgBox("left button clicked") ElseIf e.Button = MouseButtons.Right Then MsgBox("Right button clicked") End If End Sub [/code] | |
Re: try this : [code=vb.net]Public Function Factorial(ByVal Number As Integer) As String Try If Number = 0 Then Return 1 Else Return Number * Factorial(Number - 1) End If Catch ex As Exception Return ex.Message End Try End Function[/code] I called this function in button click event: [code=vb.net]Private Sub Button2_Click(ByVal sender … | |
Re: try this following code : [code=vb] Dim con As New OleDb.OleDbConnection Dim cmdOle As New OleDb.OleDbCommand Dim dsOle As New DataSet Dim da As New OleDb.OleDbDataAdapter Dim dtOle As New DataTable Dim sql As String Private Sub LoadData() con.ConnectionString = ("Provider = Microsoft.JET.OLEDB.4.0;Data Source= D:\Only Me\Authors.mdb") Try cmdOle = con.CreateCommand … | |
Re: First add reference Microsoft SQLDMO Object Library. then add this code : [code=vb.net]Dim i As Integer Dim oNames As SQLDMO.NameList Dim oSQLApp As SQLDMO.Application oSQLApp = New SQLDMO.Application oNames = oSQLApp.ListAvailableSQLServers() AddHandler ComboBoxEdit4.SelectedIndexChanged, AddressOf comboBoxEdit4_SelectedIndexChanged For i = 1 To oNames.Count Me.ComboBoxEdit4.Properties.Items.Add(oNames.Item(i)) Next i[/code] | |
Re: Hi... You want to add it and run with vb.net. .Net doesn't have a special Script Control. Download the Script Control (ActiveX) from Microsoft [URL="http://searchwindevelopment.techtarget.com/tip/0,289483,sid8_gci1045916,00.html"]See this link[/URL] | |
Re: see this code : [code]Dim cn As OleDbConnection Dim cmd As OleDbCommand Dim dr As OleDbDataReader cn = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0; Data Source=C:\MyDB.mdb;") cn.Open() cmd = New OleDbCommand("SELECT * FROM Breakdown WHERE BFrom = '" & txtFrom.Text & "'", cn) dr = cmd.ExecuteReader If dr.Read() MsgBox "Matching Records Found" 'write whatevr … | |
Re: what kind of database? how far u do this?post your code friend :) | |
Re: [URL="http://forums.msdn.microsoft.com/en-US/vblanguage/thread/ebded5b4-dcf2-49c7-bec8-96aa3dded057/"]see this link[/URL] | |
Re: [QUOTE=selvaganapathy;624146]Hi, Welcome to Daniweb. You are new to VB.Net and SQL. but the process of VB.Net with SQL cannot be explained shortly. It is a lengthy process. so please try and tutorial of VB.Net with SQL and Try your own coding. If any problem occurred, post the problem any one … | |
Re: which one u want to use? Horizontal scroll bar [code]Private Sub HScroll1_Change() Text1.Text = HScroll1.Value End Sub[/code] Vertical scroll bar [code]Private Sub VScroll1_Change() Text1.Text = VScroll1.Value End Sub[/code] | |
Re: hmm.. when u opened vb 6 project use vb.net it will convert your project in vb.net. so u can convert your project into vb 6 first then u can open current project in vb.net. Thats what i doing. | |
Re: ??? Visit this [URL="http://jsc.sourceforge.net/"]site[/URL], [URL="http://ddj.com/windows/208401872?cid=RSSfeed_DDJ_Windows/.NET"]this one too[/URL], And [URL="http://news.zdnet.co.uk/software/0,1000000121,2103779,00.htm"]this too[/URL]. | |
Re: try this : [code=c#] private string CharHash(string Data) { string Temp = null; string Result = null; //' long i; //' for (i = 1; i <= Data.Length; i += 2) { Temp = System.Convert.ToString(Strings.Chr((int) (Conversion.Val("&H" + Data.Substring((int) (i - 1), 2))))); Result = Result + Temp; } //' return … | |
Re: see this thread [URL="http://www.daniweb.com/forums/thread122450.html"]http://www.daniweb.com/forums/thread122450.html[/URL] | |
Re: First i want to say Welcome to Daniweb Friend. There is some links about module : - [URL="http://www.homeandlearn.co.uk/net/nets9p7.html"]http://www.homeandlearn.co.uk/net/nets9p7.html[/URL] - [URL="http://www.java2s.com/Tutorial/VB/0120__Class-Module/Catalog0120__Class-Module.htm"]http://www.java2s.com/Tutorial/VB/0120__Class-Module/Catalog0120__Class-Module.htm[/URL] | |
Re: i don't understand....what is line? | |
Re: Hi...Welcome to Daniweb Friend :) You can post your question in [URL="http://www.daniweb.com/forums/forum14.html"]Computer Science and Software Design[/URL] | |
Re: post your question on current section, this section just for introducing... | |
Re: Hi...Welcome to Daniweb Friend :) post your question in java section, this section just for introducing... | |
Re: Change DefaultLocation properties of Application Folder. you can set application installing path there. | |
Re: just copying a .mdb file to backup folder. | |
Re: so you want to play flash file (swf) in c# form. right? | |
Re: [code=vb] Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click If Year.Text < Now.Year Then MsgBox("Cannot input past year") ElseIf Year.Text = Now.Year Then If Trim(Month.Text) < Now.Month Then MsgBox("Cannot input past month") End If End If End Sub[/code] | |
The End.