Error when using Script in Report

Originally Posted 4 November 2009, 5:14 am EST

  • Originally Posted 4 November 2009, 5:14 am EST

    I created a report that pulls data from a SQL database and it works fine until I add script code on the report.



    In my development machine it shows an error for a missing dll related to a camera control, which we use.

    On a testing machine the error mentions another dll related to quickbooks which we also use, but it is present and installed.



    Please advice.

  • Reply

    No answer to my post?
  • Reply

    I am not using a RPX file. I am using a form in VB.NET 2008.



    Do you want the form files?



    I am not using any code for cameras or quickbooks. This is the script I am using on the report.



    Function ActiveReport_FetchData(ByVal EOF As Boolean) As Boolean



    If me.rpt.fields("unittype1").value=2 Then

    me.rpt.sections("Detail1").controls("Weight1").visible=false

    End If

    If me.rpt.fields("unittype1").value=1 Then

    me.rpt.sections("Detail1").controls("Quantity1").visible=false

    End If



    If me.rpt.fields("unittype2").value=2 Then

    me.rpt.sections("Detail1").controls("Weight2").visible=false



    End If

    If me.rpt.fields("unittype2").value=1 Then

    me.rpt.sections("Detail1").controls("Quantity2").visible=false

    End If



    If me.rpt.fields("unittype3").value=2 Then

    me.rpt.sections("Detail1").controls("Weight3").visible=false



    End If

    If me.rpt.fields("unittype3").value=1 Then

    me.rpt.sections("Detail1").controls("Quantity3").visible=false

    End If



    If me.rpt.fields("unittype4").value=2 Then

    me.rpt.sections("Detail1").controls("Weight4").visible=false



    End If

    If me.rpt.fields("unittype4").value=1 Then

    me.rpt.sections("Detail1").controls("Quantity4").visible=false

    End If



    ActiveReport_FetchData = EOF

    End Function
  • Reply

    Could you please provide me the RPX file of your report which throws this exception? Are you using some code in the script referring to the camera control dll or dll related to quickbooks?

    Regards,
    Ankit Nigam

  • Reply

    Hello,

    Have you used the AddScriptReference method to make reference to the Assemblies you are using in your script?

    Regards,
    Prantik
  • Reply

    The error I get is on the report editor during the preview.



    I am not using any assemblies on my script. Or the code I added is considered an assembly?
  • Reply

    If I add the reference for addscriptreference I get an error when I run the code on my development machine.



    This is the message I am getting.

    --------------

    Please fix the error in teh code and rebuild the project.



    Error message: could not load file or assembly ‘ActiveReporst6, Version-6.0.1797.0, Culture=neutral, PublicKeyToken=cc4967777 c49a3ff’ or one of its depedendencies. The system cannot find the file specified.

    -------------



    I really need a response to this issue please.

  • Reply

    Hello,

    Can you send the report files? If you are creating the report through code, can you send us the form file where you have created the same? Besides, is it a windows application or an web project?

    Regards,
    Prantik
  • Reply

    Hi,



    it is a windows application.



    I sent the files in a zipped file. I added an extra x to the extension to fool my email, please edit the files to be vendorform.vb and vendorform.resx
  • Reply

    You can send the files on support@grapecity.us.com and also mention the forum link in the mail.

    Regards,
    Ankit Nigam

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels