I has just the solution! I need to put a new line with table.location = "schemaName" & table.location after applylogoninfo! I found solution here: http://www.codecomments.com/Visual Basic Crystal Reports/message690985.html Thanks for all Cris
Cristina Rodriguez Garcia
Posts
-
Crystal Reports changing oracle odbc connections at runtime -
find listviewitems with keyboard entriesI have something similar handling keypress event of the control, a combobox in my case. Although not is a "beautiful" code, it works fine enough for my problem, find the first letter entry. I hope you can modify it for your owm problem solution: Private Sub ComboBoxMacge_KeyPress(ByVal sender As Object, ByVal e As System.Windows.Forms.KeyPressEventArgs) Handles MyBase.KeyPress Try Dim cb As ComboBox = CType(sender, ComboBox) Dim findString As String = String.Empty If (Not e.KeyChar.IsLetter(e.KeyChar, 0)) Then Exit Sub findString = Char.ToUpper(e.KeyChar) If cb.DropDownStyle <> ComboBoxStyle.DropDownList Then If cb.SelectedText <> cb.Text Then findString = cb.Text & Char.ToUpper(e.KeyChar) End If End If Dim IDX As Integer = -1 With cb Dim ELE As Integer = 0 Dim R As DataRow Dim DW As DataRow() = Nothing Try DW = CType(.DataSource, DataRow()) Catch Try DW = CType(.DataSource, DataTable).Select() Catch ex As Exception End Try End Try If DW Is Nothing Then Dim s As String For Each s In cb.Items ' Se distinguen los que tienen codigo o los que no: Dim idxGuion As Integer = s.IndexOfAny("-") Dim pos As Integer If idxGuion < 0 Then ' no hay guion pos = 0 Else pos = idxGuion + 2 End If If s.IndexOf(findString) = pos Then IDX = ELE Exit For End If ELE += 1 Next Else For Each R In DW ' Se distinguen los que tienen codigo o los que no: Dim idxGuion As Integer = R(cb.DisplayMember).IndexOfAny("-") Dim pos As Integer If idxGuion < 0 Then ' no hay guion pos = 0 Else pos = idxGuion + 2 End If
-
Crystal Reports changing oracle odbc connections at runtimeI have a problem. I have a report that in design time link with database with an odbc (Oracle provider). In runtime if i don´t change connection it works fine. My problem is that if i change de odbc (i try other odbc with other name but with same dns) at runtime, it doesn´t work. Only works if i change odbc connection in report at design time...but i need do it programtilly because i need user choose between two equals databases: real and testing. I try with code like Me.rptDoc.DataSourceConnections.Item(0).SetConnection("ODBCNAME", "", False) and other codes like that: Dim crConnectionInfo As ConnectionInfo Dim crDatabase As Database Dim crTables As Tables Dim crTableLogOnInfo As TableLogOnInfo Dim crReportDocument As ReportDocument = Me.rptDoc crDatabase = crReportDocument.Database crTables = crDatabase.Tables crConnectionInfo = New ConnectionInfo() crConnectionInfo.ServerName = "ODBCNAME" crConnectionInfo.DatabaseName = "" crConnectionInfo.UserID = "USER" crConnectionInfo.Password = "PASSWORD" For Each aTable As CrystalDecisions.CrystalReports.Engine.Table In crTables crTableLogOnInfo = aTable.LogOnInfo crTableLogOnInfo.ConnectionInfo.AllowCustomConnection = True crTableLogOnInfo.ConnectionInfo = crConnectionInfo aTable.ApplyLogOnInfo(crTableLogOnInfo) Next Could you help me?, thanks in advance Cristina
-
How Managed C++ client connect to https urlHello all, I am programming a application in Managed C++ that simules a client of a web commerce site. Some of pages of this site are SSL secures, and I don´t know what I have to do until to call HttpWebRequest. Have I to configured something on the computer or simply I have to programming something else? I saw example of "How to do Synchronous and Asynchronous web downloads" By Nishant S, but it doesn´t work with https, also. I am very lost :confused:. any idea? any example code? Thanks, Cris Sorry and Excuse my poor English writting!!!