Search:

Type: Posts; User: jmcilhinney

Page 1 of 13 1 2 3 4

Search: Search took 0.53 seconds.

  1. Replies
    13
    Views
    203

    VS 2019 Re: TabControl add controls from text file

    Let's think about the logic first and then write code to implement that logic, rather than writing code with no real idea what it's supposed to do.

    You have a file that contains multiple lines and...
  2. Replies
    1
    Views
    76

    VS 2019 Re: Simplify or filter data

    You would use multiple DataViews for this. Every DataTable has a DefaultView and that is where the data comes from when you bind the DataTable itself. If you want multiple views of the same data...
  3. Replies
    13
    Views
    203

    VS 2019 Re: TabControl add controls from text file

    What have you done and where are you stuck? Surely you can get a list of files from a folder, but I don't see any evidence of that. Can you read the contents of a file? You've asked multiple...
  4. Replies
    5
    Views
    213

    Re: Where are my dots ?

    If you were going to do that then it would make more sense to take out everything that wasn't specifically for the number. In fact, I wouldn't call ToString on the number there in the first place. If...
  5. VS 2010 Re: X close button not closing the Form (hangs)

    For the record, you can import a class but, as for a namespace, the point is to use its members unqualified. If you import the System.Threading.Tasks.Task class then you would use its Run method...
  6. VS 2010 Re: X close button not closing the Form (hangs)

    Do you understand what an Imports statement actually does? It appears not and you're just throwing stuff at the wall. The point of an Imports statement is to allow you to use the members of what you...
  7. VS 2010 Re: X close button not closing the Form (hangs)

    Why are you importing a class and not the namespace the class is a member of? Also, are you targeting .NET Framework or .NET Core? If the former, are you targeting at least version 4.0, because...
  8. VS 2019 Re: Datagridview values create folder names

    Put some thought into it. This is your application, not ours. If you are going to use a loop to get the data from the grid into a list and then use another loop to get the data from the list to...
  9. VS 2019 Re: Datagridview values create folder names

    So are you able to populate the list with the data you want or not?
  10. VS 2019 Re: Datagridview values create folder names

    What's wrong with using a loop? Don't try to copy LINq code that you don't understand. Presumably you know the baqsics of writing a loop. Put some thought into the logic instead of expecting to find...
  11. VS 2019 Re: Datagridview values create folder names

    You're asking multiple unrelated questions here. Stick to one thing at a time. Getting data from a DataGridView is the same no matter what you want to do with it, so creating folders is irrelevant to...
  12. Replies
    5
    Views
    200

    VS 2022 Re: Searching Form for label text

    Your explanation is too vague. If you're looking for text then you're goinmg to be comparing Strings. Comparing a String is the same no matter where it comes from, so you can find out how to do that...
  13. Replies
    3
    Views
    166

    VS 2017 Re: Unable to run exe program

    What do those applications do at startup? What framework are they targeting?
  14. Replies
    5
    Views
    213

    Re: Where are my dots ?

    I just opened the documentation for the Int32.ToString method that you're using. A couple of links later, I was reading the information specifically relevant to this question.
    ...
  15. VS 2019 Re: Problem Writing to Multi-Line Textbox and Streamwriter at Same Time

    OptionBase1 is correct. You could call AppendText on the TextBox but there would be little point because you wouldn't see the result until the end anyway, and it would slow things down. Using the...
  16. VS 2019 Re: Problem Writing to Multi-Line Textbox and Streamwriter at Same Time

    That's because you keep setting the Text property over and over, thus replacing the existing value. You should be calling the AppendText method.
  17. Replies
    5
    Views
    174

    Re: there is no row at position error

    Also, I'm not sure if maybe you have changed the code to simplify things for this thread but, if it's what you're actually using, this part is ridiculous:

    Select Case True
    Case LoadForm =...
  18. Replies
    5
    Views
    174

    Re: there is no row at position error

    I repeat:

    At a quick glance, I don't see anywhere in the code you actually posted that that exception could be thrown. We shouldn't have to spend our time trying to work out stuff that you already...
  19. Replies
    5
    Views
    174

    Re: there is no row at position error

    Perhaps you could actually tell us where in this extensive code the exception is thrown. Regardless, if you want to perform an action only if a condition is true then you use an If statement for that.
  20. Re: how to make a picturebox click fire a keypress event

    Nope. That's bad. What's the point of passing a hard-coded value into a method that then checks that value? Get rid of the parameter and the If statement. Put the If statement in the KeyPress event...
  21. Replies
    2
    Views
    169

    VS 2022 Re: UWP App how to save Data

    Given that VB and C# use all the same types with all the same members, there's no reason that you should have absolutely no clue if you've found C# examples. Unless it uses advanced features, reading...
  22. VS 2010 Re: X close button not closing the Form (hangs)

    The Invoke method is synchronous, i.e. it doesn't return until the invoked method does. BeginInvoke is asynchronous, i.e. it returns immediately, not waiting for the invoked method to complete. I...
  23. Re: Why there is Parentheses at the end of the List in C#

    You know how to call methods in C#, right? A constructor is basically just a method. Do you use parentheses when calling any other method? Yes you do, so why would you not when calling a constructor?...
  24. Re: How to delete consecutive blank lines in richtextbox

    You're assuming something that the OP didn't specify. Maybe you're right but the OP said "empty lines" and a line containing whitespace is not empty. Regardless, the logic is still the same so they...
  25. Replies
    6
    Views
    266

    Re: vb.net Issue with dbnull

    Unfortunately, Option Strict Off is the default and most tutorials and many courses don't mention it until fairly late on or even not at all. That default does make it easier for beginners to get...
  26. Re: How to delete consecutive blank lines in richtextbox

    Dim lines = myRichTextBox.Lines.ToList()

    'Loop backwards so that removing a line will not affect the index of the lines still to be processed.
    For i = lines.Count - 1 To 1 Step -1
    If...
  27. Re: Why there is Parentheses at the end of the List in C#

    That would be an object initialiser. When you use an object initialiser along with a parameterless constructor, you can include the parentheses or omit them.
  28. Re: Why there is Parentheses at the end of the List in C#

    What exactly do you not understand about this?
  29. Replies
    6
    Views
    266

    Re: vb.net Issue with dbnull

    As suggested, the main issue is that you're comparing the cell itself, rather than the Value of the cell. Even with that fix, you can still improve the structure of the code. Don't use the IsDBNull...
  30. VS 2010 Re: X close button not closing the Form (hangs)

    Get rid of the Application.Exit call too. If this is your startup form then closing it will exit the app anyway, so calling Application.Exit is also pointless and possibly doing so could cause the...
  31. VS 2010 Re: X close button not closing the Form (hangs)

    Firstly, why are you calling Application.Exit and then using End? Never use End at all but, if you were going to, calling Application.Exit first would be pointless. The point of Application.Exit is...
  32. Re: Copying/Installing font used in WinForm project

    I have no idea what that means.

    The page you linked to provides an actual example. What don't you understand? You load fonts from files into the collection, you create a Font, you use it. What's...
  33. Replies
    1
    Views
    231

    Re: Internal GPS

    There are some NuGet packages related to GPS so that's probably a good place to start.
  34. Re: Should I use a Class or a Structure, (Matrix Tool)

    Structures are value types but arrays are classes and therefore reference types. Copying a structure that contains an array will not copy the array; only the reference to the array. If you then...
  35. VS 2022 Re: Random String Function returns same result

    The issue is as Shaggy says. NEVER create a Random object in a method. You should most likely use a Shared field, so even different instances of the same type will use the same Random object.

    This...
  36. Re: Copying/Installing font used in WinForm project

    I've never done it myself but I think that you need to use the PrivateFontCollection class. This allows your app to use fonts that it supplies rather than having them installed in Windows.
  37. Re: A database project thoughts & basic questions

    No reason it shouldn't.

    VS 2022 Community Edition.
  38. Re: Trying to Stop a service and restart a different service in VB

    If your issue is resolved, please use the Thread Tools menu to mark the thread Resolved, so we can all see without opening the thread and reading the whole thing.
  39. Re: How to invoke the MouseMove event after clicking on a button

    I use CheckBoxes plenty too. I even said that using a CheckBox in this case was the proper solution. The OP is already using a Button so using a CheckBox with the Appearance set to Button will retain...
  40. VS 2022 Re: Grammar/ Spell Checker for RichTextBox in VB.NET 6.0/ VS 2022

    Are you saying that you want an existing component or you want to implement it yourself? If the latter then you can underline text in a RichTextBox by selecting the appropriate text and then setting...
Results 1 to 40 of 500
Page 1 of 13 1 2 3 4



Click Here to Expand Forum to Full Width