Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. Visual Basic
  4. Balloon Tooltip for VB.Net

Balloon Tooltip for VB.Net

Scheduled Pinned Locked Moved Visual Basic
csharptutorial
10 Posts 5 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    j1webb
    wrote on last edited by
    #1

    I was told that VB.Net has the capability of displaying a Balloon Tooltip but no one seemed to know how to do it. There are lots of projects on The Code Projects that use C# to create balloon tooltips but nothing in VB.Net Does anyone know how to implement Balloon Tooltips in VB.Net or have a project that shows how to create that type of tooltip. Thanks

    R R 2 Replies Last reply
    0
    • J j1webb

      I was told that VB.Net has the capability of displaying a Balloon Tooltip but no one seemed to know how to do it. There are lots of projects on The Code Projects that use C# to create balloon tooltips but nothing in VB.Net Does anyone know how to implement Balloon Tooltips in VB.Net or have a project that shows how to create that type of tooltip. Thanks

      R Offline
      R Offline
      Robert Rohde
      wrote on last edited by
      #2

      No I dont have any examples. But why dont you just use an assembly generated with C# in your VB.Net app?

      J 1 Reply Last reply
      0
      • R Robert Rohde

        No I dont have any examples. But why dont you just use an assembly generated with C# in your VB.Net app?

        J Offline
        J Offline
        j45mw
        wrote on last edited by
        #3

        I tried to do that with 2 c# projects but I couldn't find enough info on how to use it after I added it to my references.

        1 Reply Last reply
        0
        • J j1webb

          I was told that VB.Net has the capability of displaying a Balloon Tooltip but no one seemed to know how to do it. There are lots of projects on The Code Projects that use C# to create balloon tooltips but nothing in VB.Net Does anyone know how to implement Balloon Tooltips in VB.Net or have a project that shows how to create that type of tooltip. Thanks

          R Offline
          R Offline
          rwestgraham
          wrote on last edited by
          #4

          There is an article on this board that has VB code. I got it to work OK. It has a few problems, but should give you a starting point at least. Has anyone tried it? http://www.codeproject.com/csharp/BalloonTipsArticle.asp#xx620141xx[^]

          J 1 Reply Last reply
          0
          • R rwestgraham

            There is an article on this board that has VB code. I got it to work OK. It has a few problems, but should give you a starting point at least. Has anyone tried it? http://www.codeproject.com/csharp/BalloonTipsArticle.asp#xx620141xx[^]

            J Offline
            J Offline
            j45mw
            wrote on last edited by
            #5

            I downloaded that before going to this message board and I couldn't get it to work. However, that has been about a week ago and I've forgotten what problem I ran into. I'll look into it again. But if you had to do something to make it work I would appreciate finding out what you did.

            J 1 Reply Last reply
            0
            • J j45mw

              I downloaded that before going to this message board and I couldn't get it to work. However, that has been about a week ago and I've forgotten what problem I ran into. I'll look into it again. But if you had to do something to make it work I would appreciate finding out what you did.

              J Offline
              J Offline
              j45mw
              wrote on last edited by
              #6

              I looked at the code again and I remembered that I could not figure out what code I needed to use to make it work. I added a textbox to the Form1 and then tried to use the mouse hover event. The only success I had was the Dim tp As New BalloonTool. Then I could get any thing going from there. This is the code I am currently using and I am just displaying a normal tooltip. But I would like to display a balloon tooltip. Private Sub DataGrid1_MouseMove(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles DataGrid1.MouseMove Dim GrdX As Int32 Dim GrdY As Int32 Dim htInfo As DataGrid.HitTestInfo Try htInfo = Me.DataGrid1.HitTest(e.X, e.Y) If htInfo.Column = 1 Then Dim colCount As Int32 colCount = ds.Tables(0).Columns.Count() Dim tipText As String = Me.DataGrid1.Item(htInfo.Row, colCount - 2).ToString() & " " & Me.DataGrid1.Item(htInfo.Row, colCount - 1).ToString() If tipText.Length > 0 AndAlso tipText.Trim() <> "0" Then Me.ToolTip1.SetToolTip(Me.DataGrid1, tipText) Else Me.ToolTip1.SetToolTip(Me.DataGrid1, "") End If Else Me.ToolTip1.SetToolTip(Me.DataGrid1, "") End If Catch exc As Exception End Try End Sub If you could help me with this, using the classes you refereneced I would really appreciate it.

              R R 2 Replies Last reply
              0
              • J j45mw

                I looked at the code again and I remembered that I could not figure out what code I needed to use to make it work. I added a textbox to the Form1 and then tried to use the mouse hover event. The only success I had was the Dim tp As New BalloonTool. Then I could get any thing going from there. This is the code I am currently using and I am just displaying a normal tooltip. But I would like to display a balloon tooltip. Private Sub DataGrid1_MouseMove(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles DataGrid1.MouseMove Dim GrdX As Int32 Dim GrdY As Int32 Dim htInfo As DataGrid.HitTestInfo Try htInfo = Me.DataGrid1.HitTest(e.X, e.Y) If htInfo.Column = 1 Then Dim colCount As Int32 colCount = ds.Tables(0).Columns.Count() Dim tipText As String = Me.DataGrid1.Item(htInfo.Row, colCount - 2).ToString() & " " & Me.DataGrid1.Item(htInfo.Row, colCount - 1).ToString() If tipText.Length > 0 AndAlso tipText.Trim() <> "0" Then Me.ToolTip1.SetToolTip(Me.DataGrid1, tipText) Else Me.ToolTip1.SetToolTip(Me.DataGrid1, "") End If Else Me.ToolTip1.SetToolTip(Me.DataGrid1, "") End If Catch exc As Exception End Try End Sub If you could help me with this, using the classes you refereneced I would really appreciate it.

                R Offline
                R Offline
                rwestgraham
                wrote on last edited by
                #7

                I just used the example forms included in the source project, and it worked OK. I did not study the code, sorry.

                1 Reply Last reply
                0
                • J j45mw

                  I looked at the code again and I remembered that I could not figure out what code I needed to use to make it work. I added a textbox to the Form1 and then tried to use the mouse hover event. The only success I had was the Dim tp As New BalloonTool. Then I could get any thing going from there. This is the code I am currently using and I am just displaying a normal tooltip. But I would like to display a balloon tooltip. Private Sub DataGrid1_MouseMove(ByVal sender As Object, ByVal e As System.Windows.Forms.MouseEventArgs) Handles DataGrid1.MouseMove Dim GrdX As Int32 Dim GrdY As Int32 Dim htInfo As DataGrid.HitTestInfo Try htInfo = Me.DataGrid1.HitTest(e.X, e.Y) If htInfo.Column = 1 Then Dim colCount As Int32 colCount = ds.Tables(0).Columns.Count() Dim tipText As String = Me.DataGrid1.Item(htInfo.Row, colCount - 2).ToString() & " " & Me.DataGrid1.Item(htInfo.Row, colCount - 1).ToString() If tipText.Length > 0 AndAlso tipText.Trim() <> "0" Then Me.ToolTip1.SetToolTip(Me.DataGrid1, tipText) Else Me.ToolTip1.SetToolTip(Me.DataGrid1, "") End If Else Me.ToolTip1.SetToolTip(Me.DataGrid1, "") End If Catch exc As Exception End Try End Sub If you could help me with this, using the classes you refereneced I would really appreciate it.

                  R Offline
                  R Offline
                  Robert Rohde
                  wrote on last edited by
                  #8

                  To make it work you need thes lines of code (as found in the examples): 'Declarations Private m_hb As HoverBalloon = New HoverBalloon 'in the Constructor m_hb.Title = "Traders corp. Inc" m_hb.TitleIcon = TooltipIcon.Info m_hb.SetToolTip(Button1, "To expediate your process please click here") After a quick check I noticed that this component wont fit your needs, because it currently doesnt allow to change the tooltip (well it allows it but gives an exception :-)). You will have to extend/correct this component or search for alternatives :((. Or you could just make it yourself and write an article :-D

                  J 1 Reply Last reply
                  0
                  • R Robert Rohde

                    To make it work you need thes lines of code (as found in the examples): 'Declarations Private m_hb As HoverBalloon = New HoverBalloon 'in the Constructor m_hb.Title = "Traders corp. Inc" m_hb.TitleIcon = TooltipIcon.Info m_hb.SetToolTip(Button1, "To expediate your process please click here") After a quick check I noticed that this component wont fit your needs, because it currently doesnt allow to change the tooltip (well it allows it but gives an exception :-)). You will have to extend/correct this component or search for alternatives :((. Or you could just make it yourself and write an article :-D

                    J Offline
                    J Offline
                    j45mw
                    wrote on last edited by
                    #9

                    Believe me, if I figure this out there will be an article. It just doesn't seem like it should be this difficult.

                    O 1 Reply Last reply
                    0
                    • J j45mw

                      Believe me, if I figure this out there will be an article. It just doesn't seem like it should be this difficult.

                      O Offline
                      O Offline
                      Omar Mallat
                      wrote on last edited by
                      #10

                      Hi everybody. I found an article in vb.net and one in vb6 but the 2 articles has the same error with the time of detroy. in vb.net I fixed this error using a timer control. :-D I will post it soon. OmarMallat

                      1 Reply Last reply
                      0
                      Reply
                      • Reply as topic
                      Log in to reply
                      • Oldest to Newest
                      • Newest to Oldest
                      • Most Votes


                      • Login

                      • Don't have an account? Register

                      • Login or register to search.
                      • First post
                        Last post
                      0
                      • Categories
                      • Recent
                      • Tags
                      • Popular
                      • World
                      • Users
                      • Groups