Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. Rob2k2

    Running Total Formula

    I am using a running total field to sum up a field (field1) based on an evaluation formula on another field(field2). However if the evaluation formula is not met i.e. the condition of the formula is not satisfied then it wont return anything. Is there a way to return a 0 value instead of...
  2. Rob2k2

    Setting Data Source For Subreport

    I am currently launching a crystal report from within VB, which contains several subreports. The main report and subreports are all using different SQL statements to retrieve the data they need for the report. I have managed to get the main report working using the following code:- sqlstr1 =...
  3. Rob2k2

    Passing a paramater to a report from VB

    Ignore last post, just founf the FAQ section..lol
  4. Rob2k2

    Passing a paramater to a report from VB

    I have a date paramater field in one of my Crystal reports that lets me determine the month to run the report for. The parameter is called {?ReportDate}. I want to launch the report from a VB app and need to pass the paramater value to the report. The current SQL query to retrieve the data for...
  5. Rob2k2

    Background Colour

    Thanks, thats exactly what I was after.
  6. Rob2k2

    Background Colour

    I know this has been discussed somewhere before but I cant seem to find the post again. What i need to do is alternate the background colour of the group footer in my report. i.e. if there are 10 items in the group then the background colour of the 1st, 3rd, 5th, 7th and 9th item would be...
  7. Rob2k2

    Datagrid Updating

    I have a data grid which is used to update fields on a database. The problem is that the update only occurs when the user changes rows in the data grid. This is a problem as if the user updates a cell then exits the program without changing rows, the update is lost. Is there an easy way to...
  8. Rob2k2

    If Then Formula

    Thanks a lot worked a treat
  9. Rob2k2

    If Then Formula

    Okay, here it goes:- I need to replicate this code in crystal in order to avoid having a divide by zero error as TNoEnq can be 0 I have created a Formula called CPA in which I have the following code If {@TNoEnq} = 0 Then {@CPA} = 0 Else {@CPA} = ({@Cost}/{@TNoEnq})*1000 End If But it doesnt...
  10. Rob2k2

    Linking 2 Datagrids

    Many thanks for your reply, will give it a go tonight.
  11. Rob2k2

    Linking 2 Datagrids

    I am trying to link 2 datagrids so that if you change row in one datagrid it automatically selects the corresponding row in the other one. Each datagrid contains 2 seperate views of the same records so the number of rows is always the same and are in the same order. The code i am currently...
  12. Rob2k2

    Reading fields from a report

    Is there any way when a user clicks on a field in a report (a red box appears around it), they can then click on a vb button placed on the viewer toolbar and it will read the contents of the field into a text box. Any help would be appreciated.
  13. Rob2k2

    Export to excel from crystal reports 9

    Thanks a lot, all I needed however was the:- .ExcelConstantColumnWidth = 10000 Rob
  14. Rob2k2

    Select Expert Button Not Displaying

    Just found that out on crystals knowledgebase as well, was just about to post the same thing. It was the cselexpt.ocx file, it hadnt been included with the distro package and consequently not registered. Thanks anyway.
  15. Rob2k2

    Select Expert Button Not Displaying

    I am also having the same problem, any ideas anyone?
  16. Rob2k2

    Prompting For paramters at runtime

    Think you need to discard the saved data each time you open the report like this:- cReport.DiscardSavedData cReport.Database.Tables(1).SetLogOnInfo {your database logon info} ReportsViewFrm.CRViewer91.ViewReport ReportsViewFrm.CRViewer91.Zoom (90) ReportsViewFrm.Show This is what I use and...
  17. Rob2k2

    Refresh data by VB 6.0

    Try this beofore you view the report which should force the report to refresh itself. cReport.DiscardSavedData NB - cReport is the name you declared as:- Public cReport As CRAXDRT.Report
  18. Rob2k2

    Export to excel from crystal reports 9

    I am trying to export a report to excel(csv) format from crystal reports 9 in VB6. Everything is working fine, but i need to be able to change the colum widths of the columns to a custom value. This can be done, if you show the users the export dialog box below and allow them to specify a...
  19. Rob2k2

    Database Connection Through VB

    I have created several crystal reports and I now wish to write a visual basic frontend to view the reports. The reports import data using two sql queries from a single SQL database. Here is the SQL code I have in VB at the moment. Public Appn As CRAXDRT.Application Public cReport As...
  20. Rob2k2

    Trouble working with word

    I am using the following code to open a word document and insert two pictures:- Public WordApp As New Word.Application Public TestDoc As Word.Document Dim Sel As Word.Selection Private Sub LPCBtn_Click() Dim LogoRange As Word.Range Set TestDoc = WordApp.Documents.Open("C:\Documents and...

Part and Inventory Search

Back
Top