Skip to Content
0

DatabaseController.SetTableLocationEx throws Logon failed

Mar 10, 2017 at 08:16 AM

41

avatar image

Hi,

We run across a strange behavior with SetTableLocationEx which returned the following error:

"[Code du fournisseur de la base de données : -2147217887 ] Erreur dans le fichier xxx.rpt : Connexion impossible : les paramètres de connexion sont incorrects."
in English "Logon Failed. Error in File xxx.rpt: Unable to connect: incorrect log on parameters."

This problem occurred on one PC, but not on another one!

While analyzing the problem I tried to start a Verify Database in CR Designer (2011); here the same behavior, the Verify worked on one PC but not on another one:

On a Windows 10 PC it worked, but not on Windows 7 or 8.1. After further research, we found out that the Locale Identifier on one table was the problem:

The normal Locale ID we use is "German (Luxemburg)" = 4103, but 3072 is a new Windows 10 Locale for "German (Belgium)" which does not exists on Windows 7 or 8.

see also: Microsoft Locale ID Values

It would be great if an exception on SetTableLocationExcould could point on to the problem to the Locale ID in this case.

Thanks,

Patrick

crlogon1.png (16.7 kB)
crlogon2.png (8.0 kB)
10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

1 Answer

Best Answer
Don Williams
Mar 13, 2017 at 04:08 PM
0

Hi David,

CR does not "fix or suggest how to fix" DB client or DB Server issues. To do something like that would be a huge amount of work to write in and maintain, we have no control over what DB Server/Clients can do or how they work or when they change etc. All we can do is pass along the message from the Client, if it doesn't report specific details we can't pass them along to you.

I suggest you post an enhancement request to the dB makers to auto-adjust the language settings for each OS.

See if the Inner Exception in your app would be able to capture the same error as CRD is reporting.

Something like this:

catch (Exception ex)
{
if (ex.Message.ToString() == "Object reference not set to an instance of an object.")
MessageBox.Show("ERROR: Object reference not set to an instance of an object.");
else
if (ex.Message.ToString() == "External component has thrown an exception.")
{
MessageBox.Show("ERROR: External component has thrown an exception.");
}
else
{
{
if (ex.InnerException.Message != null)
{
MessageBox.Show("ERROR: " + ex.Message + " ;" + ex.InnerException.Message);

////cool but of no use to release mode
//string myURL = @"http://search.sap.com/ui/scn#query=" + ex.InnerException.Message + "☆tindex=1&filter=scm_a_site%28scm_v_Site11%29&filter=scm_a_modDate%28*%29&timeScope=all";
//string fixedString = myURL.Replace(" ", "%20");

////System.Diagnostics.Process.Start(@"C:\Program Files (x86)\Internet Explorer\iexplore.exe", myURL);
//System.Diagnostics.Process.Start(@"C:\Program Files (x86)\Mozilla Firefox\firefox.exe", fixedString);

////string myURL = @"C:\Program Files (x86)\SAP BusinessObjects\Crystal Reports 2011\Help\en\crw.chm";
////System.Diagnostics.Process.Start(myURL);
////cool but of no use to release mode

}
else
{
MessageBox.Show("ERROR: " + ex.Message);
}
}
}

Don

Share
10 |10000 characters needed characters left characters exceeded