Microsoft Visual Studio C# error C7036

SPlatten

Member
Joined
Nov 15, 2024
Messages
5
Programming Experience
10+
I have been working on a C# project and today some how I have introduced the compile error CS7036 "There is no argument given that corresponds to the required parameter 'V' of `cDBIntConnection.CreateDBParam(DbCommand, string, string, DataRowVersion)', looking at the DLL where this function comes from it is defined as:
C#:
public DbParameter CreateDBParam(DbCommand C, string pName, string SourceCol
                                    , DataRowVersion V) {
    return DBParam(C, pName, SourceCol, true, V);
}
I can see why the compiler is raising the error, however I haven't removed anything and now its only just reporting this as an issue. I have the same project at a location on the network which if I clean and rebuild it does not error with the same dll and source, can anyone help explain why the local build complains and the network version doesn't?

Example of the function from the source:
C#:
dbInt.CreateDBParam(InsertDBCommand, "@CustomerID", "CustomerID");

And the error reporting;
error CS7036: There is no argument given that corresponds to the required parameter 'V' of 'cDBIntConnection.CreateDBParam(DbCommand, string, string, DataRowVersion)'
 
You have two different versions of the class cDBIntConnection, or your network version of the code has an extension method called CreateDBParam that takes 3 parameters.
 
You have two different versions of the class cDBIntConnection, or your network version of the code has an extension method called CreateDBParam that takes 3 parameters.

Thank you for your post, but thats not it because the class is in the DLL and both the network and the local versions reference the same DLL version.
 
Back
Top Bottom