279 Posted Topics
Re: You only show a part of the sub. What does the rest of it look like? | |
Re: You need to take "Dim intSum As Integer = 0" out of the button click event, otherwise you always set it back to 0. | |
Re: @xuexue: If the loop only executes one time just see how often it executes if you put: For k = 0 To 4. If this works then there is something wrong with recno.Length. @Mr.M 1) For k = 0 to recno.Tostring how is this supposed to work? | |
Re: It is not very hard if you use regex. Not knowing if you have three textboxes or one, here is some code using one textbox and three radiobuttons to change validation of the input in textbox1. Imports System.Text.RegularExpressions Public Class Form1 Private Sub Form1_Load(sender As Object, e As EventArgs) Handles … | |
Re: You need to check which framework verions are installed on boths machines, and check for which cpu you have compiled your program. For the first part follow these instructions: http://www.tech-recipes.com/rx/2959/what_version_net_framework_are_installed_pc/ for the second part you need to click on my project in solution explorer and go to the compile option. | |
Re: You might want to try this: Public Class Form1 Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load Dim Seatimage As New Windows.Forms.PictureBox Seatimage.AutoSize = True PictureBox1.Image = Image.FromFile(System.IO.Path.Combine("C:\Users\Harley\Desktop\Untitled.png")) Seatimage.TabIndex = 4 End Sub End Class | |
Re: I do think your logic is flawed. What happened if the third number is the same as the second and so on? You only test against the first. | |
Re: strTotal = Format(dblTotal.ToString("N")) and please read this: http://msdn.microsoft.com/en-us/library/dwhawy9k(v=vs.110).aspx#NFormatString | |
Re: Check this one out. http://stackoverflow.com/questions/1404731/how-to-get-current-cpu-and-ram-usage-in-vb-6 | |
Re: First off if you don't want to allow 0 to be generated you need to use this: Dim value As Integer = CInt(Int((76 * Rnd()) + 1)). Here is what I would do: Grab the numbers from the user,leave these in the textboxes but also copy them into an array … | |
Re: O.K. just a couple of points. A) The program you want to send a key combinations to need to be programmed to accept this combination. B) Windows always intercepts key presses and somewhat redirects these if the program you want to send these to doesn't accept these. So here is … | |
Re: O.K there are2ways of doing this. 1) create form 2 with exactly the same dimensions as form1 e.g. form2.width = form1.width etc. and in the same position, get thcoordianates of the mouse click and tranfer these to form1. 2) Use percentages to work out the distance from the top of … | |
Re: You need to catch the close event like: Private Sub Form1_FormClosing(sender As Object, e As FormClosingEventArgs) _ Handles Me.FormClosing If e.CloseReason = CloseReason.UserClosing Then e.Cancel = True MsgBox("CLosing") Me.Hide() End If End Sub | |
Re: O.K. You need to use a monospaced font which assigns each letter, number the same space, so an i would take up the same space as a w. Than you use the Rset function, where the number indecates how much you move your items to the right- depends on the … | |
Re: That is one way of doing it not knowing what you want to achieve: Dim array1(5) As Integer Dim array2(10) As Integer 'array2 is filled like(1,2,3,4,5,1,2,3,4,5} Private Sub Form_Load() Dim i, j As Integer For i = 1 To 5 array1(i) = i Next i For j = 1 To … | |
Re: You are mixing up doubles and integers, also use val(me.text1) etc. like: Option Compare Database Dim number1 As Double Dim number2 As Double Private Sub cmd1_Click() MsgBox "The largest number is " & FindLargestNumber(val(Me.text1), val(Me.text2)) End Sub Public Function FindLargestNumber(number1, number2) As Double If number1 > number2 Then FindLargestNumber = … | |
Re: Please check out this link: [Click Here](http://msdn.microsoft.com/nb-no/vbrun/ms788708(en-us).aspx) | |
Re: I don't think you will find a lot of code performing heuristic analysis. The reason is that this is used by anti virus companies, patented and copy righted. See the link here: http://www.google.nl/patents/US7480683 There are some other articels that might interest you as well: http://www.symantec.com/connect/articles/building-anti-virus-engine With this one coming sort … | |
Re: Your first check should be to see if the matrix is square or not because only square matrices can also be diagonal matrices. Once you have determined that the matrix is square you than can start iterating through the elements to see if they are of value 0 or not. … | |
Re: So this is what you can do: Declare 6 Integer variables like: hour1,min1,sec1 and three more Integer varaibles hour2,min2,sec2. Take your first string from your text. Split it into three parts and convert these to Integers and store these in your first three Integers. Grab the next text, do the … | |
Re: You will find an example with explanations here: http://support.microsoft.com/kb/118377 | |
Re: O.K. You can't just have one button to do the backup and restore at the same time. This doesn't make sense. So you need either 2 buttons, one to backup and one to restore or set a flag with a radiobutton or something else. OK. this what I do: At … | |
Re: Private Sub Command1_Click() Picture1.Line (200, 0)-(200, Picture1.Height), vbBlue Picture1.Line (500, 0)-(500, Picture1.Height), vbBlack End Sub Private Sub Form_Load() Picture1.DrawWidth = 5 End Sub | |
Re: O.K I didn't undestand what your code is doing, considering what you want to achieve. So I whipped up a small program to do more or less what you waanted initiallyb but there is still more work to do. Since I have not yout file I just created the list. … | |
Re: http://www.vbtutes.com/2013/01/vb6-source-code.html | |
Re: Did you install all the sevice packs for vb6? http://www.microsoft.com/en-us/download/details.aspx?id=5721 Also check this website for answers. | |
| |
Re: You do need to learn the syntax of the net framework. Here is good start of how to handle the combobox methods: http://msdn.microsoft.com/en-us/library/system.windows.forms.combobox(v=vs.110).aspx | |
Re: Static x As Integer = 100 or whatever | |
Re: Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click Dim intSum As Integer = 0 Dim Int1 As Integer = CInt(NumericUpDown1.Value) Dim Int2 As Integer = CInt(NumericUpDown2.Value) TextBox1.Text = CStr((Int1) + (Int2)) End Sub | |
Re: check this info out. At the bottom is an example of how to use the toolstriptextbox: http://msdn.microsoft.com/en-us/library/system.windows.forms.toolstriptextbox(v=vs.110).aspx | |
Re: This might be what you are looking for: http://vbcity.com/forums/t/103763.aspx | |
| |
Re: Only glancing at it, you declared your variables as string but then try to do some calculation with these in line 8. Need to change into some number type, int, long ? | |
Re: O.K I assume you need to put some of your code into a button event which becomes your pull. In ther you need a counter to count the number of pulls. You also need to initialize your number of tokens as: Dim number as Integer = 100 which is the … | |
Re: The LWin and RWin keys are modifier keys with some extra functionallity. It is easier to use the Alt or Control keys. Private Sub TextBox1_KeyDown(sender As Object, e As KeyEventArgs) Handles TextBox1.KeyDown If (e.Modifiers = Keys.Control AndAlso e.KeyCode = Keys.Z) = True Then Me.BackColor = Color.Blue End If End Sub … | |
Re: Do check this out: http://www.vbforums.com/showthread.php?654846-ZoomPictureBox-picture-control-with-mouse-centred-zooming | |
Re: Its not really clear if you want 1 var or 3 var.You always can put them into an array: arr1(6) as string =New String(){"200","100"......} and so on | |
Re: What is the event you want to use to move the data? Keypress? Buttonclick? Why do you want to move data into an array before moving it into a listbox? What code do you have sofar? | |
Re: Why don't you use datedifference function? http://msdn.microsoft.com/en-us/library/b5xbyt6f(v=vs.90).aspx | |
Re: This link might be useful to you as it shows you the steps to take. http://www.timesheetsmts.com/adotutorial.htm | |
Re: Maybe this is what you want? Dim x As Integer = PictureBox1.Width Dim y As Integer = PictureBox1.Height Dim bm As New Bitmap(x, y) PictureBox1.DrawToBitmap(bm, New Rectangle(0, 0, x, y)) PictureBox2.Image = bm | |
Re: You have set your object in a subso the scope only works in the sub. Do the same in the othe sub or declare the object on top of yxour code. | |
Re: The problem lies with you assigning the currentRow to items.count. You need to find the currentRow based on some criteria - this is only pseudo: dim intCount ,i as Integer intCount=.....Row.count for i = 0 to intCount-1 if ...text= ..Row(i).items.text then currentRow=...Row(i) next So basically you need to find the … | |
Re: Just reading up on it the problem might be with directx. Find out which version is running on the computer you want to run the game. | |
Re: xlTmp.Workbooks.open ("app.path & \kundreg\bokfaktura2.xls") 'don't work should be: xlTmp.Workbooks.open ("app.path" & "\kundreg\bokfaktura2.xls") 'don't work | |
Re: Maybe this link helps, struggle myself with the listview code: http://social.msdn.microsoft.com/Forums/en-US/292ac5c0-a06b-4a77-be52-8ca3282e2edf/loop-through-listview-getting-items-and-sub-items?forum=vbgeneral | |
Re: My 2 last posts didn't display so I try again. Just insrt my code into a new project and play around with the labels. Imports System.Drawing.Color Public Class Form1 Inherits System.Windows.Forms.Form Private Sub Form1_Load(sender As Object, e As EventArgs) Handles MyBase.Load End Sub Private Sub Button3_Click(sender As Object, e As … | |
Re: Private Sub byteTest() Dim inquirybyyearmonthday(20) As Byte End Sub Do you get an error if you use it like this? I didn't get the extra brackets. | |
Re: You can use something like this: Private Sub TextBox1_KeyDown(sender As Object, e As KeyEventArgs) Handles TextBox1.KeyDown If e.KeyCode = Keys.Enter Then TextBox2.Focus() End If End Sub |
The End.