I am trying to initiate CrystalReportViewer object properly. Now I am stuck, cause the reference manual doesn't make much sense...
First, here is the code I have written:

[vb]
ParameterType enumTypes = new ParameterType();
ParameterValueKind valKind = new ParameterValueKind() ;

//Init a ParameterFields collection
ParameterFields myParamFields = new ParameterFields();
//Init a ParameterField object
ParameterField paramJob = new ParameterField();

paramJob.PromptText = "Write jobname";
//Set "job" parameter to type "Report"
paramJob.ParameterType = enumTypes.ReportParameter;
paramJob.ParameterValueKind = valKind.StringParameter;




//CrystalReportViewer1.ParameterFieldInfo = newPar;
CrystalReportViewer1.ReportSource = "c:\\jobbfelpermånad.rpt";
CrystalReportViewer1.HasExportButton = true;
CrystalReportViewer1.HasRefreshButton = true;

[/vb]
in the references it says that the property "ParameterType" should be of type "ParameterType", with is an enum. And as far as I understand it, I can declare the enum variable and use it like
[vb]
paramJob.ParameterType = enumTypes.ReportParameter;
[/vb]

But strangely it doesn't work to do it like this, cause I get the error message:

c:\inetpub\wwwroot\WebApplication14\WebForm1.aspx.cs(35): Static member 'CrystalDecisions.Shared.ParameterType.ReportParameter' cannot be accessed with an instance reference; qualify it with a type name instead



I have no clue what this means. According to the reference I thought I did it the right way, but I am pretty sure I am doing something wrong with the enum properties.

Can anyone help me on this???
If you need more info, just let me know


best regards
Henrik