Hello Samarjit uppal,
can you plz try this
Right click on your project -> Properties -> Build -> change the platform target to "Any CPU"
i was face same issue when i try to connecting dotnet to SAP HANA and then i change this platform targate path from sap and problem is solve. may this solution is solve your issue..