Results 1 to 3 of 3

Thread: [RESOLVED] "DataType" Not Declared Error

  1. #1

    Thread Starter
    Hyperactive Member pourkascheff's Avatar
    Join Date
    Apr 2020
    Location
    LocalHost
    Posts
    384

    Resolved [RESOLVED] "DataType" Not Declared Error

    Hey y'all. o/
    I followed a video instruction to initiate a simple COM transmit/receive operation.
    Communication is OK but in converting values to hexadecimal, His/Her code has no errors in building procedure but mine doesn't recognize the "DataType". I looked up the headers and imported libraries and found that we were matched.

    How can I rectify it???
    Name:  Untitled.jpg
Views: 347
Size:  43.5 KB

  2. #2
    Frenzied Member
    Join Date
    Feb 2003
    Posts
    1,945

    Re: "DataType" Not Declared Error

    Well, it's exactly as the error messsage in your screenshot says: "datatype" is not declared. At least not in the code you posted. Please use code tags next time. These can be inserted by clicking the "#" button in the toolbar above the forum message you're about to post. It would also be helpful if you linked to that video you mentioned.

  3. #3
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: "DataType" Not Declared Error

    You need to go back to the tutorial and find out where they declare that variable. If they don't state it explicitly then you should put some thought into it and work out what that variable represents and what type it is and where you think it should be declared. I don't know why you would be trying to write code to use a SerialPort if you don't understand basic things like declaring variables. It's a bad idea to try to run before you can walk.
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width