hello, I have a problem!
I have an infopath form and I want to connect into database,I use C# for coding behind, in the code I use below namespaces:
using System.Data;
using System.Data.SqlClient;
when I build the project, it shows me below error:
"The type or namespace name 'Data' does not exist in the namespace 'System' (are you missing an assembly reference?)"
I searched a lot, but I don't know how can I repair it? what is the exact namespace using instead of "Data" in VSTA(visual studio tools for applications)?

Recommended Answers

All 2 Replies

You need to add a reference to the System.Data library to your project.

thank you a lot.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.