Category Archives: Technology

Making Cisco VPN client work on Windows 8

If you have upgraded to Microsoft Windows 8 Developer Preview or Release Preview, you may have noticed the inability to connect to a VPN through the Cisco VPN Client software. This article specifically references Version 5.0.07.0290.

The connection attempts are not successful when trying to connect to a VPN network.

You need to apply a fix within the registry in order to make this work, and it is relatively easy. If you are not familiar with Windows Registry, do not attempt this fix. You can easily cause harm to your system if you do not know what you are doing!

Open the registry and navigate to HKEY_LOCAL_MACHINE \ SYSTEM \ CurrentControlSet \ Services \ CVirtA

There is a value called “Display Name” and there are a bunch of characters preceding the text “Cisco Systems VPN Adapter”. It may be something like @oem7.inf,%CVirtA_Desc%;

Change the text of the “DisplayName” value to only read “Cisco Systems VPN Adapter” by removing the preceding data. See the screenshot for an example.

Fixed value in the registry to make Cisco VPN Client work in Windows 8

Sprint Buyback Program

Thinking about utilizing Sprint’s Buyback program for your recently abandoned phone?

If changing from Sprint service to a different carrier, you most likely will not be able to use your existing phone. Sprint has some fairly attractive buyback amounts to purchase your used phone from you and you would think if they offer you the buyback program, that you would be qualified for the credit.

Think twice before you send your phone in, or at least read the rules and regulations twice. Sprint will approve you to send in your phone even when the line is no longer active. Then, they will receive the device but will not credit you if you don’t have an active line. They will also refuse to send you your phone back. Don’t give Sprint a free used phone, read the guidelines and make sure you will qualify.

I/O Error: SSO Failed: Native SSPI Library not Loaded

When this error is encountered, it is because a process is seeking to use your windows credentials to connect to a Microsoft SQL Server.  When a Java application using jDTS attempts  a Single Signon to MS SQL Serve, a library is needed on the machine.  This is the ntlmauth.dll library which is often missing when you move your code from development to production.

This file must exist in the system’s path.  When on a Windows system, a good place to put it is in the Windows\System32 folder.
The library is available for download from the jDTS project at the following address: jDTS Project – Downloads

If this is not the specific issue you are encountering, check out this other issue when working in Talend Open Studio relating to Native SSPI Library not Loaded: Talend Open Studio – Native SSPI Library Not Loaded – v5.1.1

Creating Page Links Using getElementsByTagName and addEventListener

The following is a tutorial on how to make all div elements clickable on a web page.  Handle click events on all div tags or on any specific element type in your HTML.

Do you have a need on your HTML page to create links using all the elements of a specific type.  For example, you want all “div” elements to become links that provide some sort of action in javascript.  This can be accomplished using two main functions available in javascript.  The getElementsByTagName and addEventListener functions.

The way this is handled is to create an anonymous function that adds event listeners to your page when it loads.  These event listeners then pass the event to a function that uses a switch statement and the div ID to set specific logic for each div.

We start by creating a basic HTML page that ends with the call to our script as seen below:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
<html>
 
<head>
	<title>Make Divs Clickable!</title>
</head>
<body>
	<div style="background-color: black" id="FirstDiv">
              <h2 style="color: white">Click this div to say: FirstDiv</h2>
        </div>
 
	<div style="background-color: black" id="SecondDiv">
              <h2 style="color: white">Click this div to say: SecondDiv</h2>
        </div>
 
	<div style="background-color: black" id="ThirdDiv">
              <h2 style="color: white">Our third div is not handled</h2>
        </div>
 
	<script type="text/javascript" src="test.js" ></script>
 
</body>
 
</html>

Next, we create the following anonymous function in our javascript file which adds the event listeners and sets up the handling of the different div ID’s.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
//create an anonymous function
(function() {
 
	//get all of our div elements
	var links = document.getElementsByTagName("div");
 
	//add an event handler to all of the page elements
	for( var i = 0, len = links.length; i < len; i++) {
		//add an event listener to our div
		links[i].addEventListener("mousedown", elementClickHandler);
 
 
	}
 
 
	function elementClickHandler(event) {
		//get the ID from the event
		var elementID = event.currentTarget.id;
 
		//do something based on the ID
		switch(elementID) {
		case "FirstDiv":
			//do something
			alert(elementID);
			break;
		case "SecondDiv":
			//do something
			alert(elementID);
			break;
		default:
			//do something
			alert("Some other div not Handled");
		}
	}
 
})();

That’s all there is to it. If you would like to download the ZIP file for this example, it is available via the link Make-div-Elements-Clickable.

Utility for converting JDEDebug log files to XML for Easier Viewing

TeechMi.com is offering a free utility to make the lives of JDE EnterpriseOne developers easier.  The JDE Debug log file contains a lot of useful information, but also a lot of non-useful information.  This utility takes a JDEDebug.log file and converts it to a hierarchical XML file.  Also, it strips it down to just function inputs and outputs and SQL statements executed.  Turn thousands of lines of log file into something much more quickly read.

Download the file, extract it and view the readme for instructions.

Download of ZIP File:   JDELog2XML.zip

Here is a screen shot of the script to run it:

Use this script to point the program to the input JDEDebug.log file and designate the output XML file for converting the log

 

Java Error – Unresolved Compilation Problem: Unhandled Exception Type FileNotFoundException

A typical issue when working with files in Java is a FileNotFoundException during program compilation, even though the program has not yet tried to find the file.  You may see some of the following symptoms:

Unresolved Compilation Problem given when trying to run the program through the Java compiler.

Or the following, as seen in the Eclipse Development Environment:

Eclipse shows Unhandled Exception Type FileNotFoundException

The reason for these errors is that you need to handle the possible exception, in case a value is passed into the constructor for FileInputStream that is not a valid file.  A good way to handle this exception is by adding a throw condition on the function declaration as seen below:

Adding a “throws” statement to the function declaration allows the function to handle potential exceptions properly.

Another way, and probably the best way to handle this is to add a catch to your try statement.  Then, you can handle the exception with any follow up logic that is needed and allow the function to handle it internally instead of throwing the exception.

Using a catch statement with our try block instead of throwing the exception at the function level.

Happy Coding!

Talend Open Studio – java.sql.SQLException – Native SSPI Library not Loaded

There is a bug in Talend Open Studio for Data Integration version 5.0.2 when trying to connect to SQL Server without passing a user name and password.  Java requires libraries for single signon for this to occur, specifically the ntlmauth.dll file for the system.  However, in Talend Open Studio 5.0.2, having this file does not allow single sign on to Microsoft SQL Server.  This is confirmed on Microsoft SQL Server 2008 R2 64-bit.

When attempting to connect without supplying a username and password, the following error is received:

This issue is fixed in production release 5.1.1 of Talend Open Studio.  A workaround in version 5.0.2 is not available at this time.

Error Adding DB Connection in Talend Open Studio 5.1.1

There is a bug in Talend Open Studio for Data Integration version 5.1.1 when adding a database connection.  It has to do with the jdts component used for Microsoft SQL Server connections.  When adding a new connection you may get one of the following errors:

java.lang.ClassCastException: net.sourceforge.jdts.jdbc.CnnectionJDBC3 cannot be cast to net.sourceforge.jdts.jdbc.CnnectionJDBC2

The above error usually appears the first time you hit the button to “Check” the connection.  The second and subsequent attempts will produce a different error message as follows:

Impossible to initialize the connection !

This is a bug in Talend Open Studio for Data Integration that has a fix already implemented in the future 5.1.2 version.

See details of this bug at:  TDI-21382 SQL Server Connexion Fail

Update on 3/5/2013: The Impossible to Initialize the Connection error has been corrected in a future version.  Check out Talend Impossible to Initialize the Connection.

Should I Switch from Sprint to Boost Mobile?

Sprint and Boost Mobile are a unified company, providing a great network for cell phone users.  Data is fast and reliable and coverage is exceptional.  But is it worth the switch to the lower priced, no-contract Boost Mobile entity?

Sprint offers more phones, which are higher quality with the expense of a contract.  Also, you will find faster data speeds with 4G service available in some areas, but requires a powerful phone to process that additional speed which often is lost in phone hardware deficiencies.

Boost Mobile offers a variety of smart phones that can be bought at slightly higher up front costs, but since there is no contract discount, they are the same price whether you are switching to Boost Mobile or have had them for a week and already want a new phone.  This is convenient to stay up to date with technology.

Should I wait until my contract is up to switch? When switching from an active contract with Sprint to a no-contract Boost Mobile, the phone call was actually transferred back and forth from Boost Mobile customer service and Sprint.  In the end, the early termination fee was not charged and the phone number instantly worked.  There should have been a $50 early termination fee applied for the early Sprint termination, but it was never charged.

Boost Mobile has a great network available to their clients.  For about half the price of Sprint contract service monthly fees, it’s a no-brainer switch to make.

 

Should I Learn PHP?

There are a lot of web programming languages available.  It’s often dificult to choose one, but among web programming one sticks out beyond all the others.  It is PHP (originally and acronym for “Personal Home Page”).

The reasons that PHP make a great language to learn include the following:

  • It runs on web servers that are free to install and run
  • The web servers available run on many different operating systems
  • It is very powerful, like many web programming languages
  • There are great, free development environments available
  • PHP is the backbone to many popular content systems, including WordPress Blogging
Why choose web languages that requires expensive development environments and high licensing costs?  Put your time into learning a language that is free to develop and run, comes with no licensing headaches, and is still powerful.