Linking static library

Jul 26, 2014 at 1:53pm
I am trying to link my own library (.lib file) to a new project.
I've found millions of guides with all kinds of different explanations,I am reallyconfused rigght now.
I am using Visual Studio 2013.
How do I link my .lib file to the current project?
I need clear steps, any guide/tutorial confuses me even more.
Jul 26, 2014 at 1:59pm
In Solution Explorer, right click on the project => Add => Existing Item => ...
(and select your .lib file as the item to be added).
Last edited on Jul 26, 2014 at 1:59pm
Jul 27, 2014 at 10:10am
I did that, but it still shows red lines whenever I use my libraries' functions...
Jul 27, 2014 at 10:12am
It says:
"Error: name followed by :: must be a class or namespace name"
Jul 27, 2014 at 10:24am
Nevermind, I fucked around with those complicated settings and got it to pseudo-work.
Now I got another problem: "Error: Name space MyLib has no member TestFunc"...
While I clearly declared that function in my library...
Jul 27, 2014 at 1:43pm
> While I clearly declared that function in my library...

Did you also declare the function (MyLib::TestFunc) in the header for your library (which you are #include ing in the program that uses the library)?
Jul 30, 2014 at 3:29pm
Nevermind , I got the thing to work.
Thterad cloesd.
Topic archived. No new replies allowed.