Solved

server logon problems using vb6 and crystal9

Posted on 2004-09-27
12
411 Views
Last Modified: 2012-05-05
I have been reading problems and solutions on your forum pertaining to this for the last few hours and cannot get any solutions to work.  I have an active x connection on my VB form with a connection to the sq2000 view that the crystal report will need.  I have added the crviewer.  I get the message "logon failed for user myuserid"  I have supplied the user and password in the adodbc properties.  I have resupplied then in a further connection definition.  Somehow, crystal is not retaining these values.

0
Comment
Question by:dstratford
  • 6
  • 3
  • 2
  • +1
12 Comments
 
LVL 100

Assisted Solution

by:mlmcc
mlmcc earned 50 total points
ID: 12162952
Can you supply the code you are using?

mlmcc
0
 

Author Comment

by:dstratford
ID: 12163080
OK the basics are:
dim crystal as craxdrt.application
dim report as craxdrt.report
crviewer.displayborder = false
criewer.displaytabs = false
crviewer.enabledrilldown = false
crviewer.enablerefeshbutton = false

(after pressing start on form)
set crystal = new craxdrt.application
set report = crystal.openreport("the path" & "the report name")
crviewer.reportsource = report
crviewer.viewreport

(somehow crystal is loosing the logon values in the active x and I can't seem to find the correct syntax to pass them on
to crystal at the time crystal is logoning on to the server.  Have tried using
crystal.report.logonserver("crdb_ado.dll",the server,the database,the passwork) but I keep getting syntax errors.
and also substituting "pdsodbc.dll" for "crdb_ado.dl"l.  If I could get the correct syntax here, that might be the solution)
0
 
LVL 42

Assisted Solution

by:frodoman
frodoman earned 300 total points
ID: 12163269
When you used logonserver did you specifiy the userID?  It's missing from your example above:

>> crystal.report.logonserver("crdb_ado.dll",the server,the database,the passwork)

Correct syntax is:  LogOnServer(pDllName as string,pServerName as String,[pDatabaseName],[pUserID],[pPassword])


0
Back Up Your Microsoft Windows Server®

Back up all your Microsoft Windows Server – on-premises, in remote locations, in private and hybrid clouds. Your entire Windows Server will be backed up in one easy step with patented, block-level disk imaging. We achieve RTOs (recovery time objectives) as low as 15 seconds.

 

Author Comment

by:dstratford
ID: 12163346
I did not use the user id as in a previous example on your forum DRRYAN3 omitted this.  I will try your syntax..do I put each value in quotes as he did? or do I need the square barackets?
deen
0
 
LVL 42

Assisted Solution

by:frodoman
frodoman earned 300 total points
ID: 12163363
Quotes - the square brackets denote an optional parameter - if you specify password though you must specify user as well.
0
 

Author Comment

by:dstratford
ID: 12163780
I have tried the above and am still getting syntax errors...it is looking for an = sign at the end.  I am wondering if I even have these .dll files.  
Meanwhile, I see on www.crystaldecisions.com that this is a know issue and they have a fix.  I will try that and post the results at least sometime tommorrow.
Deen
0
 

Author Comment

by:dstratford
ID: 12164345
I have downloaded the crystal9  fix and retried my program with no success.
I get syntax error, expecting =  to the line:
crystal.report.logonserver("crdb_ado.dll","server name","dbname","userid","password")

Help!
0
 
LVL 4

Accepted Solution

by:
avi247 earned 150 total points
ID: 12165194
Try it this way

crystal.report.logonserver "crdb_ado.dll","server name","dbname","userid","password"

Or

conn = crystal.report.logonserver("crdb_ado.dll","server name","dbname","userid","password")
0
 

Author Comment

by:dstratford
ID: 12168414
I just tried both of your suggestions and I get the error message for that line:
"object does not support this property or method"

I have reviewed my VB references and components. Hope you are not giving up.
0
 
LVL 42

Assisted Solution

by:frodoman
frodoman earned 300 total points
ID: 12168997
Have you tried removing the "crystal" reference from the call?  Since you've already executed "set report=..." you should be able to use report.logonserver "dll", "server", "dbname", "user", "pword"

frodoman
0
 

Author Comment

by:dstratford
ID: 12172818
Thank you so much for all your help.  My problem has been solved by the following 2 steps:
1.  Download the service pack from crystal decisions to allow the use of integrated security by adding a registry key and changing the value of this key to yes.  
2.  On the crystal report check the box for integrated security and leave userid and password blank.

This problem can be closed.
0
 
LVL 100

Expert Comment

by:mlmcc
ID: 12205863
Glad i could help

mlmcc
0

Featured Post

Netscaler Common Configuration How To guides

If you use NetScaler you will want to see these guides. The NetScaler How To Guides show administrators how to get NetScaler up and configured by providing instructions for common scenarios and some not so common ones.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
control image tags in a string ? 12 134
VbScript to countdown to New Year's Day 6 56
Help Required 2 33
Help Required 3 97
Does the idea of dealing with bits scare or confuse you? Does it seem like a waste of time in an age where we all have terabytes of storage? If so, you're missing out on one of the core tools in every professional programmer's toolbox. Learn how to …
A short article about a problem I had getting the GPS LocationListener working.
An introduction to basic programming syntax in Java by creating a simple program. Viewers can follow the tutorial as they create their first class in Java. Definitions and explanations about each element are given to help prepare viewers for future …

831 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question