2 Replies Latest reply: May 15, 2014 9:54 AM by RalphB _ RSS

    Visual Basic Code to Append Table Exported from Monarch to Microsoft Access Database

    MorseB _

      How do you write code to append table to an existing Microsoft Access database instead of having the database overlayed?

       

      I can do this from within Monarch by selecting the append (add data to existing file) instead of overwrite existing file.

       

      Sample Code follows:

       

      ***

       

      Private Sub cmd_PrepareDailyBookBal_Click()

      Dim stappname As String

       

      MsgBox "Monarch will now start and run model (DAFR8920DlyBookBal.mod) to create the DAFR8920Daily.mdb database for creating the daily book balances for importing.  Monarch will prompt you for a user id before starting.  Your user id is the same as your Novell network usder id (e.g., morseb)."

       

      stappname = "J:MonarchprogramMonarch.exe      reas_recpt_nt2 ecpt.ftpmainftp8920BANK      reas_recpt_nt2d econwinmonarchDAFR8920DlyBookBal.mod       reas_recpt_nt2DImportDataDownloadDafr8920DailyTableTest.mdb /s"

      stappname = "J:MonarchprogramMonarch.exe      reas_recpt_nt2 ecpt.ftpmainftp8920BANK      reas_recpt_nt2d econwinmonarchDAFR8920DlyBookBalPM.mod       reas_recpt_nt2DImportDataDownloadDafr8920DailyTableTest.mdb /s"

      Call Shell(stappname, 1)

       

      End Sub

       

      ***

       

      Thanks for the help.

        • Visual Basic Code to Append Table Exported from Monarch to Microsoft Access Database
          RalphB _

          Originally posted by MorseB:

          How do you write code to append table to an existing Microsoft Access database instead of having the database overlayed?

           

          I can do this from within Monarch by selecting the append (add data to existing file) instead of overwrite existing file.

           

          Sample Code follows:

           

          ***

           

          Private Sub cmd_PrepareDailyBookBal_Click()

          Dim stappname As String

           

          MsgBox "Monarch will now start and run model (DAFR8920DlyBookBal.mod) to create the DAFR8920Daily.mdb database for creating the daily book balances for importing.  Monarch will prompt you for a user id before starting.  Your user id is the same as your Novell network usder id (e.g., morseb)."

           

          stappname = "J:MonarchprogramMonarch.exe      reas_recpt_nt2 ecpt.ftpmainftp8920BANK      reas_recpt_nt2d econwinmonarchDAFR8920DlyBookBal.mod       reas_recpt_nt2DImportDataDownloadDafr8920DailyTableTest.mdb /s"

          stappname = "J:MonarchprogramMonarch.exe      reas_recpt_nt2 ecpt.ftpmainftp8920BANK      reas_recpt_nt2d econwinmonarchDAFR8920DlyBookBalPM.mod       reas_recpt_nt2DImportDataDownloadDafr8920DailyTableTest.mdb /s"

          Call Shell(stappname, 1)

           

          End Sub

           

          ***

           

          Thanks for the help. /b[/quote]

          • Visual Basic Code to Append Table Exported from Monarch to Microsoft Access Database
            RalphB _

            Originally posted by RalphB:  You can append to existing files using the JetExport command which is available in Monarch version 6 Pro and above.  For complete details on the JetExport command which can be used to export tables or summaries see the Programmers Guide.

             

              /size[quote]quote:[/size]Originally posted by MorseB:

            How do you write code to append table to an existing Microsoft Access database instead of having the database overlayed?

             

            I can do this from within Monarch by selecting the append (add data to existing file) instead of overwrite existing file.

             

            Sample Code follows:

             

            ***

             

            Private Sub cmd_PrepareDailyBookBal_Click()

            Dim stappname As String

             

            MsgBox "Monarch will now start and run model (DAFR8920DlyBookBal.mod) to create the DAFR8920Daily.mdb database for creating the daily book balances for importing.  Monarch will prompt you for a user id before starting.  Your user id is the same as your Novell network usder id (e.g., morseb)."

             

            stappname = "J:MonarchprogramMonarch.exe      reas_recpt_nt2 ecpt.ftpmainftp8920BANK      reas_recpt_nt2d econwinmonarchDAFR8920DlyBookBal.mod       reas_recpt_nt2DImportDataDownloadDafr8920DailyTableTest.mdb /s"

            stappname = "J:MonarchprogramMonarch.exe      reas_recpt_nt2 ecpt.ftpmainftp8920BANK      reas_recpt_nt2d econwinmonarchDAFR8920DlyBookBalPM.mod       reas_recpt_nt2DImportDataDownloadDafr8920DailyTableTest.mdb /s"

            Call Shell(stappname, 1)

             

            End Sub

             

            ***

             

            Thanks for the help. /b[/quote][/b][/size][/QUOTE]