Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. General Programming
  3. C / C++ / MFC
  4. making a library

making a library

Scheduled Pinned Locked Moved C / C++ / MFC
csharpvisual-studiohelptutorial
3 Posts 2 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • J Offline
    J Offline
    Jared F
    wrote on last edited by
    #1

    im trying to make myself a new library using visual studio and everything i try doesnt seem to work. i think that i got a library, but im not sure if its the right type or if i made it right. and if i did it right i have no idea which header to use or how to call my functions from each library. i understand that this is probably a hard subject to explain over a computer but any help would be greatly appreciated. thanks dudeoffrance

    M 1 Reply Last reply
    0
    • J Jared F

      im trying to make myself a new library using visual studio and everything i try doesnt seem to work. i think that i got a library, but im not sure if its the right type or if i made it right. and if i did it right i have no idea which header to use or how to call my functions from each library. i understand that this is probably a hard subject to explain over a computer but any help would be greatly appreciated. thanks dudeoffrance

      M Offline
      M Offline
      mark novak
      wrote on last edited by
      #2

      How to make a library can be ambigious. There are many types. You could have .dlls, or .libs that are directly linked into the program or just a directory of headers or even headers with source. I'd consider those all libraries. So how to make each one. To make a library which is used at runtime, use .dll. Make a new win32 application that is a dll project and then in the project you want to use the .dll, include the header to the .dll. Source is not needed, but the header will always be needed for whatever library you make. Unless you do COM or things of that nature. To make a library where no .dll is required because you wanted it linked in statically use a .lib. Create a .lib project for your library and then in the client project add the .lib to the linker tab in project settings and include the header. For the other two just make sure the client application includes and has access to the files needed. This is the simplest of libraries.

      J 1 Reply Last reply
      0
      • M mark novak

        How to make a library can be ambigious. There are many types. You could have .dlls, or .libs that are directly linked into the program or just a directory of headers or even headers with source. I'd consider those all libraries. So how to make each one. To make a library which is used at runtime, use .dll. Make a new win32 application that is a dll project and then in the project you want to use the .dll, include the header to the .dll. Source is not needed, but the header will always be needed for whatever library you make. Unless you do COM or things of that nature. To make a library where no .dll is required because you wanted it linked in statically use a .lib. Create a .lib project for your library and then in the client project add the .lib to the linker tab in project settings and include the header. For the other two just make sure the client application includes and has access to the files needed. This is the simplest of libraries.

        J Offline
        J Offline
        Jared F
        wrote on last edited by
        #3

        okay, i did that but what do i put in the #include< > at the top of the client app.? dudeoffrance

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups