Results 1 to 3 of 3
  1. #1
    Join Date
    Oct 2003
    Posts
    311

    Unanswered: Creating , importing tables with vba

    I have a few task i do where i rename and import files, how can i import and rename tables and also add columns to the tables?

    M~

  2. #2
    Join Date
    Oct 2003
    Location
    Ger
    Posts
    1,969
    Provided Answers: 1

    Re: Creating , importing tables with vba

    Originally posted by mikezcg
    I have a few task i do where i rename and import files, how can i import and rename tables and also add columns to the tables?

    M~

    Import Table from Excel through


    DoCmd.TransferSpreadsheet acImport, acSpreadsheetTypeExcel97, TableNameHavingImportedData, Path & fileName, True

  3. #3
    Join Date
    Oct 2003
    Location
    Ger
    Posts
    1,969
    Provided Answers: 1

    Re: Creating , importing tables with vba

    Originally posted by mikezcg
    I have a few task i do where i rename and import files, how can i import and rename tables and also add columns to the tables?

    M~


    Sorry I forgot the second part of your questioon


    DoCmd.Rename newName, acTable, oldTableName



    Adding columns 2 tables or Deleting columns form tables through

    ALTER TABLE Tabelle {ADD {COLUMN Feld Typ[(Größe)] [NOT NULL] [CONSTRAINT Index] |
    CONSTRAINT Mehrfelderindex} |
    DROP {COLUMN Feld I CONSTRAINT Indexname } }

Posting Permissions

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