PACKT Publishing: IBM Sametime 8.5.2 Administration Guide

It took me a while to go thru all of the content, but inally I made it and here is my review.
“IBM Sametime 8.5.2 Administration Guide” was written by Gabriella Davis, Marie L. Scott and Thomas “Duffbert” Duff.

I have attended sessions by Gabriella Davis and Thomas Duff at several conferences and while reading the book, I sometimes felt like sitting in the audience and hear Gabriella and Tom talking. I never had the chance to meet Marie L. Scott but I’m sure that she is as enthusiastic as the other authors.

All of them have a deep knowledge and so is the content of the book.
Every detail of the installation and administration is covered and one should be able to setup a Sametime environment following the description in the book step by step. If I only had this book a year ago, it would have saved me a lot of time then.
My first installation took me more than a week. One week with reading documentation, hanging around in forums and chatting with IBMer Frank Altenburg. And a lot of try and error.

Be asured that, following the book, you can do the installation in less time.
Also, if you are new to Websphere, this book is for you. IBM Sametime is not as easy to setup as double-click a setup.exe and wait. There are many places to look into and numerous properties that can be set or eaven been set wrong.

You can do it the hard way and find out on your own, or invest some money buying this book. There will be an immediate ROI.

The book may also help planning the resources by finding out, what exactly is needed, both hardware and soft skills.

I recommend “IBM Sametime 8.5.2 Administration Guide” to everyone who is new to Sametime, wants to upgrade from an older version and even to those, who already have a Sametime 8.5.x environment running. You will for sure find something in the book that is new to you.

 


Welcome to DomSQL

2012 starts with a big bang. DomSQL has just been released on OpenNTF.

The Domino JDBC Access (a.k.a. DomSQL) exposes Domino data as relational tables and
provides easy access to the tables using a JDBC driver.
JDBC stands for Java Database Connectivity. It is a set of technologies that are part of the
standard Java Runtime environment, used to connect to relational database.

Guess, it will become a long evening now …

 


Using a bigger logo in ApplicationLayout control

The applicationLayout control from the XPages Extension Library is a fantastic control. It makes the layout of an application easy ( once you know, how to set the parameters ).

The control also has a property to include a company or product logo. The only problem  is, that the logo has to have a height that is not bigger than 28px.

But what to do, if your logo has a bigger height? You can put it onto the control and live with the fact, that it breaks your layout ? …

No, this is not an option. CSS to the rescue. Add a new css resource to the control ( or use an existing one) and add the following piece of CSS to the file:

.myLogo {
    position: absolute;
    left: 5px;
    z-index: 1;
}

Next add the myLogo class to the productLogoClass property.  When you now refresh your browser, the logo is displayed correctly, but it overlays the Titlebar and Application links.

Next add these css descriptions to your CSS:

.firstApplication {
    margin-left: 160px !important;
}

.lotusTitleBar .lotusTabs {
    margin-left: 160px;
}

The margin-left value depends on your logo width. Add the firstApplication class to the first node in the xe:this.bannerApplicationLinks section of the applicationLayout.

Now your logo and the links are displayed nicely.

Here is the complete source code for the control.

And here is a small sample application .

HINT: There seems to be a bug in the applicationLayout control. When you add the productLogoClass using the property editor, the class will be added to the xe:applicationLayout entity as well as the xe:oneuiApplication.


A quick hack for the XPages Loading Mask Custom Control

The control, written by Mark Hughes and published on OpenNTF creates loading masks on the loading of a page and in partial refreshes. Just include the control into your XPage and it will start working immediately. The disadvantage is that it shows a loading mask for ALL partial events that are fired. This can be slightly annoying if you have an input field that updates a view panel when you type in your search query. It also displays the loading mask, when you drag and drop portlets in a grid container.

Here is a quick hack to exclude some events. First of all, you have to find out, which element fires the refresh. This can easily be done using firebug.

Just include the following line after

dojo.subscribe( ‘partialrefresh-start’,  function( method, form, refreshId ){

console.debug(refreshId) // add this line

In the firebug console debug window you can now see the Id of the element that triggers the refresh.

And with a few lines of javascript added to the existing code, you can now control, if the loading mask is displayed or not.

 dojo.subscribe( ‘partialrefresh-start’,  function( method, form, refreshId ){
//exclude some elements; Ulrich Krause, 10.12.2011
//console.debug(refreshId)
isInputBox = (refreshId.indexOf(‘pnl_entries_company’) > 0  || refreshId.indexOf(‘searchEntriesPeople’) > 0) ? true:false
//dragging of boxes returns @none
if (refreshId.toString() != ‘@none’ && (isInputBox == false)) {
loading()
}
} );

There are perhaps more elegant ways to achieve the aim; as I already said, this is only a quick hack.

 


Traveler calendar widget freezes HTC Sense ?

Today I’m having some problems with my HTC Desire ( Android 2.3 ). From time to time, the Home Screen becomes completely black and after a few minutes a message appears saying “HTC Sense no longer responding … “. When I OK the message, the Home Screen is rebuild and the phone works for a couple of minutes.

I googled and found  a forum entry that described the situation. The article recommended to remove widgets and applications from the Home Screen. After doing so, the issue did no longer occur. I added one application after the other to figure out which one could be the problematic one.

After installing the Traveler calendar widget, the problem re-appears. I then looked into my calendar for further investigation. I found, that I have 5 ToDos for today.

These documents are not displayed in the widget. And, the problem first appeared today. So there must be a coherency.

I moved the docs to another date; this also solved the issue. Anyone else has seen this? Perhaps an already known issue.


Where is my Sametime??

I have a small issue with the embedded Sametime Client in Notes 8.5.3. I use a laptop in the office that has a 2nd monotor attached to work in Designer. On the latop screen, I open my mailfile and Sametime.

As soon as I click into the Designer on the second screen, my Sametime client goes away from the laptop display. When I click into my inbox for example, the client re-appears

Is this a common problem with multiple monitors or do I miss some secret setting?


Extension Library 8.5.3 – undocumented @functions

Just a quick post before I leave the office for the 46. DanNotes conference.

Looked into source code of the OpenNTF Extension Library and found 2 undocumented functions in the Javascript Extension. (@NormalizeSubject and @ViewIconUrl).

@NormalizeSubject trims a subject to the specified maxlength if it exceeds it and adds 3 dots at the end of the normalized string. So an @NormalizeSubject(‘Hello World’, 9) becomes Hello Wor… .

@ViewIconUrl returns the full path to an icon ressource. For example @ViewIconUrl(81) returns /.ibmxspres/domino/icons/vwicn081.gif

You can find more functions @IsAbsoluteUrl, @InfoMessage, @WarningMessage in the NotesFunctionsEx.java file


November is pulmonary hypertension awareness month

Pulmonary Hypertension (PH) is high blood pressure in the arteries of the lungs that can lead to heart failure. It is still incurable and there is still a lot of research to do to understand, what causes the disease and hopefully find a way to cure it.

My wife has been diagnosed with PH almost 2 years ago. Thanks to very motivated and engaged doctors she is in a stable state at the moment.

PH is an orphan disease and so it is not much known in public. And even a well educated doctor will not always diagnose PH when a patients tells him that he is gasping for air when just trying to reach the next floor. Everybody can be affected and if PH is not diagnosed in an early state, chances are that you will die within the next 2 or 3 years.

PH needs awareness! November is pulmonary hypertension awareness month.

Please link to this article, tweet or share it on Facebook, Google+ etc.

Here are links to PH related sites that can give you some more information on PH


XPages to PDF with iText

Yesterday, David Leedy published a new extended edition of his great Notes in 9 video series. Brian Moore talked about how to create PDF from XPages and showed a simple example during the show.

I played a bit with the iText package and like to share some mor code that shows how to add tables and cells, anchors, chunks and phrases and even HTML to a PDF. Although this is very basic code, it should give you an idea, how to create other elements in PDF.

Here is the code. (Put it into a button on your XPage)

importPackage(com.itextpdf);
importPackage(java.io);

 

//Initialization
var con = facesContext.getExternalContext();
var response:com.ibm.xsp.webapp.XspHttpServletResponse = con.getResponse();

 

//setting response headers for browser to recognize data
response.setContentType(“application/pdf”);
response.setHeader(“Cache-Control”, “no-cache”);

response.setDateHeader(“Expires”, -1);
response.setHeader( “Content-Disposition”, “attachment; filename=\”test.pdf\”” );

 

// Setup the PDF Output Stream
var newPDF:com.itextpdf.text.Document = new com.itextpdf.text.Document();
var writer = com.itextpdf.text.pdf.PdfWriter.getInstance(newPDF,response.getOutputStream());
var htmlWorker = new com.itextpdf.text.html.simpleparser.HTMLWorker(newPDF);

 

// Open the PDF and write the PDF header info
newPDF.open();
newPDF.addAuthor(“Ulrich Krause”);
newPDF.addCreationDate();
newPDF.addCreator(“IBM Lotus Domino V8.5.3 :iText Library”);
newPDF.addTitle(“PDF Demo”);

 

//add a Hello World text to the PDF
var helloWorld = new com.itextpdf.text.Paragraph(“Hello world1”)
newPDF.add(helloWorld);

 

//Create a table with 3 cells, width = 100%
var table = new com.itextpdf.text.pdf.PdfPTable(3); // 3 columns.
var cell1 = new com.itextpdf.text.pdf.PdfPCell(new com.itextpdf.text.Paragraph(“Table Cell 1”));
var cell2 = new com.itextpdf.text.pdf.PdfPCell(new com.itextpdf.text.Paragraph(“Table Cell 2”));
var cell3 = new com.itextpdf.text.pdf.PdfPCell(new com.itextpdf.text.Paragraph(“Table Cell 3”));

table.setWidthPercentage(100);
table.addCell(cell1);
table.addCell(cell2);
table.addCell(cell3);
newPDF.add(table);

 

// Add a Chunk to the PDF; chunks do not add a CRLF when the leght exceeds page width. Better use phrases
newPDF.add(new com.itextpdf.text.Chunk(“This is a chunk. “));

 

// Add a Phrase to the PDF
newPDF.add(new com.itextpdf.text.Phrase(“This is a phrase. “));

 

// Add a ordered List to the PDF
var orderedList = new com.itextpdf.text.List(com.itextpdf.text.List.ORDERED);
orderedList.add(new com.itextpdf.text.ListItem(“Item 1”));
orderedList.add(new com.itextpdf.text.ListItem(“Item 2”));
orderedList.add(new com.itextpdf.text.ListItem(“Item 3”));
newPDF.add(orderedList)

 

// Add a link to the PDF
var anchor = new com.itextpdf.text.Anchor(“eknori.de”);
anchor.setReference(“https://www.eknori.de”);
newPDF.add(anchor);

 

// Add HTML to the PDF
var str = “<html><head><title>titlu</title></head><body><table><tr><td><br /><br /><a href=’https://www.eknori.de’>Link 2 eknori.de</a><br /><br /><br />Test</td></tr></table></body></html>”;
htmlWorker.parse(new java.io.StringReader(str));

 

// Finish
newPDF.close();
writer.close();

facesContext.responseComplete();

Have fun !


Examining LotusScript call stack after a crash or hang with NSD

There is a new feature in Notes/Domino 8.5.3 that tracks LotusScript call stacks as they execute on the client or server, and allows NSD to dump the recorded stacks.

1. Place the following entry in your notes.ini:

DEBUG_LS_DUMP=1

2. Restart the Lotus Domino server or Notes client.

When enabled, an NSD dump will include a LotusScript Interpreter section like the following, which shows a stack trace for all LotusScript that was running at the time NSD was called, for all threads in all Notes/Domino processes.

Read more …


Sandy Carter – Get Bold!

Returned from AdminCamp this afternoon and found a package in my post box. It’s Sandy Carter’s new book “Get Social”; fresh from the press.

The book has not yet been published. So thanks to IBM Press for sending me the book in advance.


Expand last column in Grid

In our applications at IS@Web we use the Dojo Grid from the Extension Library to display data in various places. The autoWidth property automatically sets the width depending on columns width.

This can be a problem, if you put the control into a panel with a fixed width. The next screenshot shows this situation,

Well, no problem. You can set the autoWidth property to false and the grid will grow to the size of the panel. BUT …

As you can see, the grid now fits into the panel, but does not look very nice. It would be great, if the last column would also expand to full width. But unfortunately, there is no such property.

I have attached a small demo application with a custom control that I have build. The control uses the extension library and retrieves its data via a REST service from any view provided a a custom property. The control uses some JavaScript to get the column header names, column width and also some style properties from the view. Set the font weight or style to bold or italic etc. and the grid will also show the content of the column using the weight and style. Also the color can be changed. The demo only contains some of the features. But you can easily extend the list of available colors.

To expand the last column to the full size of the underlying panel, I simply modify the JSON data that bulds the structure of the grid.

// make last column 100%
var _tmp:String = ‘[‘ + json.toString() + ‘]’;

return (true  == compositeData.prop_autoWidth) ? _tmp:
@LeftBack(_tmp,”width:”)  + “width:’auto” + @RightBack(_tmp,”px”);

This code snippet from the dojo.grid SSJS library replaces the last occurrence of width’:123px’ with width:’auto’

Download Sample