Search:

Type: Posts; User: vbasicgirl

Page 1 of 13 1 2 3 4

Search: Search took 0.20 seconds.

  1. Replies
    2
    Views
    1,186

    Re: My calculations aren't working

    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 *...
  2. VS 2008 Re: [RESOLVED] For..Next loop in a For...Next loop

    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)...
  3. VS 2008 Re: For..Next loop in a For...Next loop

    Exit For will break from the current loop then back onto the other.

    CAsey.
  4. VS 2010 Re: pulling from a very very specific location imbedded in a test file

    The very first thing is to find out if there is always some unique in the certain lines that hold these numbers. Is there ?
  5. Replies
    6
    Views
    647

    VS 2008 Re: Need help with setting Listbox Values

    Cant you use the index value of the selectedindex ?

    Casey.
  6. VS 2008 Re: Getting a list of all windows handlers using the EnumWindows API

    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...
  7. VS 2008 Re: Scroll multiple listboxes simultaneously

    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...
  8. Replies
    7
    Views
    901

    VS 2008 Re: Textbox line by line

    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...
  9. Replies
    9
    Views
    842

    Re: [2005] Date AND Time Picker

    You can use both by making use of the custom format property.

    Casey.
  10. Re: [RESOLVED] [2008] For Next with RadioButton

    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.
  11. Re: [RESOLVED] [2008] For Next with RadioButton

    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...
  12. Replies
    12
    Views
    1,316

    Re: [2008] Parsing text file, need some help

    Or use the LastIndexOf method.

    Casey.
  13. Re: Listbox Item Exist validation......ignore case?

    You could use the FindStringExact method as its not case sensitive.

    Casey.
  14. Re: Loading Listview Problems.........

    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...
  15. Re: Loading Listview Problems.........

    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.
  16. Re: [2008] How to arrange numbers from smallest to biggest?

    Negative0 beat me to it.

    Casey.
  17. Re: [2008] How to arrange numbers from smallest to biggest?

    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
    ...
  18. Replies
    6
    Views
    895

    Re: Multiline textbox?

    You can use a combination of GetFirstCharIndexFromLine and SubString.

    Casey.
  19. Re: [2008] Using split method and getting error

    You are not splitting the string anywhere, Shouldnt that be.


    Dim mySplit() As String = _appointment.Body.Split(","c)


    Casey.
  20. Re: Stop DateTimePicker from showing calendar

    How about changing the ShowUpDown property to true ?

    Casey.
  21. Re: Stop DateTimePicker from showing calendar

    Im curious, Why have a datetimepicker then ?

    Casey.
  22. Re: [2008] Sorting a list within a form by name

    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...
  23. Re: [2008] Sorting a list within a form by name

    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...
  24. Replies
    10
    Views
    1,183

    Re: [2008] Combo Box's

    What do you mean, it doesnt seem to be saving the values ?

    Save them where ?, can you explain further.

    Casey.
  25. Replies
    14
    Views
    1,940

    Re: [2005] CallByName question

    Have you set the variable x in Cstr(x) ?

    Casey.
  26. Replies
    14
    Views
    1,940

    Re: [2005] CallByName question

    Try this instead


    For Each ctrl As Control In CType(Me.Controls("GroupBox" & CStr(x)), GroupBox).Controls


    Casey.
  27. Replies
    10
    Views
    1,183

    Re: [2008] Combo Box's

    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...
  28. Replies
    4
    Views
    799

    Re: [2008] Process watch

    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.
    ...
  29. Replies
    3
    Views
    621

    Re: [RESOLVED] [2005] Comparing lists

    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.
    ...
  30. Replies
    3
    Views
    621

    Re: [2005] Comparing lists

    Try sorting the lists then use binarysearch. That should improve the speed.

    Casey.
  31. Re: List Box Help, Displaying A Football Score.

    You are not adding to decTotalScore before adding to the listbox


    If decInputScore > 0 Then

    decTotalScore += decInputScore <<<<<<<added line

    ...
  32. Re: [2008] How do I search quickly in an array?

    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 _
    ...
  33. Re: [2008] Sorting listbox data from External source

    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...
  34. Re: Radio Button Selected when I use ShowDialog

    Sounds like the focus is straight to one of the radiobuttons, try changing the tabindex if you have other controls on the form.

    Casey.
  35. Replies
    10
    Views
    1,124

    Re: Fixed Length String

    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.
  36. Replies
    10
    Views
    1,124

    Re: Fixed Length String

    Are you sure you have changed your font to a fixed width one ?


    Casey.
  37. Re: [2008] If/then statements not displaying results correctly

    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.

    ...
  38. Replies
    10
    Views
    1,124

    Re: Fixed Length String

    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.
  39. Re: [2005] cannot converted to system.text.encoding

    I am going to assume you want each line of the textfile adding to the listbox ?


    ListBox1.Items.AddRange(IO.File.ReadAllLines("yourpath"))


    Casey.
  40. Replies
    11
    Views
    968

    Re: [2008] TXT File

    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)

    ...
Results 1 to 40 of 500
Page 1 of 13 1 2 3 4



Click Here to Expand Forum to Full Width