Search:

Type: Posts; User: .paul.

Page 1 of 13 1 2 3 4

Search: Search took 2.75 seconds; generated 17 minute(s) ago.

  1. Replies
    7
    Views
    695

    VS 2010 Re: VB2010: how get more timer precision?

    Winforms isn’t your best choice for intensive graphical games. That’s the point…
  2. Replies
    7
    Views
    695

    VS 2010 Re: VB2010: how get more timer precision?

    You can fool the human eye with 20FPS. Why do you need more?
  3. Replies
    6
    Views
    330

    VS 2019 Re: DLL Based Project

    Right click on the project in solution explorer, then select Rebuild
  4. Replies
    10
    Views
    582

    Re: VB.net Slots game bug not easily apparent

    As jmcilhinney told you, numbers are numbers and text is text, however much it looks like a number on your screen.

    If you try Button1.Text = “20” + “5” what do you get??? You’d expect “25”, but...
  5. Replies
    9
    Views
    704

    VS 2022 Re: 2nd form not showing on desktop

    I have an app, with an animated form that remembers its last location. I’ve had times when the compiled app config file has been corrupted and replaced with default values, resulting in the form...
  6. Replies
    46
    Views
    2,140

    VS 2010 Re: how convert VB6 to VB2010 code?

    Try this


    For i As Integer = 0 To ((bmpData.Stride * bmpData.Height) / 4) - 1

    To convert to integer, as the error says


    For i As Integer = 0 To CInt((bmpData.Stride * bmpData.Height) / 4)...
  7. Replies
    46
    Views
    2,140

    VS 2010 Re: how convert VB6 to VB2010 code?

    In 2009, it was the best i could find :D

    I understood what the algorithm did, but the kludgy way it did it was what stopped me trying to rewrite it...
  8. VS 2010 Re: Expression Validator excluding specific string

    Something like this?


    Dim rx As New Regex
    If rx.IsMatch(TextBox1.Text, ?^[a-z0-9]+\@gmail\.com$?, RegexOptions.IgnoreCase) Then
    ?Email address found
    End If

    Edit: The question marks in...
  9. Replies
    46
    Views
    2,140

    VS 2010 Re: how convert VB6 to VB2010 code?

    From several seconds to less than 1/5th of a second, in a top-level language is quite an achievement though
  10. Replies
    46
    Views
    2,140

    VS 2010 Re: how convert VB6 to VB2010 code?

    Good idea with the codebank entry. I didn't, and still don't understand the 4 way recursive algorithm :D Which is why i asked an expert when i saw the opportunity :D
  11. Replies
    46
    Views
    2,140

    VS 2010 Re: how convert VB6 to VB2010 code?

    This site is still buggy. Changing punctuation characters in my text input


    Edit: Site problem reported to admin
  12. Replies
    46
    Views
    2,140

    VS 2010 Re: how convert VB6 to VB2010 code?

    I will implement it, when I get round to having another look at my paint app. I know you?re right about the time savings. That was one of the issues that made me limit the size of images in my paint...
  13. Replies
    46
    Views
    2,140

    VS 2010 Re: how convert VB6 to VB2010 code?

    I didn't time it. Just judging by eye with that simple image (post #31). In a real graphics app, with less regular shapes to fill, i'm sure it'll perform much better than the code i was using...
  14. Replies
    46
    Views
    2,140

    VS 2010 Re: how convert VB6 to VB2010 code?

    I fixed one bug (first line of code in FloodFill5)
    Running the 2 methods side by side on a very simple image, there doesn't appear to be much difference?

    Anyway, thanks Niya. I've uploaded the...
  15. Replies
    46
    Views
    2,140

    VS 2010 Re: how convert VB6 to VB2010 code?

    Ok thanks. This is the slow code. It takes a few seconds rather than milliseconds, and the images i was using aren't large images...



    #Region "UnsafeFloodFill"
    ' Flood the area at this...
  16. Replies
    46
    Views
    2,140

    VS 2010 Re: how convert VB6 to VB2010 code?

    @Niya

    Using this method, how could i create an MSPaint-like floodfill feature? I have an existing method, that radiates out from the clicked pixel that i found on the www a long time ago. The code...
  17. Replies
    27
    Views
    1,440

    Re: How to extract text from HTML

    The standard TextBox has a MultiLines Property that is False by default
  18. Replies
    46
    Views
    2,140

    VS 2010 Re: how convert VB6 to VB2010 code?

    In VB.Net?

    Short=Int16
    Integer=Int32
    Long=Int64
  19. Replies
    46
    Views
    2,140

    VS 2010 Re: how convert VB6 to VB2010 code?

    Basically, where in vb6 you used Long is now Integer, Integer is now Short, Type is now Structure, Byte remains Byte
  20. Replies
    46
    Views
    2,140

    VS 2010 Re: how convert VB6 to VB2010 code?

    Private Const BI_RGB As Integer = 0
    Private Const CBM_INIT As Integer = &H4
    Private Const DIB_RGB_COLORS As Integer = 0

    Private Structure BITMAP '14 bytes
    bmType As Integer
    bmWidth As...
  21. Replies
    27
    Views
    1,440

    Re: How to extract text from HTML

    Sounds like you're using a .Net Core application. That's a specialised type of project. Did you intend to use .Net Core?
  22. Replies
    7
    Views
    654

    VS 2019 Re: Drag/Drop Outlook message to form

    I don't think you can cast it. While searching, i saw something about creating a new MailItem from an object. Not sure if you can do that with a DataObject
  23. Replies
    7
    Views
    654

    VS 2019 Re: Drag/Drop Outlook message to form

    You can find some helpful information here…

    https://learn.microsoft.com/en-us/dotnet/api/microsoft.office.interop.outlook.mailitem?view=outlook-pia
  24. Replies
    27
    Views
    1,440

    Re: How to extract text from HTML

    Regex was around in classic vb times. That’s where I first learned Regex…
  25. Replies
    27
    Views
    1,440

    Re: How to extract text from HTML

    You could use similar methods in modern VB, but different syntax
  26. Replies
    27
    Views
    1,440

    Re: How to extract text from HTML

    You might’ve found a working solution, but you’re using classic vb functions. Also, you should be warned, the html you’re retrieving may not forever be in the format it is now…
  27. Replies
    3
    Views
    544

    VS 2022 Re: Drawn image not aligning correctly

    Try this...


    Private Sub Panel1_Paint(sender As Object, e As PaintEventArgs) Handles Panel1.Paint
    Dim Image = New Bitmap(Panel1.ClientSize.Width, Panel1.ClientSize.Height)
    Using g =...
  28. Re: To get correct result using Regex.Replace or without using Regex.Replace

    Regex.Replace(s, "(\+\d{2})", "$1" & " ", RegexOptions.Multiline)

    $1 is the highlighted group
  29. Re: To get correct result using Regex.Replace or without using Regex.Replace

    You realise, the phrase is…

    The Quick Brown Fox Jumps Over the Lazy Dog???
  30. Re: Scope of Datasets and DataAdapters for SQLite

    I think the question is... If you create a DataTable in a Button_Click handler, will the data stay where you've set a DataSource?
    Scope is scope, for any Variable or Object. If you need the Variable...
  31. Replies
    1
    Views
    255

    Re: Play Sound Using Windows Media Player

    The Code Bank is not here for coding questions. You should ask your question in the VB General forum...
  32. Replies
    15
    Views
    920

    VS 2010 Re: Migrating VB 2010 code

    It had a future 30 years ago…:D
  33. Replies
    9
    Views
    889

    Re: DataFile vs DataBase

    If you use a DataGridView, DataTable, DataAdaptor and a CommandBuilder, you don’t have to handle your Add/Update/Delete commands. It can all be done with a few lines of code…
  34. Replies
    6
    Views
    489

    Re: Resize form when printing

    To resize...


    Dim img As BitMap = 'your Form image
    Dim img2 As New BitMap(img, newWidth, newHeight)
  35. Replies
    1
    Views
    3,036

    Re: Average Strategies

    Update (edit in OP).
  36. Replies
    3
    Views
    494

    Re: Shutdown error due to Unshown form

    You have to fix it one way or another. Might as well fix it properly…
  37. Replies
    5
    Views
    588

    VS 2008 Re: trouble dim as integer

    You should note Val returns a Double, not an Integer…


    ‘ TextBox.Text = “1”
    Val(TextBox.Text) = 1
    ‘ TextBox.Text = “hello”
    Val(TextBox.Text) = 0

    Dim intNumber As Integer
    ‘ TextBox.Text =...
  38. VS 2017 Re: How to allow only one instance of a form in a MDI menu strip to open?

    You've gotta loop through the open forms... :D


    Public Class MDI_Form

    Private Sub Form1ToolStripMenuItem_Click(sender As Object, e As EventArgs) Handles Form1ToolStripMenuItem.Click
    ...
  39. VS 2017 Re: How to allow only one instance of a form in a MDI menu strip to open?

    Try...


    If TypeOf frm Is Form1 Then
    Return
    End If

    Instead of...
  40. VS 2017 Re: How to allow only one instance of a form in a MDI menu strip to open?

    Try this…


    Public Class MDI_Form

    Private Sub Form1ToolStripMenuItem_Click(sender As Object, e As EventArgs) Handles Form1ToolStripMenuItem.Click
    For Each frm As Form In...
Results 1 to 40 of 496
Page 1 of 13 1 2 3 4



Click Here to Expand Forum to Full Width