Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

how to connect crystal report with vb.net ?

Answer Posted / kafeel ahmad

Take crystal report from toolbox .Take New form (I named it
frmRpt)Then take crystal report Viewer from tool box and
place it on new form(frmRpt) I named crystal report Viewer
as crptVW
double click on newform(frmRpt) and place this code---

Public Class frmRpt
Public strRptName As Object
Public strRptFilter As String
Private Sub frmRpt_Load(ByVal sender As System.Object,
ByVal e As System.EventArgs) Handles MyBase.Load
If strRptFilter <> "" Then
crptVW.SelectionFormula = strRptFilter
End If
crptVW.ReportSource = strRptName
crptVW.Show()
End Sub
End Class


now if u want to call it on button_click then paste this
code on that button_click event ------

Dim objRpt As New frmRpt
objRpt.strRptName = New crList
' objRpt.strRptFilter = "{ConsultantMaster.ConId}="
& cboConIDX.SelectedValue 'if want to filter
objRpt.Show()

'now u can open as many crystal report just paste code
above on button_click()

Is This Answer Correct ?    8 Yes 8 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

List the types of generations in garbage collector?

910


What is econo-jit?

1146


what is the need for dynamic controls in vb.net? i would like to know for what purpose should we create the controls dynamically? please give the answer in simple words.

2388


What is public assembly?

992


Explain about rapid application development tool?

972


What are the difference between dispose(), close(), exit(), end()? When do we use them?

1041


Tell me how many .net languages can a single .net dll contain?

949


Before in my vb app I would just load the icons from dll. How can I load the icons provided by .net dynamically?

977


How a base class method is hidden?

1097


Explain the differences between vb.net and c#, related to oops concepts?

945


what is common type system?

916


Can you please explain the difference between int and int32?

1086


Explain enumerator?

924


What is the class that allows an element to be accessed using unique key?

1138


Why is the xml infoset specification different from the xml dom?

931