Search Results - VBForums

Search:

Type: Posts; User: .paul.

Page 1 of 13 1 2 3 4

Search: Search took 0.42 seconds; generated 42 minute(s) ago.

  1. VS 2013 Re: Visual Studio 2013 not breaking on all exceptions

    http://stackoverflow.com/questions/13419761/stumped-by-vs2012-exception-swallowing-nightmare
  2. VS 2013 Re: Visual Studio 2013 not breaking on all exceptions

    I know of the problem. VS will exit sub if it encounters an exception in Form_Load.
    I'm not sure of the reason, but Try, Catch is the solution
  3. VS 2013 Re: Visual Studio 2013 not breaking on all exceptions

    While debugging, a Try, Catch block can help you identify exceptions, which you can avoid in your eventual compiled code
  4. VS 2013 Re: Visual Studio 2013 not breaking on all exceptions

    Where in your app was the code?
    If it was in Form_Load, that would explain why it does that.
    Unlike ident, I would recommend Try, Catch, in Form_Load
  5. Replies
    1
    Views
    54

    Re: writing to text file

    objWriter.Write(Dod)
  6. Re: Best practice advice requested ragarding VB.NET file(s) management

    one-class-per-file is generally a good method to use, as it's easier locating classes and code that way...
  7. Replies
    12
    Views
    5,578

    Re: [Example] Sendmessage API in .NET

    @usrhlp...

    Please don't post in long finished threads. Other members will think they are new active threads that haven't been long since resolved.
  8. Replies
    12
    Views
    5,578

    Re: [Example] Sendmessage API in .NET

    This is the correct way to write that code:



    Public Class Form1

    Private Declare Function SendMessage Lib "user32.dll" Alias "SendMessageA" (ByVal hwnd As IntPtr, ByVal wMsg As Integer,...
  9. Replies
    3
    Views
    86

    Re: Add apostrophe and roundup numbers

    Standard Numeric Format Strings:

    http://msdn.microsoft.com/en-us/library/dwhawy9k(v=vs.110).aspx
  10. Replies
    3
    Views
    86

    Re: Add apostrophe and roundup numbers

    try:


    slayerBot.Text = temp.ToString("n")
  11. Replies
    7
    Views
    141

    Re: Working with business dates

    a while back I created a calendar control, that calculates UK/US holidays:

    http://www.vbforums.com/showthread.php?639775-dropDown-Calendar-control
  12. Replies
    7
    Views
    141

    Re: Working with business dates

    http://msdn.microsoft.com/en-us/library/bb762911(v=vs.110).aspx
  13. Replies
    7
    Views
    141

    Re: Working with business dates

    You could store them as CSV in My.Resources
  14. Re: counting objects of different keys (strings)

    A Dictionary(Of String, Integer) will work the same as a string-indexed array
  15. Replies
    2
    Views
    117

    Re: Algorithms to Visual Basic

    here's how:

    http://www.homeandlearn.co.uk/NET/vbNet.html
  16. Replies
    2
    Views
    121

    Re: How to Get XML Nodes from XML File ?

    try this. I used xDocument, and xElement, with LINQ to XML:



    Public Class Form1

    Dim xml As XDocument = _
    <?xml version="1.0" standalone="no"?>
    <root>
    <!-- General -->
  17. Replies
    4
    Views
    173

    VS 2008 Re: Tax Rate calculator

    try this:



    If grosspay <= 152 Then
    netpay = grosspay
    ElseIf grosspay <= 309 And grosspay >= 153 Then
    taxamount = (grosspay - 152) * taxrate20
    netpay = grosspay - taxamount...
  18. Replies
    36
    Views
    676

    VS 2010 Re: List displayed in a Textbox

    Dim testlist As New List(Of String)
    testlist.Add("aa")
    testlist.Add("bb")
    testlist.Add("cc")

    testlist is a list(of string).
    TextBox1.Lines requires a string array, so you convert the list(of...
  19. Replies
    2
    Views
    109

    Re: Split a column in a dataset

    Those aren't datasets. A dataset is a collection of datatables.
    What you have are datatables...
  20. Re: LINQ to Dataset (VB 2012), querying and browsing results

    try this:



    Dim query = _
    (From ele In dt.AsEnumerable() _
    Where ele.Field(Of Int16)("PKName") = PKValue _
    Select ele).CopyToDataTable

    For Each row As DataRow In query.AsEnumerable()
  21. VS 2008 Re: Change Selection entry in Listview

    try this:



    Public Class Form1

    Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
    ListView1.MultiSelect = False
    End Sub
  22. Re: Need help with terminology and file management

    You know how to use a Form level variable. You used that for FileName. It's not a giant leap to see how you could store a file's contents in another variable...
  23. Re: Need help with terminology and file management

    It is stored in your textbox's .Text property
  24. Re: Need help with terminology and file management

    There are 256 possible characters in use on English and us computers, and they all have a textual representation, though depending on which font you use they may appear as spaces.
    Windows recognizes...
  25. Re: Need help with terminology and file management

    readalltext returns everything in the file...
  26. Re: Need help with terminology and file management

    As jayinth813 told you:


    TextBox.Text = IO.File.ReadAllText(FileName)



    It doesn't save the file contents.
    The first button just gets the filename which it saves in the FileName variable...
  27. Re: Need help with terminology and file management

    that's an overcomplicated method you're using, but:


    FileName = IO.File.ReadAllText(ofd.FileName)

    should be:


    FileName = ofd.FileName
  28. Replies
    36
    Views
    676

    VS 2010 Re: List displayed in a Textbox

    TextBox.Lines = list
  29. Re: Having difficulty with Keyboard Hooks / Hotkeys

    unless you understand exactly what it does, and that is your intention.

    http://msdn.microsoft.com/en-us/library/0wt87xba.aspx

    never say never:D
  30. Replies
    8
    Views
    261

    VS 2010 Re: Difference In Times

    put:


    Dim duration As TimeSpan = endTime - startTime

    in Button2_Click, after:


    endTime = DateTime.Now
  31. Re: Drag and drop buttons that are added/removed at runtime in FlowLayoutPanel

    Here's how to drag dynamically created buttons. You'll need to find a way to make them stay where you drag them to, as adding another button rearranges the buttons order:



    Public Class Form1
    ...
  32. Re: Hello, quick code question that is likely very noobish

    If you still have the problem, we need to see your inputs, outputs and the code you're now using.
    It'd be helpful if you can tell us what you expect the outputs to be...
  33. Re: [RESOLVED] ListView check\unchecked - a better way

    Your rep is unremovable according to forum policy. If it was a simple 'No comment' rating it could be removed. Maybe forum admins might help...
  34. Re: Need some instruction on using dictionaries VB2013

    A valuable contribution, but it only adds to a greater understanding of the working of dictionaries, and more knowledge is better than less knowledge.
  35. Re: Need some instruction on using dictionaries VB2013

    So you want to know if the dictionaries both have identical keys associated with identical value, or you need to count how many keys have matching values?
    You can loop through a dictionary like...
  36. Replies
    5
    Views
    755

    Re: Help with this code

    I'm not sure what you're doing in your code but my guess is:



    sum = TextBox1 * TextBox2 * TextBox3 * TextBox4


    If I'm right, you don't have Option Strict on, as that wouldn't be allowed....
  37. Re: Need some instruction on using dictionaries VB2013

    should the keys be identical in both dictionaries when comparing values?
    you can check if 2 dictionaries have the same content in one line:



    MsgBox(FirstValue.SequenceEqual(SecondValue))
  38. VS 2010 Re: Only Last Dynamic Picture Box Showing

    this works. I think the problem was because you were trying to assign property values to an uninitialized object variable:



    Public Class Form1

    Private Sub Button1_Click(ByVal sender As...
  39. VS 2010 Re: Only Last Dynamic Picture Box Showing

    you only declared one NewPic that you tried to add twice
  40. Re: [RESOLVED] ListView check\unchecked - a better way

    It's to avoid any recursion
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.