XPageDeveloper – Client Killer v1.1 with log file cleaner

A new version of my Client killer software is released this new version has support for cleaning up log files that the Client is producing in the following folders workspace/logs and IBM_Technical_Support. You can run the client killer with and without the Notes client running, If you only want to clean up the log files. 

 

 

 

The size of the log file folders is presented directly when the client is started.

Download the new version here

New version of my Tinymce Custom Control

I got an enhancement request from a user if it’s was possible to validate if the tinyMCE control had some text.
Because validation is implemented as a core property on XPage Controls this was a quick fix.  

One Tip i can give when creating your own custom controls is when binding computed properties, set the property how the compositeData property should bind to compute at page load, if the data shouldn’t update.
Some properties of controls require this. I don’t know if this is a bug or if it’s this is meant to work like this. 😉

I also built an XPage using the Form Table control to display how the validation looks like.

Check out the new version of the Tiny Mce custom control –> openntf project page 

Using RegExp to make field validation easier

There is alot of ways to validate fields. But if you ask me validating thru regular expression is very powerful because you can test for patterns in strings. You can test for valid email adresses, phone numbers or your required passwords.

Because regular expressions can be tested both on the client and the server using almost the same code you can do tests on the client side without doing round trips to the server when the user exits a field or perhaps while the user are typing.

Lets look at an example of an regexp

[a-z]+

This will check that the tested string contains letters in the interval a-z

(\d{5})

The above code will test so the string is five numbers.

This is very helpful because then you could test for a password pattern

((?=.*\d)(?=.*[a-z])(?=.*[A-Z]))

This will then test the string to contain a digit, a lowercase and an uppercase letter. Imagine testing this some other way, no thanks. To complete this we also need to test for length and that we do by adding this to the line .{8,14} this will test that the string is 8 to 14 letters long. So the complete string is then

((?=.*\d)(?=.*[a-z])(?=.*[A-Z]).{8,14})

This seams complicated you might say, Yes regexp can be complicated but then we have great resources online to just copy and paste regexp from. But test the regexp you copy from the web, they might not do what you want them to do 😉

The best regexp tester that I have found is Rubular

How to use Regexp with old school Domino and XPages

How do you use this in HCL Domino if you haven’t moved over to XPages yet, you could use this in client side javascript. And if you have moved over to XPages you can use this in Client side JS, Serverside JS and with a expression validator. I’m going to show you all these ways to validate.

1. Client side JS validation using RegExp

var field=document.getElementById("YOURFIELDNAME");
var data=field.value;
var re=/\d+/
if(re.test(data)){
   alert("Valid");
}else{
   alert("Not Valid");
}

2. Serverside javascript

The first Two lines changes from the client side script and also you need to write what should happen if the validation is true or not.

var inputText1= getComponent("inputText1");
var data=inputText1.getValueAsString()

var re=/\d+/
if(re.test(data)){
//do some stuff
}else{
//Do other stuff
}

3. validateExpression validator

The only thing diffrent in this validator than number 2 is that you return true or false when validation is done.

4. validateConstrain validator

This validator is used if you want to do a complete match of the value in the field using regular expression. My suggestion is that you start the string with ^( write you expression and end with )$ because then it’s easy to use a regexp tester when testing your regular expression this will tell the regexp engine that the string must validate as a line of text.

Update:

Check out this great post about how to create regex strings directly in the designer.

http://www.intec.co.uk/test-your-regular-expressions-in-domino-designer/#comment-1498

Another XPageDeveloper.com Utility – Client Killer

Tired of killing the Notes client using the command line?

Client killer is the solution for you, a NSD.exe GUI that will find your Notes install folder and with a single click kill the notes client.

Hopefully you will never need to use it but if you do, get your free copy today 

Download Client Killer

nsd.exe high cpu fix run Client Killer

Designer Memory Configurator 1.1 update

The utility is updated to version 1.1 after a comment from a user that the memory option of 2048mb doesn’t work. So that one is removed as an option in the utility.

enjoy

Download it using the link below

–>>> Designer Memory Configurator

Domino Designer Memory Configurator is here

Do you want more speed in Domino Designer?

Do you want to configure you designer memory but always forget where to do it?

Did you know that everytime you add a Fixpack of the designer the memory is reseted ?

Now this is no problem just use Designer Memory configurator and with 2 click your memory is increased to the level you need.  

Download it using the link below

–>>> Designer Memory Configurator

If you every used .copytodatabase with a replicated or clustered Domino

I had a strange problem with documents that disappears in a replicated or clustered environment.

A more deep investigation lead to the discovery of deletion stubbs being created days/weeks/months before the document even was created, Strange. Documents getting create date the same as the original document.

But then a discovery was made .copytodatabase creates the same UNID everytime if the original document isn’t in the database. OK who cares the document isn’t in the database and no other document has that UNID. So far so good, but if you copy the document delete the new document in the new database. And copy it again, it gets the same UNID anyway. OK you might say, do this matter.

YES

It’s overwriting the deletion stubb on the destination database. If this database is in a clustered or replicated environment this will give your very very strange results. Documents disappearing, One minute they are there the next the documents are gone. 

There is a notes.ini param that fixes the problem, but there is nothing in the documentation. And do we need a notes.ini to fix a bug? It should be the other way around if you built an application that uses a functionality based on a bug then you should need to apply the notes.ini param not the other way around. 

To fix the problem apply the notes.ini param where your code runs client/server and you need to restart after applying.

CopyToDatabase_New_UNID=1

There is some other workarounds, one is creating a new document and using copyallitems. And the other one is copying the document two times but both these workarounds will give you problems if your document is large. So I would recommend the notes.ini param. 

This problem should only affect LotusScipt code but after trying it out it works the same in XPages also.

Notes Client as a browser plugin

After reading the post by Raj –>link about the Notes browser plugin in 8.5.4

This is great the Notes client as a browser plugin, all you old applications running in “browser notes”

Hopefully an automated install can be preformed so the user interaction is minimized to UserName and password, in the comment Raj writes that server name also needs to be specified. Hopefully this can be removed with some  install param. Or that you could get this from the server you download from.
Perhaps require a login on a Domino server thru http, then you know the username, password and homeserver directly. 

According to the blog post the install is 60MB and under one minute in install time.

I just want to say Woow this is real news for the corporate use of Lotus Notes.

Even if it’s an ordinary notes client behind the scen, it’s what the user sees that matters.

Good work IBM 

Ed Brill post about the Lotus Notes Browser Plugin

Some minor updates to SmallTalk and TinyMce editor

I have today released some small updates to SmallTalk and the tinyMce editor custom control.

SmallTalk needed some polishing to the attachment upload working in the client.

And for the tinyMce control I did some changes in the init scripts because they gave some strange js
errors in older internet explorer browsers so now it should work in IE7 also.

Enjoy 

Let’s do a Social Group Activity and what a response

Woow what a response. I sent out last night on twitter that we should start a social group activity.

The idea didn’t start last night you might remember that I wrote about that Lotus Notes and XPages needs a great tagline, Post 1 Post 2. The Lotus Notes community needs something to get together around.

If you use Lotus Notes for email or traveler for email in you phone. You should add a line at the bottom to should where the email was sent from. Think of all the people that we send emails to everyday. If they see the line at the bottom of the email from you and from all of us that like Lotus Notes.

Soon I think people will start saying to each other I also want an inbox that does more.

Exactly what you add in your email signature isn’t that important, the main thing is that you add something.

Speak out and join the community that’s what Social is about. 

My original line was

Sent by Lotus Notes – More than an inbox

Per Henrik LaustenPer Henrik Lausten

thought we should change the line so it looked more like the iphone

Sent from Lotus Notes – More than an inbox 

Mat NewmanMat Newman

Wrote his own post regarding this and thought of the line

This message was sent from IBM Lotus Notes – MORE than an inbox

Dave Armstrong commented Matts post and thought that we should

 add this line into applications that is using domino

Serdar BaşeğmezSerdar BaşeğmezSent out this twitter post

I have added this line to my email signature!! “Sent by Lotus Notes – more than an inbox.”. Your turn! 

Feel free to comment that you join this social activity.