Results 1 to 2 of 2
  1. #1
    Join Date
    Nov 2005

    Unhappy Unanswered: Query: Printing ms-access table in vc++

    Hi all,
    I am having this problem for a long time & has almost left me frustrated.i want to print an ms-access table using vc++.when i use the following code:
    oDoCmd.PrintOut(0,1L,_variant_t("1"),_variant_t("1 "));

    //DoCmd.PrintOut [printrange][, pagefrom, pageto][, printquality][, copies][, collatecopies]

    it gives error:
    error C2660: 'PrintOut' : function does not take 4 parameters

    Second & third parameters are not required since first parameter 0 signifies print all. This is documented for vb but for vc++ i haven't found any documentation.How can i print an entire table in ms-access using vc++ as i have tried all my means but to no avail.Help!!

    Also does anyone know how can we get the no. of tables & their names in an access database
    Ankush Mehta

  2. #2
    Join Date
    Nov 2004
    out on a limb
    Provided Answers: 59
    Just a gues: If its a VC++ question then you'd probably be better of in the Delphi / C or possibly the .NET forums

    As regards getting the table names - it can be done in VBA, so providing the same objects are visible to you in VC++ then you should able to read them. See if your database object has the tabledefs collection visible.


Posting Permissions

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