Click here to Skip to main content
15,886,873 members
Home / Discussions / Visual Basic
   

Visual Basic

 
GeneralRe: Regarding Windows Registry Pin
Ashfield16-Apr-08 0:51
Ashfield16-Apr-08 0:51 
GeneralRe: Regarding Windows Registry Pin
Dave Kreskowiak16-Apr-08 3:30
mveDave Kreskowiak16-Apr-08 3:30 
QuestionRe: Regarding Windows Registry Pin
vijaylumar16-Apr-08 18:54
vijaylumar16-Apr-08 18:54 
GeneralRe: Regarding Windows Registry Pin
Dave Kreskowiak17-Apr-08 1:31
mveDave Kreskowiak17-Apr-08 1:31 
Questionregarding creating Help File for vb.net 2.0 windows application Pin
vijaylumar15-Apr-08 20:08
vijaylumar15-Apr-08 20:08 
AnswerRe: regarding creating Help File for vb.net 2.0 windows application Pin
Arjun Marwaha15-Apr-08 20:42
Arjun Marwaha15-Apr-08 20:42 
GeneralRe: regarding creating Help File for vb.net 2.0 windows application Pin
Smithers-Jones15-Apr-08 23:32
Smithers-Jones15-Apr-08 23:32 
GeneralCRAXDRT.ConnectionPropertiesClass.getItem(String Name) "Error: Invalid Index" Pin
vbDigger'z15-Apr-08 19:32
vbDigger'z15-Apr-08 19:32 
anybody who knows or have an idea about this error in VB2005 and CrystalRport XI R2 and MS ACCESS?

CRAXDRT.ConnectionPropertiesClass.getItem(String Name) "Error: Invalid Index"

Here's my code:
************************
<br />
<br />
    Public crxApp As CRAXDRT.Application<br />
    Public crxReport As CRAXDRT.Report<br />
    Public crxDataBase As CRAXDRT.Database<br />
    Public crxTable As CRAXDRT.DatabaseTable<br />
    Public crxTables As CRAXDRT.DatabaseTables<br />
    Public crxConnectionProperty As CRAXDRT.ConnectionProperty<br />
<br />
<br />
    Public strSelectionfrm As String<br />
    Public strCRSourcePath As String<br />
<br />
Private Sub frmCrystalReport_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load<br />
        Try<br />
            ChildFormAutoSizeFit(Me)<br />
            Me.Cursor = Cursors.WaitCursor<br />
            Me.MdiParent = frmMain<br />
            Dim i As Integer = 0<br />
<br />
            crxApp = New CRAXDRT.Application<br />
<br />
            crxReport = crxApp.OpenReport(strCRSourcePath, CrystalDecisions.Shared.OpenReportMethod.OpenReportByDefault)<br />
<br />
            crxTables = crxReport.Database.Tables<br />
<br />
            For Each crxTable In crxReport.Database.Tables<br />
<br />
                'Note: The error occurs here<br />
                crxConnectionProperty = crxTable.ConnectionProperties("Data Source") = crxDataBasePath<br />
                crxConnectionProperty = crxTable.ConnectionProperties("Database Name") = myDataBasePath & "\dbEmployee.mdb"<br />
                crxConnectionProperty = crxTable.ConnectionProperties("User ID") = "myUserID"<br />
                crxConnectionProperty = crxTable.ConnectionProperties("Password") = "myPassword"<br />
            Next crxTable<br />
<br />
            crxReport.Database.Verify()<br />
<br />
            crxReport.SQLQueryString = strSelectionfrm<br />
<br />
            AxCRViewer1.ReportSource = crxReport<br />
            AxCRViewer1.ViewReport()<br />
<br />
            crxDataBase = Nothing<br />
            crxTable = Nothing<br />
            crxTables = Nothing<br />
            crxReport = Nothing<br />
            crxApp = Nothing<br />
<br />
        Catch ex As Exception<br />
            MsgBox(ex.ToString())<br />
        Finally<br />
            Me.Cursor = Cursors.Default<br />
        End Try<br />
    End Sub<br />

*******************

actually i know that the error's occurs on the part where..

crxConnectionProperty = crxTable.ConnectionProperties() -->indexing or string name..
but i have just follow it from other forums that works for them..

anybody who have a good solutions about this error?? Please help... Im so frustated to figure it out myself... Frown | :(
GeneralRe: CRAXDRT.ConnectionPropertiesClass.getItem(String Name) "Error: Invalid Index" Pin
_Damian S_15-Apr-08 19:59
professional_Damian S_15-Apr-08 19:59 
GeneralRe: CRAXDRT.ConnectionPropertiesClass.getItem(String Name) "Error: Invalid Index" Pin
vbDigger'z15-Apr-08 21:22
vbDigger'z15-Apr-08 21:22 
GeneralRe: CRAXDRT.ConnectionPropertiesClass.getItem(String Name) "Error: Invalid Index" Pin
_Damian S_16-Apr-08 18:07
professional_Damian S_16-Apr-08 18:07 
GeneralRe: CRAXDRT.ConnectionPropertiesClass.getItem(String Name) "Error: Invalid Index" Pin
vbDigger'z16-Apr-08 21:56
vbDigger'z16-Apr-08 21:56 
GeneralRe: CRAXDRT.ConnectionPropertiesClass.getItem(String Name) "Error: Invalid Index" Pin
Mycroft Holmes15-Apr-08 22:07
professionalMycroft Holmes15-Apr-08 22:07 
GeneralRe: CRAXDRT.ConnectionPropertiesClass.getItem(String Name) "Error: Invalid Index" Pin
vbDigger'z15-Apr-08 22:19
vbDigger'z15-Apr-08 22:19 
GeneralRe: CRAXDRT.ConnectionPropertiesClass.getItem(String Name) "Error: Invalid Index" Pin
ChandraRam15-Apr-08 23:56
ChandraRam15-Apr-08 23:56 
GeneralRe: CRAXDRT.ConnectionPropertiesClass.getItem(String Name) "Error: Invalid Index" Pin
vbDigger'z16-Apr-08 14:21
vbDigger'z16-Apr-08 14:21 
GeneralRe: CRAXDRT.ConnectionPropertiesClass.getItem(String Name) "Error: Invalid Index" Pin
ChandraRam16-Apr-08 19:52
ChandraRam16-Apr-08 19:52 
GeneralRe: CRAXDRT.ConnectionPropertiesClass.getItem(String Name) "Error: Invalid Index" [modified] Pin
vbDigger'z16-Apr-08 21:53
vbDigger'z16-Apr-08 21:53 
GeneralI think so i know whats wrong with my vb project... its not on the code but the versioning of active x component [modified] Pin
vbDigger'z17-Apr-08 18:04
vbDigger'z17-Apr-08 18:04 
Questionextract OLE Object from MS-Access Table using vb6 Pin
ERLN15-Apr-08 18:05
ERLN15-Apr-08 18:05 
GeneralRe: extract OLE Object from MS-Access Table using vb6 Pin
Dave Kreskowiak16-Apr-08 3:23
mveDave Kreskowiak16-Apr-08 3:23 
GeneralException has been thrown by the target of an invocation Pin
tom8315-Apr-08 17:56
tom8315-Apr-08 17:56 
GeneralRe: Exception has been thrown by the target of an invocation Pin
Arjun Marwaha15-Apr-08 20:50
Arjun Marwaha15-Apr-08 20:50 
GeneralRe: Exception has been thrown by the target of an invocation Pin
Mycroft Holmes15-Apr-08 22:11
professionalMycroft Holmes15-Apr-08 22:11 
GeneralRe: Exception has been thrown by the target of an invocation Pin
tom8316-Apr-08 3:01
tom8316-Apr-08 3:01 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.