Search:
Type: Posts; User: vbasicgirl
Search:
Search took 0.20 seconds.
-
Not looked at it fully from the point i am posting about but its a start
Shouldnt >>> decGrossPay = decOvtHours + cdecFullTime * decPayRate
Be >>> decGrossPay = decOvtPay + (cdecFullTime *...
-
Another option is to add to n before the loop then minus from n if the condition meets
If mB(i) = search(0) Then
n = n + 1
For j = 1 To search.Length - 1
If mB(i + j)...
-
Exit For will break from the current loop then back onto the other.
CAsey.
-
The very first thing is to find out if there is always some unique in the certain lines that hold these numbers. Is there ?
-
Cant you use the index value of the selectedindex ?
Casey.
-
You can loop through all your processes and check to see if it as a main window handle.
For Each proc As Process In Process.GetProcesses
If Not proc.MainWindowHandle.ToInt32 = 0...
-
You will need to create a class, inherit the listbox and create your own scroll event.
Public Class LBox
Inherits ListBox
Public Event Scroll(ByRef m As Message)
Private Const...
-
You need to have a couple of form scope variables, one holding the lines in an array and another as a counter to keep track of the lines when calling them in the timer.
Have a look at this simple...
-
You can use both by making use of the custom format property.
Casey.
-
You can add all the radiobuttons to the event in one go without typing a thing though, plus once its done, theres no loops at all.
Casey.
-
You could handle all the radiobuttons click event in one event and each time one is selected, set a string variable to the text of the radiobutton
Private RadioText As String
Private Sub...
-
Or use the LastIndexOf method.
Casey.
-
You could use the FindStringExact method as its not case sensitive.
Casey.
-
The Listview is not like the vb6 listview in many ways. If you look at Bulldogs post you will see that you need to set the listviewitem before adding to the listview plus, take notice how he adds the...
-
You are setting the listviewitem but you are not adding it to the listview. At the end of your code you need
Listview1.Items.Add(lvItem)
Casey.
-
Negative0 beat me to it.
Casey.
-
You would be better using a list of integer then sorting the list
Dim random As New Random
Dim result As New List(Of Integer)
For i As Integer = 1 To 7
...
-
You can use a combination of GetFirstCharIndexFromLine and SubString.
Casey.
-
You are not splitting the string anywhere, Shouldnt that be.
Dim mySplit() As String = _appointment.Body.Split(","c)
Casey.
-
How about changing the ShowUpDown property to true ?
Casey.
-
Im curious, Why have a datetimepicker then ?
Casey.
-
Its not as complicated as you may think. I have enclosed an example form, I have used the textfile format you supplied in post #3. I have also showed an example of a listview aswell as a textbox, you...
-
Another option for you because you are using the 3.5 framework(2008), is the orderby and orderbydescending methods which can sort a structure by any element of that structure. So, with your example...
-
What do you mean, it doesnt seem to be saving the values ?
Save them where ?, can you explain further.
Casey.
-
Have you set the variable x in Cstr(x) ?
Casey.
-
Try this instead
For Each ctrl As Control In CType(Me.Controls("GroupBox" & CStr(x)), GroupBox).Controls
Casey.
-
You could probably create a class or structure to hold both the text and the value, but if its a constant few items i would probably just have a seperate list of doubles to hold the values but in the...
-
This code will do what you need But, it only handles one open explorer. Get to grips with what the code actually does then see if you can come up with something to handle multiple open explorers.
...
-
Your welcome.
Just another note, because your lists are sorted, their is no need to use the binarysearch because if their are duplicates in the list then we know they will be side by side.
...
-
Try sorting the lists then use binarysearch. That should improve the speed.
Casey.
-
You are not adding to decTotalScore before adding to the listbox
If decInputScore > 0 Then
decTotalScore += decInputScore <<<<<<<added line
...
-
While you are using 2008, you have the option of using LINQ. I havnt done any testing on the speed of linq but maybe you could try this.
Dim ListFound = From s In yourarray _
...
-
This is a small example you could use to sort the dates, obviously you will need to fill the list first with the folder names by using io.directory.getdirectories.
Dim DateList As New List(Of...
-
Sounds like the focus is straight to one of the radiobuttons, try changing the tabindex if you have other controls on the form.
Casey.
-
Maybe another option would be to use Sendmessage with em_settabstops if you didnt want to use a fixed width font. If you search the site or google EM_SETTABSTOPS, you will find examples.
Casey.
-
Are you sure you have changed your font to a fixed width one ?
Casey.
-
balance = balance - withdrawal
txtNewBalance.Text = balance - withdrawal
You subtract it twice.
As another note, you should use tryparse when converting a string to a numerical variable.
...
-
If you dont want it to be longer than 30 aswell then you can use a combination of padright and substring
strname = strname.PadRight(30).Substring(0, 30)
Casey.
-
I am going to assume you want each line of the textfile adding to the listbox ?
ListBox1.Items.AddRange(IO.File.ReadAllLines("yourpath"))
Casey.
-
These two lines will now put each line of the textfile into a list. You can loop through that list then to deal with each line.
Dim Lines As New List(Of String)
...
|
Click Here to Expand Forum to Full Width
|