Get the field you want by name from ReportObjects, and that field has the properties of Left, Top, Height and Width. Note that you have to use the Section of the report. You can also use the report already in a Crystal Viewer control:
I used to rock and roll every night and party every day. Then it was every other day. Now I'm lucky if I can find 30 minutes a week in which to get funky. - Homer Simpson
Imports CrystalDecisions.Shared
Imports CrystalDecisions.CrystalReports.Engine
Public Class Form1
Public cryRpt As New ReportDocument
Private Sub Form1_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load
load_report()
End Sub
Public Function load_report()
Try
cryRpt.Load("\\10.4.160.231\db\Reports\BSS.rpt")
gen_report()
Catch ex As Exception
MsgBox(ex.Message.ToString)
End Try
CrystalReportViewer1.ReportSource = cryRpt
CrystalReportViewer1.Refresh()
End Function
Public Function gen_report()
Try
Dim A As Integer = 2
Dim crtableLogoninfos As New TableLogOnInfos
Dim crtableLogoninfo As New TableLogOnInfo
Dim crConnectionInfo As New ConnectionInfo
Dim CrTables As Tables
Dim CrTable As Table
With crConnectionInfo
.ServerName = "images"
.DatabaseName = "BBS.mdb"
.UserID = ""
.Password = ""
End With
CrTables = cryRpt.Database.Tables
For Each CrTable In CrTables
crtableLogoninfo = CrTable.LogOnInfo
crtableLogoninfo.ConnectionInfo = crConnectionInfo
CrTable.ApplyLogOnInfo(crtableLogoninfo)
Next
Dim crParameterDiscreteValue As ParameterDiscreteValue
Dim crParameterFieldDefinitions As ParameterFieldDefinitions
Dim crParameterFieldLocation As ParameterFieldDefinition
Dim crParameterValues As ParameterValues
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.