How to get rid of LNK2019, LNK1107, & LNK1561?

Tristan98 1 Reputation point
2022-01-10T22:18:10.167+00:00

A little bit of background, I am a current CS student just doing some general overview on C++ as I haven't used it very much. I wrote the code right from the textbook to help understand and practice in VS Code.

This program is going over classes, initialization lists, constructors, accessors, and mutators. Pretty basic and I can understand how that all works. I just cant compile it to run.

Using VS code 2022 on a Surface 8 Pro with Windows 11, command prompt terminal.

Like I said, not that experienced with C++ and am brushing up on using a new (to me) IDE so any help would be great.

IntCell.h:

1hGZKf9.jpg

IntCell.cpp:

yVLiCo6.jpg

TestIntCell.cpp

ZCqUlGT.jpg

Developer technologies | C++
{count} votes

1 answer

Sort by: Most helpful
  1. Minxin Yu 13,506 Reputation points Microsoft External Staff
    2022-01-11T09:37:24.537+00:00

    Hi, @Tristan98
    The snippet works fine in Visual Studio. You need to check if VS Code is configured correctly.
    For your reference: Configure VS Code for Microsoft C++

    Best regards,

    Minxin Yu


    If the answer is the right solution, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.


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.