when i type declare it does not show in the intellisense list so i can select if

Skullptor 0 Reputation points
2024-05-13T14:23:59.52+00:00

I keep getting the error must declare scalar variable "@SerialNo". Doesn't make any sense because the variable is a txt variable. This is occuring while trying to save to a sql database - cmd.Parameters.AddWithValue("@txtSerialNnumber", txtSerialNo.Text);

Microsoft 365
Microsoft 365
Formerly Office 365, is a line of subscription services offered by Microsoft which adds to and includes the Microsoft Office product line.
5,258 questions
Windows Server 2019
Windows Server 2019
A Microsoft server operating system that supports enterprise-level management updated to data storage.
3,831 questions
Windows 11
Windows 11
A Microsoft operating system designed for productivity, creativity, and ease of use.
10,126 questions
{count} votes

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.