Search Results - VBForums

Search:

Type: Posts; User: dbasnett

Page 1 of 13 1 2 3 4

Search: Search took 0.13 seconds.

  1. Replies
    7
    Views
    265

    VS 2013 Re: Ping ASYNC Accuracy issue

    Show your code as it is now.
  2. Re: How to reference multinumber string?

    In the error message what was Null?
  3. Re: How to reference multinumber string?

    You can reference a control by name.


    For x As Integer = 1 To 10
    OtherForm.Controls("Flav" & x.ToString).Text = "test"
    Next
  4. Replies
    7
    Views
    219

    VS 2013 Re: Number of elements to array

    This might help:

    Dim MyResult As List(Of Object)
    MyResult = SNMPresponse.Pdu().Variables.ToList
    ItemCount = MyResult.Count
  5. Replies
    26
    Views
    589

    VS 2010 Re: Space Key

    Please mark thread resolved.
  6. Re: VB.Net printing. How to print a line on the last page of a 8 1/2 by 11 page

    Make the form larger and move the textbox to the bottom. See if that makes a difference.
  7. Re: VB.Net printing. How to print a line on the last page of a 8 1/2 by 11 page

    Did you try the change I proposed?
  8. Re: VB.Net printing. How to print a line on the last page of a 8 1/2 by 11 page

    Assuming the string value you want to print is positioned correctly on the Form but is scrolled out of view this might help


    pf.PrinterSettings.Copies = 2
    ...
  9. Replies
    11
    Views
    232

    Re: Select case - is this right?

    One other thing. num is an integer so Case "" can't be true. If this statement compiles you should turn Option Strict on.
  10. Re: Need help with removing multiple carriage returns

    Are you trying to replace multiple CR / LF with a single NewLine or replace all CR / LF with some other char?
    This will replace multiples with a single:

    Dim Sentence As String
    ...
  11. Replies
    26
    Views
    589

    VS 2010 Re: Space Key

    Is this a Forms or Console app?

    pseudo code:


    if bug_on_monitor and dday9_post then
    ignore
    else
    shoo_fly
    endif
  12. Replies
    26
    Views
    589

    VS 2010 Re: Space Key

    How about something like this:

    Dim Sentence As String
    Dim Words As Integer
    Dim LengthSentence As Integer

    Console.WriteLine("Please Enter A Sentence")
    ...
  13. Replies
    17
    Views
    399

    Re: SerialPort data corruption

    If you have a hardware loopback take a look at my signature for code related to serial ports.
  14. Replies
    17
    Views
    399

    Re: SerialPort data corruption

    Show the code that contains both ports. Also, turn DTR on.
  15. Replies
    17
    Views
    399

    Re: SerialPort data corruption

    Is the terminal program capable of displaying raw bytes, and sending raw bytes? You are sending ETX,ETX,STX,NUL,-,SOH,
  16. Replies
    17
    Views
    399

    Re: SerialPort data corruption

    I only see one port in your program and it is sending and receiving. Do you have a null modem or a loopback?
  17. Replies
    3
    Views
    179

    VS 2012 Re: Customize Solution Exporer buttons order

    Have you tried making the Solution Explorer window wider? It works for me.
  18. Replies
    8
    Views
    242

    VS 2013 Re: Decimal Result of Two Textboxes Help

    I agree with John's approach. What should happen if the input is '10.'?


    Dim num As Decimal

    If Decimal.TryParse(txtDivThis.Text.TrimEnd, num) AndAlso num <= 100D Then
    ...
  19. Replies
    30
    Views
    769

    VS 2013 Re: Shutdown system super fast?

    Great questions.
  20. VS 2012 Re: How to make a update for my software but load old settings

    Take a look at these and then at the code I provided.

    https://msdn.microsoft.com/en-us/library/vstudio/saa62613%28v=vs.100%29.aspx
    ...
  21. VS 2012 Re: How to make a update for my software but load old settings

    If you are using My.Settings create a new Boolean setting, name it NeedUpgrade or something similar and set it to True.

    In the form Load or Shown event do the following:


    If...
  22. Replies
    5
    Views
    248

    Re: Controls - How much do they cover?

    Here is an example using two buttons. The example is from the perspective of button1.

    'assumes that button1's overlap with button2
    'is what is being looked for

    Dim r...
  23. Replies
    2
    Views
    173

    VS 2012 Re: Calling Byval value as Char function

    It will have to be called like this

    Task5("s"c)
  24. VS 2013 Re: Method for conversion, can it be improved?

    <Flags> _
    Enum Unit As Integer
    Undefined = 0
    SI = 1 << 1
    US = 1 << 2
    BothSIAndUS = Unit.SI Or Unit.US
    End Enum

    Private Sub UnitDecode(aUnit As...
  25. Replies
    11
    Views
    263

    Re: Cannot print chr(34)

    It worked for me:
    ?Chr(34)
    """c

    What version of .Net are you using?
  26. Thread: color dailog

    by dbasnett
    Replies
    1
    Views
    170

    Re: color dailog

    You can store the color as an integer using Color.ToArgb and then use Color.FromArgb once the integer value has been retrieved.


    Dim acolor As Color = Color.AliceBlue

    Dim...
  27. Re: Contest 8 - Roman Numeral Converter - Discussion Thread

    Why not just change the rules to only 1 - 3999?
  28. VS 2008 Re: Calculating All IP Addresses in a Range (Pretty Good Start)

    FWIW - if you are working with IPv4 addresses you can treat the ip address as a number.


    ''' <summary>
    ''' converts a Net.IPAddress to an Integer
    ''' </summary>
    ''' <param...
  29. Replies
    15
    Views
    446

    VS 2013 Re: Random distribution in VB

    Having not heard of this I had to give it a try. I created this class:


    Public Class RandomSum
    ...
  30. VS 2012 Re: Letter Combinations - Comments / Suggestions

    Here is the math:



    Private Sub Button1_Click(sender As Object, e As EventArgs) Handles Button1.Click
    For x As Integer = 10 To 3 Step -1
    ...
  31. VS 2012 Re: Letter Combinations - Comments / Suggestions

    I posted the wrong numbers. Both return the same count. From what I can tell testing 9 letters mine might be slightly faster.
  32. VS 2012 Re: Letter Combinations - Comments / Suggestions

    At one point I had added list = list.distinct which was great until there were 10 letters at which point I got an OOM error.
  33. VS 2012 Re: Letter Combinations - Comments / Suggestions

    It started off being recursive but with 10 letters I had issues. 9 letters produces 986,400 combos in approx. 200 ms., 10 letters is 9,864,090 in 2.7 secs.

    Hope this example answers your...
  34. VS 2012 Letter Combinations - Comments / Suggestions

    Given a set of letters produce all the combinations of those letters. These two functions satisfy this. I am asking for comments / suggestions / sanity check. Thanks in advance. This was done to...
  35. Replies
    6
    Views
    228

    Re: Integer to Byte

    The problem is the '1' which is being interpreted as integer. Unfortunately there is not a Type character for byte. One idea is to work with integers and only switch to bytes if absolutely needed. ...
  36. Replies
    14
    Views
    441

    VS 2013 Re: Loosly compare string

    All of this depends on the specifics which you did not state. Specifics for the file name guess:


    must start with lowercase uxm_
    followed by three numbers
    followed by _
    followed by three...
  37. Replies
    4
    Views
    228

    VS 2013 Re: What is Colon (:) e.KeyChar code?

    Agreed.
  38. VS 2013 Re: How to calculate time remaining for prime factor finder?

    See my signature for a fairly fast prime number calculator.
  39. Replies
    18
    Views
    637

    VS 2013 Re: Super Simple Countdown timer

    This is why I used a stopwatch. You might stop the timer from ticking but the current time keeps on going, nothing you can do about that.
  40. Replies
    7
    Views
    369

    VS 2013 Re: Dice Simulator question

    The way you have it the random numbers are likely the same. Here is a short version of what you have



    Private Sub Button3_Click(sender As Object, e As EventArgs) Handles Button3.Click
    ...
Results 1 to 40 of 500
Page 1 of 13 1 2 3 4



Featured


Click Here to Expand Forum to Full Width

Survey posted by VBForums.