Ctrl+E

Please help, this is driving me mad. I’m sure there must be a simple answer, I just can’t find it.

In your mail file, a document open in the Preview Pane does not allow Ctrl+E. But you can open the document edit mode from the view. Thus documents open in the preview pane are Read Only.

Try it in your own Notes Mail file. If you right mouse click a document in the preview pane Ctrl+e is not available. Right mouse click the document in the view and ctrl+e is available.

How can you prevent users from using ctrl+e in the preview pane.

This has been asked before, but the answer do not prevent Ctrl+e.

http://www-10.lotus.com/ldd/nd6forum.nsf/55c38d716d632d9b8525689b005ba1c0/008be43a309f502c852570d5007cd292?OpenDocument

Using, Queryopen, Postopen, Querymodechange, To prevent the document going into edit mode does not work, mainly because the Source.inpreviewpane returns false all the time.

Subject: Ctrl+E

Interesting. Don’t know the answer but managed to make a couple of observations over lunchtime that may help…

  1. It’s only Memo’s that Edit is disabled for. Calendar entries, delivery reports, etc all have the option available on the right click menu.

  2. Tried copying a Memo into another DB and previewing it - the Edit option was available so it doesn’t look like it’s a field in the Memo that its reacting to.

  3. The “Preview Pane” in the mail file does not appear to be a real preview pane but rather a frameset with two frames in it. Couldn’t find any code in there that could do this tho.

Don’t know if this helps any. It’s certainly a puzzler…

Pete

Subject: RE: Ctrl+E

Pete, Sorry for the delay in repsonding.

Yep. These are the same sort of test I did. Puzzling for sure!.

cheers

AJP

Subject: doc.IsUIDocOpen – Ctrl+E

I did not use this in a QueryOpen or QMC event, but it should be adaptable to that use by changing the code to use Source.

Dim session As New NotesSession

Dim ws As New NotesUIWorkspace

Dim zzzDB As NotesDatabase

Dim doc As NotesDocument

Dim uiDoc As NotesUIDocument

Dim answer As Integer

'-----------------------------------------------------------------------------

’ MsgBox parameters – can be used where %Include “lsconst.lss” is not allowed

Const MB_OK = 0                 ' OK Button only

Const MB_IconExclamation = 48   ' Warning message

'-----------------------------------------------------------------------------

Set zzzDB = New NotesDatabase(“server”, “thedb.nsf”)

Set doc = zzzDB.GetDocumentByUNID( sUNID )

If doc Is Nothing Then

answer% = Msgbox( "Document " & sUNID & " not found.", MB_OK + MB_IconExclamation, "Error: OpenUIDocByUNID" )

Exit Sub

End If

If doc.IsUIDocOpen Then

answer% = Msgbox( "You cannot open a document in two windows at once.   ", _

MB_OK + MB_IconExclamation, "Selected Document Already Open" )		

Else

Set UIDoc = ws.EditDocument( False, doc )  ' open doc into UIDoc in READ mode

End If

Subject: RE: doc.IsUIDocOpen – Ctrl+E

Doug, sorry for the delay in responding.

Doc.IsUIDoc open … I’d forgotten all about that property. I’ll certainly give this a try. It does not hide/grey our the Ctrl+E option but it might be a suitable workaround.

cheers

AJP