Crystal Report Selection Formula Problem

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mehtaprashant19
    New Member
    • Mar 2008
    • 1

    #1

    Crystal Report Selection Formula Problem

    i have a problem with Crystal Report,

    i am giving a SelectionFormul a to the Crystal Report Viewer,

    but it is giving me all the records

    If Session("Rep") Is Nothing Then
    Dim ConnInfo As New ConnectionInfo
    With ConnInfo
    .ServerName = ".sqlexpres s"
    .DatabaseName = "MTS_NEW"
    .UserID = "marc"
    .Password = "marc"
    End With

    Dim rep As New ReportDocument
    rep.Load(Server .MapPath("Cryst alReport1.Rpt") )
    rep.DataDefinit ion.GroupSelect ionFormula = "{MT_Rights.Rig htsGivenTo}=68"
    Me.CrystalRepor tViewer1.Report Source = rep
    Dim RepTbls As Tables = rep.Database.Ta bles
    For Each RepTbl As Table In RepTbls
    Dim RepTblLogonInfo As TableLogOnInfo = RepTbl.LogOnInf o
    RepTblLogonInfo .ConnectionInfo = ConnInfo
    RepTbl.ApplyLog OnInfo(RepTblLo gonInfo)
    Next
    Session("Rep") = rep
    End If

    Me.CrystalRepor tViewer1.Report Source = Session("Rep")
    Me.CrystalRepor tViewer1.DataBi nd()

    so what should i do,
    please do the needfull
    thanks in advance

    thanks & regards,
    Prashant Mehta
Working...