Hi Altaf, I had the same problem this helped me try this.
change your code to the following, you should be using "SqlCeConnection class", rather than "SqlConnection class"...
string conStr = ConfigurationManager.ConnectionStrings["ConString"].ConnectionString;
SqlCeConnection con = new SqlCeConnection(conStr);
SqlCeCommand cmd = new SqlCeCommand();
SqlCeDataReader dr;
try
{
con.Open();
cmd.CommandType = CommandType.Text;
cmd.Connection = con;
cmd.CommandText = "Select ProductName From Products";