Data Connectivity
 Crystal Reports Forum : Crystal Reports for Visual Studio 2005 and Newer : Data Connectivity
Message Icon Topic: Microsoft.Jet.OLE DB.4.0 ,Crystal Report and .NET Post Reply Post New Topic
Author Message
manojkgr
Newbie
Newbie


Joined: 11 Feb 2009
Online Status: Offline
Posts: 1
Quote manojkgr Replybullet Topic: Microsoft.Jet.OLE DB.4.0 ,Crystal Report and .NET
    Posted: 11 Feb 2009 at 9:08pm

Hi,

 

I have an application using MS Access database and the application is developed using VS.net 2005 and .NET framework 2.0.

 

Req:

  1. Need to set up a DSN-less Crystal Report XI using MS Access 2003
  2. Need to use “Microsoft.Jet.OLE DB.4.0” provider to connect database.
  3. The database location will change in every installation.
  4. Database is protected by user id and password

 

Issue:

I am facing login failed error when the application tried to open report at runtime. Error message “Logon Failed. Please try again.” The problem is that I used Microsoft.Jet.OLE DB.4.0 at design time and  provided database details at runtime.

 

Note: Application is working well when I used DAO provider in the report at design time.

 

In .Net , I added codes shown below ;

 

objReport.Load(prReportName)

objReport.DataSourceConnections.Item(0).IntegratedSecurity = False

objReport.DataSourceConnections.Item(0).SetConnection("", strDBLocation, False)

objReport.DataSourceConnections.Item(0).SetLogon("Admin", Password)

rptViewer.ReportSource = objReport

Me.rptViewer.Refresh()

Me.Show()

 

Thanks,

Manoj Nair



Edited by manojkgr - 11 Feb 2009 at 9:19pm
IP IP Logged
Post Reply Post New Topic
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum



This page was generated in 0.031 seconds.