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. how to connect database

how to connect database

Scheduled Pinned Locked Moved C / C++ / MFC
databasetutorial
7 Posts 4 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.
  • S Offline
    S Offline
    Supriyanka
    wrote on last edited by
    #1

    How to connect database.database is in exelsheet.

    D H 2 Replies Last reply
    0
    • S Supriyanka

      How to connect database.database is in exelsheet.

      D Offline
      D Offline
      David Crow
      wrote on last edited by
      #2

      So which is it: reading from a database or an Excel file? You can use ODBC for both. You can also use Excel Automation for the latter. Are you using MFC?

      "Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown

      "Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons

      S 1 Reply Last reply
      0
      • S Supriyanka

        How to connect database.database is in exelsheet.

        H Offline
        H Offline
        Hamid Taebi
        wrote on last edited by
        #3

        For database you can use of CDatabase class for excel see CSpreadSheet - A Class to Read and Write to Excel[^].

        Of one Essence is the human race thus has Creation put the base One Limb impacted is sufficient For all Others to feel the Mace (Saadi )

        F 1 Reply Last reply
        0
        • D David Crow

          So which is it: reading from a database or an Excel file? You can use ODBC for both. You can also use Excel Automation for the latter. Are you using MFC?

          "Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown

          "Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons

          S Offline
          S Offline
          Supriyanka
          wrote on last edited by
          #4

          I am using MFC. hw to connect exelsheet as database while doing MFC project.

          D 1 Reply Last reply
          0
          • S Supriyanka

            I am using MFC. hw to connect exelsheet as database while doing MFC project.

            D Offline
            D Offline
            David Crow
            wrote on last edited by
            #5

            Supriyanka wrote:

            hw to connect exelsheet as database while doing MFC project.

            Have you tried ODBC with CRecordset and CDatabase?

            "Old age is like a bank account. You withdraw later in life what you have deposited along the way." - Unknown

            "Fireproof doesn't mean the fire will never come. It means when the fire comes that you will be able to withstand it." - Michael Simmons

            1 Reply Last reply
            0
            • H Hamid Taebi

              For database you can use of CDatabase class for excel see CSpreadSheet - A Class to Read and Write to Excel[^].

              Of one Essence is the human race thus has Creation put the base One Limb impacted is sufficient For all Others to feel the Mace (Saadi )

              F Offline
              F Offline
              fanronghua
              wrote on last edited by
              #6

              Which Database are you connect? you can used AdoConnect _ConnectionPtr * con; _RecordsetPtr * rec;

              H 1 Reply Last reply
              0
              • F fanronghua

                Which Database are you connect? you can used AdoConnect _ConnectionPtr * con; _RecordsetPtr * rec;

                H Offline
                H Offline
                Hamid Taebi
                wrote on last edited by
                #7

                Thanks for your answer but it was not my question! :-D

                Of one Essence is the human race thus has Creation put the base One Limb impacted is sufficient For all Others to feel the Mace (Saadi )

                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