Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Alternatives of old IE methods
#9
I'm sorry for your loss Will. That's certainly not something you want to go through. Wish you the best.


About the questions.

We'll continue using window.print() for now, hoping it'll be added soon.
As for the keyboard event. We're currently using it because we're loading a text editor library in the browser. In our program we have certain key presses that can activate functionalities, such as ctrl +s, which saves the text from the editor to our program. However, if you're writing inside the editor, the key presses won't be caught because it's seen as an action inside the browser. Which is why we're catching the keyboard events.

This should be possible if we could execute javascript and directly get the result. Because we then only need to call the document of the editor and define it as a HTMLDocument
(In our new case Edge is async, and we can't find a solution for the code below)
Small code example IE browser:

Dim WithEvents oDoc As HTMLDocument 'Events
Private Sub SetoDoc()
    Set oDoc = wb.Document.parentWindow.Eval("editor.document.$") ' Here we get document of the edit area of the editor
End Sub
And when a key get pressed, we do:
Private Sub oDoc_onkeydown()
    Select Case oDoc.parentWindow.Event.KeyCode
        Case vbKeyS
            If oDoc.parentWindow.Event.ctrlKey Then
                ' Call functions
            End If
End Sub

Hopefully this makes our goal a bit clearer.
Reply


Messages In This Thread
Alternatives of old IE methods - by hsacrm - 2022-08-30, 07:34:20
RE: Alternatives of old IE methods - by wila - 2022-08-30, 10:17:06
RE: Alternatives of old IE methods - by Patrickb - 2022-11-03, 20:10:42
RE: Alternatives of old IE methods - by hsacrm - 2022-08-30, 13:05:33
RE: Alternatives of old IE methods - by wila - 2022-08-30, 17:12:07
RE: Alternatives of old IE methods - by hsacrm - 2022-08-31, 07:32:58
RE: Alternatives of old IE methods - by wila - 2022-08-31, 11:02:56
RE: Alternatives of old IE methods - by hsacrm - 2022-09-09, 14:00:43
RE: Alternatives of old IE methods - by wila - 2022-09-10, 17:45:32
RE: Alternatives of old IE methods - by hsacrm - 2022-09-12, 06:39:00
RE: Alternatives of old IE methods - by wila - 2022-09-12, 12:44:00
RE: Alternatives of old IE methods - by wila - 2022-09-13, 22:20:57
RE: Alternatives of old IE methods - by hsacrm - 2022-09-14, 13:01:42
RE: Alternatives of old IE methods - by wila - 2022-09-14, 14:02:43
RE: Alternatives of old IE methods - by wila - 2022-11-03, 21:02:38
RE: Alternatives of old IE methods - by Patrickb - 2022-11-15, 20:12:43
RE: Alternatives of old IE methods - by wila - 2022-11-15, 22:54:47
RE: Alternatives of old IE methods - by Patrickb - 2022-11-16, 15:41:16
RE: Alternatives of old IE methods - by wila - 2022-11-16, 16:08:59

Forum Jump:


Users browsing this thread: 1 Guest(s)