Solved

I want to double click on HTML Table row and intercept on in vb form where the browser control is used

Posted on 2010-09-02
3
598 Views
Last Modified: 2013-12-26
Hi I would be be able to double click on a row in an HMTL table and pass back a unquiue reference number to the the form where the html brower brower window control is displayed.

1) I attach the code for the xslt fie that loads the page notebook.xsl
2) I attach the code for loaduing the browser control  loadit.txt
0
Comment
Question by:peter3244
  • 2
3 Comments
 
LVL 11

Expert Comment

by:kbirecki
ID: 33602397
I haven't used an html browser control, but vb can display forms with rows and have the labels and/or text fields clickable.  Is there a reason you need to use the browser control?  I'm thinking that the browser control is going to be limited to what any browser can do - and triggering vb application events is not one of them.  You should be able to create script in the web page that responds to events like clicking, but I don't think double clicking - that's an application-like function, not a browser function.  I've never seen any html-based web page, other than special cases like flash, silverlight or other non-html technology, be able to recognize a double click.  And at that point, if you were doing that, why not implement the whole app in a browser using your web-based scripting language of choice (php, javascript, etc.)
0
 
LVL 6

Expert Comment

by:judgeking
ID: 33630732
I'm not sure what browser control you're using, I use the DHTMLEdit control.  Something like this should work for you:

HTML code:

    <script language="javascript">

       function SetValue(Val) {

         document.all.ClickValue.value = Val;

       }

    </script>

    <input type="hidden" name="ClickValue" value="0">

    <table bgcolor="white" border=1>

      <tr>

        <td ondblclick="javascript:SetValue(1);">One</td><td>1</td>

      </tr>

      <tr>

        <td ondblclick="javascript:SetValue(2);">Two</td><td>2</td>

      </tr>

    </table>



DHTMLEdit code:



Private Sub DHTMLEdit1_ondblclick()

  MsgBox DHTMLEdit1.DOM.All.ClickValue.Value

End Sub

Open in new window

0
 
LVL 6

Accepted Solution

by:
judgeking earned 500 total points
ID: 34035629
Any update?
0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
In this tutorial viewers will learn how to customize the background color and font color of highlighted text using the ::selection element in CSS Begin by defining the selected text as an element in CSS by typing "::selection": Style the ::selection…
The viewer will learn the benefit of using external CSS files and the relationship between class and ID selectors. Create your external css file by saving it as style.css then set up your style tags: (CODE) Reference the nav tag and set your prop…

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now