Quantcast
Channel: VBForums
Viewing all articles
Browse latest Browse all 15151

VS 2013 Setting Top and Left values in Crystal Reports using VS 2013 / VB.net

$
0
0
Hello everyone,

I am making a cheque printing program for which I want user to set left & top vales for date field.

Here is my code. Please help me how can I set left and top margin for formula name : 201_CounterDate

Code:


  '
        '

        '
        If SearchText1 = "RptChequePrint" Then

            Try
                CReport.Load(Application.StartupPath & "\RptChequePrint.rpt")
                CReport.RecordSelectionFormula = SearchText2

                Dim fieldObject1 As FieldObject
                Dim section = CReport.ReportDefinition.Sections("Details")


                CReport.DataDefinition.FormulaFields.Item("201_CounterDate").Text = "'" & Glb201_CounterDate & "'"

                fieldObject1 = TryCast(section.ReportObjects("201_CounterDate"), FieldObject)
                fieldObject1.Left = Val(Glb201_CounterDateX)



            Catch ex As Exception
                MessageBox.Show(Err.Description, "Info.", MessageBoxButtons.OK, MessageBoxIcon.Information)
                Me.Close()
                Return
            End Try
        End If

Thank you
Ladak

Viewing all articles
Browse latest Browse all 15151

Trending Articles