<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>JavaWithMarcus &#187; Lotus Notes</title>
	<atom:link href="http://blog.turabdin.nl/category/lotus-notes/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.turabdin.nl</link>
	<description>Just another Java blog</description>
	<lastBuildDate>Mon, 24 Jan 2011 14:22:58 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
		<item>
		<title>Lotus Notes: Create Excel files with POI</title>
		<link>http://blog.turabdin.nl/2011/01/lotus-notes-create-excel-files-with-poi/</link>
		<comments>http://blog.turabdin.nl/2011/01/lotus-notes-create-excel-files-with-poi/#comments</comments>
		<pubDate>Mon, 24 Jan 2011 14:19:51 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Java]]></category>
		<category><![CDATA[Lotus Notes]]></category>

		<guid isPermaLink="false">http://blog.turabdin.nl/?p=74</guid>
		<description><![CDATA[My colleague (Martin Meijer) asked me some time ago how to easy export data to Excel without installing Excel on the server. As a Java developer I know Apache POI project. There is some great progress on that project. So I made a simple Java Agent that creates a simple Excel file and embed it as an [...]]]></description>
			<content:encoded><![CDATA[<p>My colleague (Martin Meijer) asked me some time ago how to easy export data to Excel without installing Excel on the server. As a Java developer I know Apache POI project. There is some great progress on that project.</p>
<p>So I made a simple Java Agent that creates a simple Excel file and embed it as an attachment. First of all you need to <a href="http://poi.apache.org/" target="_blank">download</a> Apache POI.</p>
<p><span id="more-74"></span></p>
<p>Create a new Java Agent. Import the poi.jar as archive. Also import the dependencies commons-logging.jar and log4j.jar</p>
<p>Edit your JavaAgent.java</p>
<p>Take a look at this code and implement your own agent (our copy it if you&#8217;re too lazy to understand).</p>
<p>Past it where the comment is (Your code goes here).</p>
<pre>// (Your code goes here)
Workbook wb = new HSSFWorkbook();
Sheet sheet = wb.createSheet("Sheet 1");
Row row = sheet.createRow(0);
row.createCell(0).setCellValue("Hello Lotus");
Document doc = agentContext.getCurrentDatabase().createDocument();

RichTextItem item = doc.createRichTextItem("item");
File tempFile = new File(doc.getNoteID());
FileOutputStream out = new FileOutputStream(tempFile);

wb.write(out);
out.close();

item.embedObject(EmbeddedObject.EMBED_ATTACHMENT, null, tempFile.getAbsolutePath(), "Excel.xls");
doc.save();

tempFile.delete();
getAgentOutput().println("Done!");</pre>
<p>Make sure that you import the classes after you pasted the code. Press Ctrl+1 on the errors.</p>
<p>If you have some questions? Place a comment or contact me at twitter <a href="http://twitter.com/JavaWithMarcus" target="_blank">@JavaWithMarcus</a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.turabdin.nl/2011/01/lotus-notes-create-excel-files-with-poi/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Get User-Agent string in XPages</title>
		<link>http://blog.turabdin.nl/2010/08/get-user-agent-string-in-xpages/</link>
		<comments>http://blog.turabdin.nl/2010/08/get-user-agent-string-in-xpages/#comments</comments>
		<pubDate>Tue, 03 Aug 2010 09:33:50 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Lotus Notes]]></category>
		<category><![CDATA[XPages]]></category>

		<guid isPermaLink="false">http://blog.turabdin.nl/?p=55</guid>
		<description><![CDATA[There is an easy way to get in server-side javascript in a XPage the User-Agent string from the request header. You can use this also to get other headers in the request. facesContext.getRequest().getRequestHeaderMap().get("User-Agent"); This returns: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/533.4 (KHTML, like Gecko) Chrome/5.0.375.125 Safari/533.4 Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; [...]]]></description>
			<content:encoded><![CDATA[<p>There is an easy way to get in server-side javascript in a XPage the User-Agent string from the request header. You can use this also to get other headers in the request.<span id="more-55"></span></p>
<pre>facesContext.getRequest().getRequestHeaderMap().get("User-Agent");</pre>
<p>This returns:</p>
<p><span style="text-decoration: underline;">Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US) AppleWebKit/533.4 (KHTML, like Gecko) Chrome/5.0.375.125 Safari/533.4</span></p>
<p><span style="text-decoration: underline;">Mozilla/4.0 (compatible; MSIE 8.0; Windows NT 5.1; Trident/4.0)</span></p>
<p><a id="AA56048590" href="http://www.hypersmash.com/hostgator/"></a></p>
]]></content:encoded>
			<wfw:commentRss>http://blog.turabdin.nl/2010/08/get-user-agent-string-in-xpages/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>Installing IBM Lotus Notes 8.5 on Ubuntu 64bits</title>
		<link>http://blog.turabdin.nl/2009/07/installing-ibm-lotus-notes-8-5-on-ubuntu-64bits/</link>
		<comments>http://blog.turabdin.nl/2009/07/installing-ibm-lotus-notes-8-5-on-ubuntu-64bits/#comments</comments>
		<pubDate>Fri, 03 Jul 2009 13:48:17 +0000</pubDate>
		<dc:creator>admin</dc:creator>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Lotus Notes]]></category>
		<category><![CDATA[ubuntu]]></category>

		<guid isPermaLink="false">http://turabdin.4fx.biz/blog/?p=9</guid>
		<description><![CDATA[Here is a small how-to install IBM Lotus Notes 8.5 on Ubuntu Jaunty 64 bits Sometimes I need to bite my tongue and this is on of those occasions. The icon text on the workspace is still an issue even with the final code drop 12. To make sure I was not at fault I [...]]]></description>
			<content:encoded><![CDATA[<p><img class="size-full wp-image-11 alignright" title="lotus-notes-logo" src="http://turabdin.4fx.biz/blog/wp-content/uploads/2009/07/lotus-notes-logo.png" alt="" width="100" height="100" />Here is a small how-to install IBM Lotus Notes 8.5 on Ubuntu Jaunty 64 bits</p>
<div id="_mcePaste">Sometimes I need to bite my tongue and this is on of those occasions. The icon text on the workspace is still an issue even with the final code drop 12. To make sure I was not at fault I did a few things today to work around the issue. I deleted, moved, copies, restored every desktop*.dsk file to no avail. The last test was to install Notes 8.5 on a clean system. The only one I had available was a new 64Bit Ubuntu system I have installed. For those in the know, Ubuntu sever does not come with a GUI. The options are to install the server version and then install the desktop. I use a different approach. I installed the 64Bit Ultimate Edition 2.0 version and then simply installed the Server Kernel. Works brilliantly. Here are the hurdles you will have to overcome to run on a 64bit system.</div>
<div id="_mcePaste">Download Notes 8.5 for debian platforms and extract the files.<span id="more-9"></span></div>
<blockquote>
<div id="_mcePaste">sudo dpkg -i –force-architecture ibm_lotus_notes-8.5.i586.deb</div>
<div id="_mcePaste">sudo dpkg -i –force-architecture ibm_lotus_activities-8.5.i586.deb</div>
<div id="_mcePaste">sudo dpkg -i –force-architecture ibm_lotus_cae-8.5.i586.deb</div>
<div id="_mcePaste">sudo dpkg -i –force-architecture ibm_lotus_sametime-8.5.i586.deb</div>
<div id="_mcePaste">sudo dpkg -i –force-architecture ibm_lotus_symphony-8.5.i586.deb</div>
</blockquote>
<div id="_mcePaste">However, you will find that you would not be able to start Notes.</div>
<div id="_mcePaste">Install the requisite 32 bit libraries.</div>
<blockquote>
<div id="_mcePaste">apt-get install ia32-libs</div>
</blockquote>
<div>You need to download the extra 32 bit libraries first. Use Getlibs</div>
<div id="_mcePaste">http://ubuntuforums.org/showthread.php?t=474790</div>
<div id="_mcePaste">Once installed then issue this command.</div>
<blockquote>
<div id="_mcePaste">getlibs -p libavahi-client3 libavahi-common3 libavahi-glib1 libbonoboui2-0 libcroco3 libdbus-1-3 libdbus-glib-1-2 libeel2-2 libgnome2-0 libgnomecanvas2-0 libgnome-keyring0 libgnome-menu2 libgnomeprint2.2-0 libgnomeprintui2.2-0 libgnomeui-0 libgnomevfs2-0 libgsf-1-114 libgsf-1-dev librsvg2-2 librsvg2-common libselinux1 libsepol1 libstartup-notification0 libxkbfile1 gtk2-engines-ubuntulooks gtk2-engines-murrine</div>
</blockquote>
<div id="_mcePaste">Depending on how you did the install the icon would not have been created but all is not lost. Start a Terminal session and change to:</div>
<blockquote>
<div id="_mcePaste">/opt/ibm/lotus/notes/framework/</div>
</blockquote>
<div id="_mcePaste">Now enter</div>
<blockquote>
<div id="_mcePaste">../notes</div>
</blockquote>
<div id="_mcePaste">If you are lucky then a separate console will startup and ask you to accept the license agreement.</div>
<div id="_mcePaste">Because you are starting Notes from a Terminal session you will see how the process starts up and this will help with diagnostics. In any event I had to issue the command three times before Notes would start but I am pleased to say the blog entry is being typed from an Ubuntu 64 bit server so It does work. Time to bite my tongue again.</div>
<p>After you&#8217;ve done this there are some steps to make it almost perfect.</p>
<p>Fonts fix. Install ttf-xfree86-nonfree package (Thanks Bram!)</p>
<pre>yum install ttf-xfree86-nonfree</pre>
<p>Fix Open attachment option. You cannot open attachments from the browser (this has also been seen on 32 bits systems). To fix this remove openwith in the notes directory and make a symlink to gnome-open</p>
<pre>rm /opt/ibm/lotus/notes/openwith
ln -s /usr/bin/gnome-open /opt/ibm/lotus/notes/openwith</pre>
<p>And for the last, start notes with linux32. This fixes that last library issues. Browser works and Sametime.</p>
<pre>cd /opt/ibm/lotus/notes
linux32 ./notes</pre>
<p>This is tested on Jaunty 64bits</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.turabdin.nl/2009/07/installing-ibm-lotus-notes-8-5-on-ubuntu-64bits/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

