О программке, запоминающей раб.область

  • Автор темы Optimizer
  • Дата начала
O

Optimizer

#1
Добрый день!

Подскажите пожалуйста - есть ли программка/скримт до Лотус Нотс , которая запоминает все окна и программы, в которых ты сидишь и запускает их вместе с вкладками в одном окне.

Спасибо
 

Kee_Keekkenen

Well-known member
05.09.2006
639
4
#2
если имеется ввиду запоминание множества открытых баз на рабочей области перед закрытием лотусового клиента клиента, то это 8-я версия клиента
 
O

Optimizer

#9
Нашел описание скриптов, а как это воплотить в жизнь не знаю

- BUTTON 1: Disable the save window state features and continue using the "Startup" option.
- BUTTON 2: Clear out the startup folder in order to rely solely on the newer "Save Window State" approach.

Here's the code for BUTTON 1:
[codebox]
Sub Click(Source As Button)
Dim ws As New NotesUIWorkspace
Dim session As New NotesSession
Dim bookmarkdb As NotesDatabase
Dim outline As NotesOutline
Dim entry As NotesOutlineEntry
Dim childentry As NotesOutlineEntry
Dim folder As NotesView
Dim vec As NotesViewEntryCollection

Set bookmarkdb = Session.GetDatabase("", "bookmark.nsf")

Set outline = bookmarkdb.GetOutline("UserBookmarkOrder")

Set entry = outline.GetFirst()

'This will find and delete the bookmark folder containing the links for the Last State, if they exist
Do While Not entry Is Nothing
If entry.Label = "Last State" Then
Do While entry.HasChildren
Set childentry = outline.GetNext(entry)
Call outline.RemoveEntry(childentry)
Loop
Call outline.save()
Goto ExitLoop
Else
Set entry = outline.GetNext(entry)
End If
Loop

ExitLoop:

'Now we need to remove the "link" documents from the Last State folder
Set folder = bookmarkdb.GetView("$LastState")
Set vec = folder.AllEntries
Call vec.RemoveAll(True)

'This will disable the "Save Window State on Exit" user preference
Call session.SetEnvironmentVar( "SaveStateOnExit", "0", True)
Messagebox "You will need to restart your Notes client for the settings to take effect", 48, "Finished"
End Sub
This LotusScript was converted to HTML using the ls2html routine,
provided by Julian Robichaux at nsftools.com.


And here's the code for BUTTON 2:

Sub Click(Source As Button)
Dim ws As New NotesUIWorkspace
Dim session As New NotesSession
Dim bookmarkdb As NotesDatabase
Dim outline As NotesOutline
Dim entry As NotesOutlineEntry
Dim childentry As NotesOutlineEntry
Dim folder As NotesView
Dim vec As NotesViewEntryCollection

Set bookmarkdb = Session.GetDatabase("", "bookmark.nsf")

Set outline = bookmarkdb.GetOutline("UserBookmarkOrder")

Set entry = outline.GetFirst()

'This will find and delete the bookmark folder containing the links for the Last State, if they exist
Do While Not entry Is Nothing
If entry.Label = "Startup" Then
Do While entry.HasChildren
Set childentry = outline.GetNext(entry)
Call outline.RemoveEntry(childentry)
Loop
Call outline.save()
Goto ExitLoop
Else
Set entry = outline.GetNext(entry)
End If
Loop

ExitLoop:

'We need to remove the "link" documents from the Startup folder
Set folder = bookmarkdb.GetView("$Startup")
Set vec = folder.AllEntries
Call vec.RemoveAll(True)

'This will enable the "Save Window State on Exit" user preference
Call session.SetEnvironmentVar( "SaveStateOnExit", "1", True)
Messagebox "You will need to restart your Notes client for the settings to take effect", 48, "Finished"
End Sub[/codebox]
 

Eugen

Well-known member
22.03.2012
177
0
#10
День добрый.
А можно ли сделать наоборот, для одного конкретного приложения?
То есть пусть все ранее открытые кладки восстанавливаются, а для одной это запретить?
Версия 8.5.2.