Crystal11 and VB6 "logon failed"

What I am trying to do is change a VB6/SQL program to use windows authentication. Everything works fine except the Crystal reports.  I went into each report and changed my connections from DSN to Windows Authentication.  I selected the server and the database.
The reports looks fine and displays fine in Crystal.  
The I tested the reports in my VB6 program.  I changed the associated variables to now use windows authentication.

When I tested the reports, they WORKED.
But then if I alter the report in any way, something happens and I get a "Logon Failed"

This is all happening on the same machine.

Why did it work the first time when I Initially changed to the windows authentication but then stops once any change is done to the report?

Let me know what other informatopn you may need.

Thank you,

Jerry

Here is the original DSN Login (Commented out) and the new Windows Authentication login
    For Each crxDataTable In crxReport.Database.Tables
'      crxDataTable.SetLogOnInfo gbServer, gbDatabase, gbUserID, gbPW
      crxDataTable.SetLogOnInfo gbDataServer, gbDatabase, "<<Use Integrated Security>>", vbNullString
 
      I = InStr(crxDataTable.Location, ".")
      If I = 0 Then
         crxDataTable.Location = gbDatabase & ".dbo." & crxDataTable.Location
      Else
         crxDataTable.Location = gbDatabase & Mid$(crxDataTable.Location, I)
      End If
 
      If Not crxDataTable.TestConnectivity Then
         sMsg = "Unable to connect to database."
         Set crxReport = Nothing
         Set crxApp = Nothing
         Exit Sub
      End If
    Next

Open in new window

jerrystefaniakAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

mlmccCommented:
Did you reset the report to use WIndows authentication?

mlmcc
0
mlmccCommented:
What kind of chnages did you make?

mlmcc
0
jerrystefaniakAuthor Commented:
Actually all I had to do was make the size of a reporting field bigger and save the change and then the report no longer logs in.

How do I make sure that windows Auth is set right?

I just noticed something.
When I open one of my reports and tell it to Verify Database, it comes up with the connection Information box with nothing filled in.  It's as if the original values are not being saved with the report?

I think I reset the report to use windows authentication.  Attached are pics.  Hope it helps.

I
Login-Failed-01.doc
0
10 Tips to Protect Your Business from Ransomware

Did you know that ransomware is the most widespread, destructive malware in the world today? It accounts for 39% of all security breaches, with ransomware gangsters projected to make $11.5B in profits from online extortion by 2019.

jerrystefaniakAuthor Commented:
It seems that whenever I go into Crystal the first time, the login fails.  After two or three attempts, then it takes and then subsequent reports open fine

Jerry
0
mlmccCommented:
Is it the same report that gives trouble or do all reports fail if tried first

mlmcc
0
jerrystefaniakAuthor Commented:
It seems that it's all reports.  Any report that I change in any way seems to break the login routine.
0
mlmccCommented:
You may need to go into each report and use the SET DATABASE LOCATION under the DATABASE menu.  You then change the reports to use WIndows Authentication

mlmcc
0
jerrystefaniakAuthor Commented:
I DID go into every report and set the database location.  Everything seemed to work fine until I  try to alter a report...When you say Windows Authentication do you mean that little checkbox that says ISS Security?  (I think that's what the box says.  I'm not at my computer to check)  Because each report had the location changed and that box was checked.

Let me know if there is something I have missed.  I hope so!  this is frustrating.

Thanks
0
jerrystefaniakAuthor Commented:
Basically what I am seeing here is that whenevr I go back into a Crystal Report, I have to reenter the connection information.  I never saw this when I was using a DSN with a UserID and Password (for the past 10 years).  Now that our auditors want us to go to Windows Authentication, now I am being asked everytime for the connection.

Have I missed something??
0
jerrystefaniakAuthor Commented:
Dear mlmcc:,
I want to give you more info hopefully it will help.

What I have also done is tried to uninstll Crystal 11 and Crystal 11 Rel 2.  I was able to remove Crystal 11 and reinstall but I cannot remove  Release 2.  I get a weird error message right at the end of the uninstall process.

Could this be a factor?

Thank you. . . . jerry
0
mlmccCommented:
It could be but I doubt it.

We built a large project and used Windows Authentication or Integrated Security for the reports.  as I recall when I opened a report I had to give me logon and password but the users never reported a problem.  It has been too long ago to really remember.  

mlmcc
0
jerrystefaniakAuthor Commented:
When I try to remove All Crystal 11 Releasae 2 I get a message "Error 1316: A network error occured while attempting to read from the file: C:\WINDOWS\Installer\CrystalReports.msi"

Is there anything I can do to remove Release 2?

Also, is there any more information I can give you to help me with this login problem?  I am totally stuck here and have no idea where to turn.

thank you.
0
mlmccCommented:
I wonder if that file disappears when you uninstall CR XI R1.

Try setting th elocation before the logon

   For Each crxDataTable In crxReport.Database.Tables
      I = InStr(crxDataTable.Location, ".")
      If I = 0 Then
         crxDataTable.Location = gbDatabase & ".dbo." & crxDataTable.Location
      Else
         crxDataTable.Location = gbDatabase & Mid$(crxDataTable.Location, I)
      End If
'      crxDataTable.SetLogOnInfo gbServer, gbDatabase, gbUserID, gbPW
      crxDataTable.SetLogOnInfo gbDataServer, gbDatabase, "<<Use Integrated Security>>", vbNullString
 
mlmcc
0
jerrystefaniakAuthor Commented:
1.  Originally I tried uninstalling Rel 2 first and got the same error.  Then I just uninstalled Rel 1 out of desperation.

2.  I tried your idea but I die on a login error as soon as it executes the crxDataTable.Location = gbDatabase & ".dbo." & crxDataTable.Location command.  I guess it requires a valid login in order to set its locations.

Jerry

0
jerrystefaniakAuthor Commented:
I'm at my wits end here.  Do you have a operson maybe at Crystal that I could possibly contact.  I would be willing to let them use LogMeIn in order to get on my computer and see what's wrong.  I have no idea whether it's my computer, my set up or a bug somewhere.

Let me know if there is a contact.

Thank you,

Jerry
0
mlmccCommented:
I don't know.  I don't have any contacts at Crystal

mlmcc
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
jerrystefaniakAuthor Commented:
Dear mimcc,
Do you know how it feels when you've spent tons of time doing a job one way and then find there was a simpler way all along?  Well my problem is that I was using DSN's to link the reports to the system.  After I removed the DSN and changed all my reports to read from my server, I decided to see if the same problem would occur at my user's site.

Well, my reports would not work because they were linkd to my server at home - hard linked.  And I thought, "Oh hell, I'm going to have to change these reports everytime I move them to my user's system.  And then the light dawned.

All I had to do in order to get the reports to use windows Authentication was to change the DSN to use Windows Authentication.  Simple.

I don't know what was causing the original problem here but I don't care.  The reports are now using Windows Auth without haing to change a thing.

I'm going to give you the points anyway because you spent time trying to help.

Thanks

0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
DB Reporting Tools

From novice to tech pro — start learning today.