OracleConnection ~ Connection String Nightmare

I spent quite a bit of time today debugging an oracleconnection object. It would fail everytime the connection string property was set. This is what I would recieve in the error log:

Faulting module name: KERNELBASE.dll, version: 6.1.7601.17651, time stamp: 0x4e2111c0

Exception code: 0xe0434f4d

Fault offset: 0x0000d36f

I didn’t get to far Duck Duck Go’ing (or Googling) on this so I threw the assignment into an try catch block. I got an error  “Connection string is not well formed”. Connectionstrings.com had a great section on Oracle so I copied/pasted it into my code changing the pertinent data. Same issue.

After trying several things I discovered that the connection strings for Oracle cannot have a trailing semi-colon.

Data Source=IDWorks;User Id=IDWorks;Password=idw;

Data Source=IDWorks;User Id=IDWorks;Password=idw

Hope this saved you some time!

Advertisements

DataGridViewComboBoxColumn requires multiple clicks to select an item

I am reposting this because I think this guy did a good job posting this. I wish I got to this first! 🙂

DataGridViewComboBoxColumn requires multiple clicks to select an item.

DirectoryOperationException – The object does not exist.

System.DirectoryService.Protocols Library

This was a very frustrating error. I was able to connect to LDAP through LDAPadmin but not through a program I was creating. “The object does not exist” error occurs, at least in my experience when the credentials you are passing to the server do not authenticate.

In this case I was getting nowhere. Resorting to Wireshark, filtering against port 389, which is the port for LDAP resulted in me seeing a backslash in the credentials being passed as well as the username coming after the organization, which is wrong for my environment.

The resolution was to set the domain to nothing in VB or null in C# in my Net.NetworkCredential object. At the same time moving the organization to the username property.

Dim credLDAP As New Net.NetworkCredential(“cn=username”,”password”, “o=domain”)
does not work, but this does:
Dim credLDAP As New Net.NetworkCredential(“cn=username,o=domain”,”password”, nothing)

MS Access Error: Too few parameters. Expected x

If you are getting this error it means you are probably working. Here is the deal: this error happens when you try to access an Access Database through ODBC or OLEDB. Chances are you are trying to use Access’s standard of using double quotes (“), replace them with single quotes(‘) and you should be off and running.

If that still didn’t fix your problem the error is probably quite literal in that you forgot to add a parameter to your query or that you are missing some search criteria.

Let me know if this doesn’t work for you and I can help you get up and running.

Fun With Images and Photographs – Photosynth

This is very interesting and compelling. Anyone have an other great ideas for processing of images? What are your plans for images? I would love to hear them as I am planning my own project similar to this one but to a different end and for a different purpose.

IIS Frontpage Extensions – You are not authorized to view this page

If you get this error something changed with your environment that is forcing anonymous login to the server. Here is what to do:

Within IIS Manager, right click on the site in which you need access to. Click on the directory security tab. Click on the edit button within Authentication and Access control. Click on Integrated Windows Authentication.

Enjoy! Of course your account will actually need rights to the site in question.

Visual Studio – Data Binding: “The operation could not be completed. Access denied.”

I ran into this problem yesterday and let it go until this morning. I got this error message and had a hard time figuring it out.  Here is a link to the MSDN Forum thread discussing this: http://social.msdn.microsoft.com/forums/en-US/vblanguage/thread/94868d04-de4f-44a9-a362-4ffb1f130bae

This particular thread is specific to Visual Studio Express but is really applicable to all editions of Visual Studio 2005.

The Solution

Open your project’s properties tab.

In the Debug section uncheck “Enable the Visual Studio hosting process”.

This will allow you to find out in more detail what the problem is. In my case I forgot to code in the password in the connection string.

Afterwards, you can check the “Enable the Visual Studio hosting process” option again.