355 Posted Topics
Re: Hi, If you say the attempts is the same as gameplayed then you can change this part of code: [CODE]If attempts > 1 Then GamesPlayed = +1 TextBox1.Text = GamesPlayed End If[/CODE] into this: [CODE] If attempts = 5 Then MsgBox("You played 5 times!") Else attempts = attempts + 1 … | |
Re: Hi, You can Try something like this: [CODE]Dim result as integer result = (textbox1 * _Units) / _priceincur Textbox1.Text=Math.Round(result,4)[/CODE] I couldn't tested. | |
Re: Hi, @waynespangler, your code is working with mouseEnter and MouseLeave, but the OP wants to change the backcolor when Tabstop set the focus on the textbox. @Gopinathv Welkom to the Forum :icon_smile: | |
Re: Hi, You can try this: [CODE]Private Shared ds As DataSet[/CODE] | |
Re: Hi, I think the best way is to create an application in the most common resolution and that's 800x600. The raison for that is to handle smaller rsolutions and then resize it based on the screen object. You can try then this paart of code: [CODE]Dim h, w As Integer … | |
Re: Hi kitjo, The application you made isn't that for a Mobile devices and you want to use it into PC? | |
Re: Hi, You can find an example, [URL="http://www.nerdydork.com/crop-an-image-bitmap-in-c-or-vbnet.html"]here.[/URL] | |
Re: Hi, How did you do the export format? Can you show us your codes? You can find some explanation, [URL="http://www.codeproject.com/KB/vb/JatsArticle1.aspx"]here.[/URL] | |
Re: Hi, Did you tryed to rename it again to the original name. | |
Re: Hi, I think the upgrade wizard doesn't work because of the complexity of your VB6 application. (74 forms) What you could try is to use the wizard form by form and then build the application all together in VB.Net. That said, when the wizard is working it's not always the … | |
Re: [QUOTE=ashley11;1574657]i have a radio button and a text box. when i select the radio button, then will come out the text box to let user fill in. may i know to show the text box? below are my coding. [CODE] Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) … | |
Re: Hi, You can find some explanation, [URL="http://msdn.microsoft.com/en-us/library/wx3b589t.aspx"]here.[/URL] And a walkthrough, [URL="http://msdn.microsoft.com/en-us/library/bb458038.aspx"]here.[/URL] | |
Re: Hi, To read a TextFile into a ListBox you can do it like this: [CODE]// Load the ListBox from a file. private void Form1_Load(System.Object sender, System.EventArgs e) { try { string file_name = DataFile(); System.IO.StreamReader stream_reader = new System.IO.StreamReader(file_name); ListBox1.Items.AddRange(Strings.Split(stream_reader.ReadToEnd(), Constants.vbCrLf)); ListBox1.SelectedIndex = 0; stream_reader.Close(); } catch (Exception exc) { … | |
Re: Hi, What you also can do is useDES Algorithm. For more explanation, look [URL="http://www.vb-helper.com/howto_net_des_file.html"]here.[/URL] See also [URL="http://www.daniweb.com/software-development/vbnet/code/366392"]this[/URL] thread. | |
Re: Hi, You can try something like this: [CODE] ListBox1.Items.Add("Balnce: " & amount). ToString("0.00")[/CODE] | |
Re: Hi, You said it's not working. Perhaps a little more explanation like: what errors do you have? ... | |
Re: Hi, You can drag and drop items in a Listview. For more information, look [URL="http://vbcity.com/forums/t/87003.aspx"]here.[/URL] | |
Re: [QUOTE=Sevyt;1564189]Was wondering, is it possible to create a class which has the majority of your keypress controls? Like allowing just letters or numbers in a textbox etc.... To make things clearer what i exactly want. I have a textbox on my form. This is a textbox for the postcode. The … | |
Re: Hi, Try this: [CODE]conn.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=D:\G-project Crab\GP\GP\Database1-2.mdb" conn.Open()[/CODE] | |
Re: Hi, You can find a tutorial how to create a database[URL="http://www.sourcecodester.com/tutorials/net/database-programming-made-easy.html"]here.[/URL] It shows you also the differance between Access and SQL Server Express. | |
Re: [QUOTE=wenbnet;1566490]i created loan table, and i m fetching loan amount of each employee in a label to see d actual loan amount then i have one text box where user will insert amount and remaining amount on deduction come in another label as balance amount.[/QUOTE] Hi wenbnet, You have a … | |
Re: Hi, For your first question. It's working normal because you put it in the Timer Event. That means every second the timer execute you'll have an item added into the Listbox. What you can do is change the timer interval to the executiontime you need or put it into a … | |
Re: Hi, Here's a small example how to draw a line on a panel and to clean the panel: [CODE] Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Dim redPen As Pen = New Pen(Color.Red, 2) Dim point1 As Point = New Point(10, 10) Dim point2 As … | |
Re: Hi, To export a Crystal Report to PDF. You can find some information, [URL="http://vb.net-informations.com/crystal-report/vb.net_crystal_report_export_pdf.htm"]here.[/URL] To send an Email, try this: [CODE]Dim mail As New MailMessage() mail.To = "me@mycompany.com" mail.From = "you@yourcompany.com" mail.Subject = "this is a test email." mail.Body = "this is my test email body." Dim attachment As New … | |
Re: Hi, You can try it like this: [CODE] Private Sub ListView1_SelectedIndexChanged(ByVal sender As Object, ByVal e As System.EventArgs) Handles ListView1.SelectedIndexChanged Dim SelectedItems As ListView.SelectedListViewItemCollection = _ CType(sender, ListView).SelectedItems If (SelectedItems.Count > 0) Then Label1.Text = ListView1.SelectedItems(0).SubItems(0).Text End If End Sub[/CODE] | |
Re: Hi, I sould not use a Monthcalendar for this, but 2 Datetimepickers. I made you a small example how I should do the calculation. [CODE]private void Button1_Click(System.Object sender, System.EventArgs e) { System.DateTime d1 = DateTimePicker1.Value; System.DateTime d2 = DateTimePicker2.Value; TimeSpan ts = default(TimeSpan); ts = d2.Subtract(d1); if (!(ts.Days > 0)) … | |
Re: Hi, You can find some information how to create a crystal report with VB.Net, [URL="http://developer.emc.com/developer/downloads/CrystalReport_ADO_Dataset.pdf"]here.[/URL] | |
Re: Hi, You can try something like this: [CODE] Dim value As Long value = Convert.ToInt64(CardNo) Dim CNo As String = value.ToString("X") CNo.padleft(6, "0")[/CODE] I didn't tested it. | |
Re: Hi, Here's a way how to print the contents of a Label and TextBoxes. For example add two labels to a panel and name them Students Name and Fathers Name. Next to the Labels add two Textboxes where you can write the contents. Then add two buttons and a PrintPreviewDialog … | |
Re: Hi, You need to iterate through the DataGridView rows and for each row, cast the cell in the column of interest to DataGridViewCheckBoxCell and cast the Value to a bool. | |
Re: Hi, You can find some information about how to add an Image/Loge into a Crystal Report, [URL="http://www.c-sharpcorner.com/UploadFile/saj/CrystalReports03192006090510AM/CrystalReports.aspx"]here.[/URL] | |
Re: Hi, You can find some good tutorials about programming VB 2010, [URL="http://www.visual-basic-tutorials.com/"]here.[/URL] Those tutorials have a lot of explanation and code samples, etxc... Then last but not least, you can learn from all threads in this Forum. Ask a questions about programming and you'll get some answers. | |
Re: Hi, If you want to open the Ieplore.exe in your application. You have to do it with Process.Start method. | |
Re: Hi, You can find some explanation ans example, [URL="http://www.linglom.com/2010/05/27/creating-graph-with-vb-net-part-3-data-binding-chart-to-database/"]here[/URL] to create a bar graph binded to a database. | |
Re: Hi, You can find some information, [URL="http://msdn.microsoft.com/en-us/library/ms227476(v=vs.80).aspx"]here.[/URL] | |
Re: Hi, I thin you can find some information, [URL="http://www.xtremevbtalk.com/showthread.php?t=160459"]here.[/URL] | |
Re: Hi, I think you should do it this way. Add this part of code into a Button Click event: [CODE]If Me.WebBrowser1.DocumentText.Contains("Login") Then MsgBox("The login is ok!") End If[/CODE] | |
Re: Hi, Did you actually include your database in your project or just reference it from the config file? If you add the database the database (right click your project in the project explorer and select "Add existing item..." and go find your database. | |
| |
Re: Hi, You should use the Datagridview CellValidating event for this, because this event is fired when the user is done with the typing and leaves the cell. You can find some information, [URL="http://msdn.microsoft.com/en-us/library/system.windows.forms.datagridview.cellvalidating.aspx"]here.[/URL] | |
Re: Hi, You can try something like this: [CODE]Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click If DateTimePicker1.Value > DateTimePicker2.Value Then MsgBox("Wrong Date") Else MsgBox("Good Date") End If End Sub[/CODE] | |
Re: Hi, Here's something I made with numbers. [CODE]Private Sub Digit_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles bttn1.Click, bttn2.Click, bttn3.Click, _ bttn4.Click, bttn5.Click, bttn6.Click, bttn7.Click, bttn8.Click, bttn9.Click, bttn0.Click lblDisplay.Text = lblDisplay.Text + sender.Text End Sub[/CODE] Like you can see it's for numbers. Add ten buttons and name them like … | |
Re: Hi, What do you have so far? | |
Re: Hi, You can find a complete database with several buttons to navigate into a database. Even with the whole explanation. Look [URL="http://www.homeandlearn.co.uk/NET/nets12p4.html"]here[/URL]. | |
Re: [QUOTE=christos312;1547167]Hello to everyone, I have a program that gets some information from the user and updates the database. I also have two DataGridView, [B]OpenOrders[/B] and [B]ItemsInOrder[/B] When the user click on a cell in the [B]OpenOrders[/B] a [I]CellChange[/I] event is triggered and it updates the [B]ItemsInOrder[/B] grid view... Now after … | |
Re: Hi, You can find New Languages via New Project -> Open Other Languages. | |
Re: Hi, You can try this: [CODE]Dim i As Integer For i = 0 To Products.Length – 1 Products(i).Qty = 0 Next[/CODE] And: [CODE]Dim textfile As StreamWriter textfile = File.CreateText(FileName(OrderDate)) Dim i As Integer For i = 0 To Products.Length – 1 If Products(i).Qty > 0 Then textfile.WriteLine(Products(i).UPC) textfile.WriteLine(Products(i).Qty) End If … |
The End.