Results 1 to 3 of 3

Thread: A Number is Required Here... anyone pls...

  1. #1

    Thread Starter
    Member psychofoo's Avatar
    Join Date
    Jun 2005
    Posts
    48

    A Number is Required Here... anyone pls...

    hi.. here's my code, but when i run my program, an error message "A number is required here ( on the red part). my declaration for NempID is integer...

    VB Code:
    1. Dim CrReport As CRAXDRT.Report
    2. Dim appCr As CRAXDRT.Application
    3. Set CrReport = New CRAXDRT.Report
    4. Set appCr = New CRAXDRT.Application
    5.  
    6. Set CrReport = appCr.OpenReport("c:\Documents and Settings\francis\Desktop\PC Inventory System\report\rptEmpMonitoring.rpt")
    7. [COLOR=Red]CrReport.RecordSelectionFormula = "{tEmployee.EmpID}='" & NEmpID & "'"[/COLOR]
    8. CR.ReportSource = CrReport
    9. CR.ViewReport

  2. #2
    PowerPoster
    Join Date
    Oct 2002
    Location
    British Columbia
    Posts
    9,758

    Re: A Number is Required Here... anyone pls...

    Remove the single quotes. Crystal is assuming the value of NempId is a string.

  3. #3

    Thread Starter
    Member psychofoo's Avatar
    Join Date
    Jun 2005
    Posts
    48

    Re: A Number is Required Here... anyone pls...

    hi... thanx so much! it works... + 1

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width