Member Of GONAD

After all those endless nights in front of my computer trying to work around several pesky bugs and half baked functions in my beloved Lotus Notes; after uncounted server crashes and RSODs; after pilgramage to conferences, today I became a member of GONAD.

member of gonad

If you too want to become a member of GONAD, read Steve McDonagh’s post for furher information.


F*ck f*ck f*cking b*lloxing f*ck

If you are not offended at anything, jump over to aisteach sceal, a new blog started by Steve McDonagh.

Greetings gentle reader 🙂
Welcome to the Aisteach Scaél blog where I park some of my short stories, ideas , paintings and anything vaguely creative that I come up with. Be warned I do kick at the boundaries of acceptability, I punctuate when I feel like it and were it not for spell checkers I would have my English teacher spinning in his grave. I treat English much like that 20 year old sweater which is stretched to shapelessness , but you just can’t throw it out because it is so comfortable, I write the way I write for that very reason, because it is comfortable.


Lotus Notes Traveler Fix Pack 8.0.1.2

A fixpack for Lotus Notes Traveler (Fix Pack 8.0.1.2) is available for download. It fixes the following issues

  • LO27829 – Traveler stops pushing data because file name case mismatch
  • LO28880 – Notice accept failed when SMTP routed
  • LO29236 – Underscores in subject with Danish Characters
  • LO29261 – Server Doc lookup failed during startup
  • LO29250 – Device Stop synching because mail file is not resolved
  • LO29364 – “Unable to open view Server\Internet Sites” message displayed
  • LO29482 – Compression error on SSL syncs with self-signed cert
  • LO29215 – Some WM devices can not send mail because of an exception in SubmitMessage
  • LO29211 – Device password screen hides Authenticator screen
  • LO29715 – Could not open database ntsclcache” message in log files
  • LO30460 – Lotus Traveler users cannot reply to email sent from addresses
  • LO30553 – ActiveSync constantly syncs traveler logs
  • LO30955 – Send/Receiver Email in inbox inverted on server
  • Support for Windows Mobile 6.1 Classic, Standard and Professional devices.
  • Support for Self-signed or non-well known SSL certificates on the Domino Server running Lotus Notes Traveler Server.
  • Client log files moved out of the My Documents folder to reduce ActiveSync syncronization for connected devices.

Softsphere Admin & Developer Conference 2008

In September, I’ll be presenting at the Softsphere Admin & Developer Conference 2008 in Munich. The session is about “Templates, Code and Tools”. I’ll try to cover almost everything that is available for Lotus Notes / Domino for free or at least for a small budget. I will take you to some well known sources for Lotus Notes / Domino related stuff in the world wide web. But there are also some sites you might not know by now.

I’m looking forward to seeing you in Munich at Softsphere 2008 ( 15 & 16.-SEP-2008 )


Elevated Command Prompt Here

One of the things that irks me is I’m trying to do stuff in a deeply buried directory in Explorer and then realize that I want to do something Command Prompt related. You get all the way down to where you want to be and say “uwaaaah!” because you realize that you now have to type that long path into a command window. Sure you could copy the path from the directory bar and paste in the command window, but, well, that’s a bunch of steps I don’t want to deal with.

Below you’ll find a set of Registry settings that will enable a “Command Prompt here” and “Elevated Command Prompt here” menu item when you right click on a drive or directory in Explorer.

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\Directory\shell\cmd]
@=”CMD Prompt here”
“NoWorkingDirectory”=””
“Extended”=-

[HKEY_CLASSES_ROOT\Directory\shell\cmd\command]
@=”cmd.exe /k \”pushd %L && title Command Prompt\””

[HKEY_CLASSES_ROOT\Directory\shell\runas]
@=”Ele&vated CMD Prompt here”
“NoWorkingDirectory”=””

[HKEY_CLASSES_ROOT\Directory\shell\runas\command]
@=”cmd.exe /k \”pushd %L && title Command Prompt\””

[HKEY_CLASSES_ROOT\Drive\shell\cmd]
@=”CMD Prompt here”
“NoWorkingDirectory”=””
“Extended”=-

[HKEY_CLASSES_ROOT\Drive\shell\cmd\command]
@=”cmd.exe /k \”pushd %L && title Command Prompt\””

[HKEY_CLASSES_ROOT\Drive\shell\runas]
@=”Ele&vated CMD Prompt here”
“NoWorkingDirectory”=””

[HKEY_CLASSES_ROOT\Drive\shell\runas\command]
@=”cmd.exe /k \”pushd %L && title Command Prompt\””

Works on Windows XP, Windows 2003, and Windows Vista. Vista already has Command Prompt here in the menu but it’s normally hidden. It comes down to a single REG_SZ value called Extended, which is removed as part of the Registry file. If you don’t want to lose the hidden option, remove these two lines. I want it to always be there, so I delete that REG_SZ value.

Download: cmdhere.reg


AutoPopulateGroup – Scheduled Agent

In yesterdays post about how to automatically populate a group document, I published code to do the job in the foreground only. One of my blog readers complained about this. Maybe I was to naive to think that even an unexperienced java developer like me could modify the given code to run on a scheduled basis on the server.

Well, here is the code for an scheduled agent.

import lotus.domino.*;
import javax.naming.*;
import javax.naming.directory.*;
import java.util.Hashtable;
import java.util.Vector; 

public class LDAPSearchWithFilter extends AgentBase { 

	private static String fldMembers = "Members";

    	public void NotesMain() { 

    	try {
        	Database _db;
        	Document _doc;
        	Session session = getSession();
        	AgentContext agentContext = session.getAgentContext();
        	_db = agentContext.getCurrentDatabase(); 

        	Agent ag1 = agentContext.getCurrentAgent(); 

        	String ldapCF = "com.sun.jndi.ldap.LdapCtxFactory";
        	String ldapURL = "ldap://localhost:389/";
        	String ldapBaseDN = "";
        	String ldapUserID = "";
        	String ldapPassword = ""; 

        	Hashtable env = new Hashtable(4);
        	env.put(Context.INITIAL_CONTEXT_FACTORY, ldapCF);
        	env.put(Context.PROVIDER_URL, ldapURL + ldapBaseDN);
        	env.put(Context.SECURITY_PRINCIPAL, ldapUserID);
        	env.put(Context.SECURITY_CREDENTIALS, ldapPassword); 

      	DocumentCollection _dc = _db.getAllDocuments();
      	Document doc = _dc.getFirstDocument();

      	while (doc != null) {
        	String searchCriteria = doc.getItemValueString("SelectionCriteria");
        	DirContext ctx = new InitialDirContext(env);
        	SearchControls ctls = new SearchControls();
		NamingEnumeration answer = ctx.search("", searchCriteria, ctls);
		PopulateGroup (answer, doc);
     		ctx.close();
        	doc = _dc.getNextDocument();
		} // end of while
	  } // end of try
		catch (Exception e) {
    		e.printStackTrace(); }
	} // end of Main 

	public static void PopulateGroup(NamingEnumeration col, Document doc) { 

    	try {
    	Item item = doc.getFirstItem(fldMembers);
    	Vector v = new Vector();
    	String result;
	if (col.hasMore()) {
        	while (col.hasMore()) {
            	  SearchResult sr = (SearchResult)col.next();
            	  result = (String)sr.getName();
                  v.addElement(result.replace(',','/'));
           	} // end of while
		  doc.replaceItemValue(fldMembers, v);
    		  doc.save(true);
		} // end of if
    	} // end of try
	catch (NamingException e) {
    		e.printStackTrace(); }
	catch (Exception e) {
    		e.printStackTrace(); }
	} // end of PopulateGroup
} // end of class

AutoPopulateGroup (If You Do Not Run Domino 8.5)

A few days ago, I wrote about a new feature of Domino 8.5 to automatically populate groups via a LDAP selectioncriteria. This is a great feature and I have successfully tested it on my sandbox server.
Since we run Domino 8.0.1 on our productive servers, we cannot use this very useful feature. …

But, with a few lines of JAVA and Lotusscript code, you can build your own solution to auto populate groups. Here is what I came out with.

I’ve created a subform with two fields and a button.

  • HiddenMembers, Text, hidden
  • SelectionCriteria, Text, editable

The “Populate Group” button contains the following code

'/* Declaration
Const fldMEMBERS = "Members"
Const fldHIDDEN = "HiddenMembers"
Const agntDOLDAP = "AutoPopulateGroup"

Sub Click(Source As Button)
	Dim s As New NotesSession
	Dim ws As New NotesUIWorkspace
	Dim db As NotesDatabase
	Dim agent As NotesAgent
	Dim doc As NotesDocument
	Dim uidoc As NotesUIDocument
	Dim searchResultItem As NotesItem
	Dim paramid As String 

	Set db = s.CurrentDatabase
	Set uidoc = ws.CurrentDocument
	Set doc = uidoc.Document
	Set agent = db.GetAgent(agntDOLDAP)
	Call doc.save(True, False)
	paramid = doc.NoteID
	Call agent.RunOnServer(paramid)
	Delete doc
	Set doc = db.GetDocumentByID(paramid) 

	Set searchResultItem = doc.getFirstItem(fldHIDDEN)
	Call uidoc.FieldSettext( fldMEMBERS,  "")
	Forall values In searchResultItem.Values
		Call uidoc.FieldAppendText(fldMEMBERS,  values)
		Call uidoc.FieldAppendText(fldMEMBERS, Chr(10))
	End Forall
	Call uidoc.Refresh
	doc.Remove(True)
End Sub

Like in Domino 8.5 you’ll have to run LDAP on your server. To access LDAP and do a search according to the SelectionCriteria, you need an agent with the following piece of Java code.

import lotus.domino.*;
import javax.naming.*;
import javax.naming.directory.*;
import java.util.Hashtable;
import java.util.Vector; 

public class LDAPSearchWithFilter extends AgentBase { 

	private static String fldTmpMembers = "HiddenMembers";

    	public void NotesMain() { 

    	try {
        Database _db;
        Document _doc;
        Session session = getSession();
        AgentContext agentContext = session.getAgentContext();
        _db = agentContext.getCurrentDatabase(); 

        Agent ag1 = agentContext.getCurrentAgent();
        String paramid = ag1.getParameterDocID();
        Document doc = _db.getDocumentByID(paramid); 

        String searchCriteria = doc.getItemValueString("SelectionCriteria"); 

        String ldapCF = "com.sun.jndi.ldap.LdapCtxFactory";
        String ldapURL = "ldap://localhost:389/";
        String ldapBaseDN = "";
        String ldapUserID = "";
        String ldapPassword = ""; 

        Hashtable env = new Hashtable(4);
        env.put(Context.INITIAL_CONTEXT_FACTORY, ldapCF);
        env.put(Context.PROVIDER_URL, ldapURL + ldapBaseDN);
        env.put(Context.SECURITY_PRINCIPAL, ldapUserID);
        env.put(Context.SECURITY_CREDENTIALS, ldapPassword); 

    try {
       	DirContext ctx = new InitialDirContext(env);
        	SearchControls ctls = new SearchControls();
		NamingEnumeration answer = ctx.search("", searchCriteria, ctls);
		PopulateGroup (answer, doc);
        	ctx.close(); 

	    		} catch(NamingException e) {
     	   		e.printStackTrace();
    		} 

	    } catch (Exception e) {
    		e.printStackTrace();
    }
} // end of Main 

public static void PopulateGroup(NamingEnumeration col, Document doc) { 

    try {
    Item item = doc.getFirstItem(fldTmpMembers);
    Vector v = new Vector();
    String result;    

	if (col.hasMore()) { 

        		while (col.hasMore()) {
            		SearchResult sr = (SearchResult)col.next();
            		result = (String)sr.getName();
                	v.addElement(result.replace(',','/'));
           	} // end of while

			doc.replaceItemValue(fldTmpMembers, v);
    			doc.save(true);
		}
    }
	catch (NamingException e) {
    		e.printStackTrace();
    		} catch (Exception e) {
    			e.printStackTrace();
    			}
	} // end of PopulateGroup
} // end of class

Set the agent’s runtime security to “2”, to allow restricted operations. When you have all code in place, you can test the function by typing a selection criteria and clicking the button.

The members field in your form should now show all persons that have “serv01” as their mailserver.

Download sample database


Off The Air For Holiday

Once again this year it’s time to pack my bags and start my holidays. I’m totally fed up with all this stupid user questions about forgotten passwords and stuff. I’m pissed by CEOs making wrong decisions that causes extra work.

Next 3 weeks I don’t need no business blahblah, no helpdesk calls, no charts, no not damn swearing in public.

I don’t give a shit! Just trunks, cold beverages, the sun and white sand on the beach.


New Replica Crashes Domino 8.0.1 (64 Bit)

When creating a new replica from another server on a Domino 8.0.1 (64 Bit) on Windows 2003 (64 Bit), the server crashes and you will find these lines in your NSD file:

############################################################
### FATAL THREAD 54/73 [ nSERVER: 0138: 09a4]
### FP=0x1080C9342, PC=0x014fb0a8, SP=0x1a92bcd0
### stkbase=1a930000, total stksize=4194304, used stksize=17200
### EAX=0x1080C931C, EBX=0x00000000, ECX=0x080c9342, EDX=0x080c9344
### ESI=0x080c9342, EDI=0x1a92f2d8, CS=0x00000033, SS=0x0000002b
### DS=0x0000002b, ES=0x0000002b, FS=0x00000053, GS=0x0000002b
Flags=0x00010293
Exception code: c0000005 (ACCESS_VIOLATION)
############################################################
@[ 1] 0x014fb0a8 nnotes.Cmovmem+656 (1a92f2d8,4f0101,0,159b400)”

This seems to be similar to SPR RMAA7D9HAP. The Knowledgebase says that this will be fixed in 8.0.2.
I informed IBM and they promised to provide a hotfix to solve this issue.

Update: Received hotfix today. Problem solved!


1954 – How could a computer look like in the year 2004

Scientists from the RAND corporation have created this model to illustrate how a “home computer” could look like in the year 2004. However the needed technology will not be economically feasible for the average home. Also the scientists readily admit that the computer will require not yet invented technology to actually work, but 50 years from now scientific progress is expected to solve these problems. With teletype interface and Fortran language, the computer will be easy to use.

What on earth the steering wheel is presumed being used for?


PushOnly, PullPull, PushPull, PullOnly ?

I wanted to have a quick overview on how the servers replicate and if replication is enabled w/o. opening each document.

The easiest way to accomplish  this is to insert a new row into the “Server\Connections” view in the Domino Directory. The view displays values as colors. If replication or schedule is disabled for a connection, the column does not show an icon.

The following formula is used to visualize the replication direction.


_PullPull:=178:178;
_PullPush:=178:179;
_PullOnly:=178;
_PushOnly:=179;
@If(RepTask="0" | Enabled="0";"";
@If ( RepType="0";_PullPull; RepType="1";_PullPush; RepType="2";_PullOnly; RepType="3";_PushOnly;
""))

Tweak The Auto-Populated Groups Feature In Domino 8.5

Yesterday I wrote about the new Auto-Populated Groups in Domino 8.5 . Today I want to show, how you can tweak this feature by just adding a new subform to names.nsf on the server and not using any additional code or modifying existing code to make the feature work.

As we learned yesterday, Domino uses LDAP and a LDAP Query to populate the members field in an auto-populated group.

In 8.5 Beta 1 you can only select the option “HomeServer” in the “Auto Populate Method” field which results in a fixed string in the “SelectionCriteria” field . This field is computed and you cannot modify its value.

We could easily make this field editable. But this means to modify the standard coding which is not always a good idea.

But you can achieve the aim in another way. Follow these steps

  • Create a new subform
  • Create a new field on the subform ( SelectionCriteria, Text, Editable )
  • Give it the name Custom and an alias starting with $AutoPopulate followed by a number of your choice ( i.e. 9999)
  • Save the subform

When you now create a new group, the “Auto Populate Method” field contains a new option … Custom. Magic, isn’t it ?

In fact it is not magic at all. When you open a group form in edit mode, the “Sub GenerateSubFormsList” in subform $GroupInheritableSchema reads all design elements  and fills the “SubformsList” field with the names of all subforms starting with $AutoPopulate as an alias.

Then the following formula shows the subform according to the choice you make as an auto populate method

@If(AutoPopulate="" | AutoPopulate="0";"";"$AutoPopulate" + AutoPopulate)

That’s it, folks!

By the way, this is a great example of how to write code that allows enhancements without changing the code.


Auto-Populated Groups in Domino 8.5

Domino 8.5 comes with a new feature to use predefined criteria to automatically determine and update group membership.

Complete these steps to set up an auto-populated home server group.

  • Set up a Home Server auto-populated group in a Group document.
  • Specify the update interval for auto-populated groups in the Domino Directory Profile document.

and ( this is not in the administrator help for 8.5 )

  • You must have LDAP enabled on the server.

Why LDAP ? Take a look at the “SelectionCriteria” field in the recently created group document.


iLug 2008 – Speedgeeking

According to Paul Mooney’s definition, SpeedGeeking is:

… a brand-new , quick-n-dirty, raucous way to learn some great tips, tricks, and techniques from some of the best and brightest of our ILUG speakers. In a short 5 minutes you’ll see some tips, techniques (and sometimes crazy) ideas that they have been working on. …

To give all of you who did not attend iLug 2008 an impression what this means in reality, here is a video of fabulous Sean Burgess.

There was also SpeedSponsoring, which does not mean to give away much Guiness as you can in 5 Minutes ( which would have been great from the attendees point of view ) or buy as much as you can from the exhibitors products ( which would have been great from the sonsor’s point of view ).
To me it seemed that most of the sponsors did not have had any clue what Speedsponsoring really is.

Most of them tried to do a presentation of their product in 5 minutes. I had expected to see only one outstanding feature of the product in question that was presented in a breathtaking manner. But it was great fun anyway.

Because all of us at least on friday suffer from deprivation of sleep, another SpeedFoo took place at the very beginning of Julian Robichaux’s and Rob McDonagh’s “Charts! Reports! Graphs! Beer (no, not for you)… ” session. … SpeedNapping.