Postopen even and editing document - retruns text properties-confused

RE: Programatically open attachment in edit mode

Sign in to participate Previous Next

RE: Programatically open attachment in edit mode

Posted by Alexander Kogan on 25.Dec.06 at 20:25 using a Web browser

Category: Domino DesignerRelease: 7.0.1Platform: All Platforms

Following is in to the initialization event of the form.

Type KBDINPUT ’ INPUT structure

wVk As Integer ’ must be 1 for kbd

wScan As Integer ’ VKey code

dwFlags As Long ’ we don’t use this

iTime As Long ’ don’t use this

dwExtraInfo As Long ’ or this

End Type

Dim Kinput As KBDINPUT

Type GeneralInput

dwType As Long

xi(0 To 23) As Byte

End Type

Dim Ginput(0 To 1) As GeneralInput

Const INPUT_KYBOARD = 1

Const KEYEVENTF_KEYUP = &H2

Const VK_CONTROL = &H11

Const VK_MENU = &H12 ’ the ALT key

Const VK_T = &H54

Const VK_TAB = &H09

Const VK_RETURN = &H0D

Declare Sub keybd_event Lib “user32” (Byval bVk As Byte, Byval bScan As Byte, Byval dwFlags As Long, Byval dwExtraInfo As Long)

"Following is in the postopen event of the form.

Call keybd_event(VK_MENU,0,0,0) ’ press the ALT key

Call keybd_event(VK_T,0,0,0) ’ fire the T key

Call keybd_event(VK_T,0,KEYEVENTF_KEYUP,0) ’ let up the T key

Call keybd_event(VK_MENU,0,KEYEVENTF_KEYUP,0) ’ let up the ALT key

Call keybd_event(VK_RETURN,0,0,0) ’ fire the RETURN key

Call keybd_event(VK_RETURN,0,KEYEVENTF_KEYUP,0) ’ let up the RETURN key

Call keybd_event(VK_TAB,0,0,0) ’ fire the TAB key

Call keybd_event(VK_TAB,0,KEYEVENTF_KEYUP,0) ’ let up the TAB key

Call keybd_event(VK_TAB,0,0,0) ’ fire the TAB key

Call keybd_event(VK_TAB,0,KEYEVENTF_KEYUP,0) ’ let up the TAB key

Call keybd_event(VK_RETURN,0,0,0) ’ fire the RETURN key

Call keybd_event(VK_RETURN,0,KEYEVENTF_KEYUP,0) ’ let up the RETURN key

following code runs and opens the text properties instead of editing word application directly.

Regards,

Dev

Subject: Postopen event and editing document - returns text properties-confused