Zum Inhalt springen
View in the app

A better way to browse. Learn more.

Fachinformatiker.de

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Excel, Access, OLE-Objekte

Empfohlene Antworten

Veröffentlicht

Hallo Comm.,

Ich habe eine Access Datenbank in welcher unteranderem Word-Dokumente als OLE-Objekte abliegen.

Nun möchte ich von Excel aus zum einen neue OLE-Objekte einfügen, bzw. aus Excel herraus diese Objekte öffnen.

Kann mir da jemand behilflich sein?


Public Function openDoc()

Set objWord = CreateObject("Word.Application")

Set objWDoc = objWord.Documents


modDB.connectDB 'stellt Verbindung mit DB her

modDB.query "SELECT Formular FROM Formular WHERE FormID = '1A'"


objWDoc = rs.Fields(0) 'rs ist global deklariert, das ist der Recordset


'Hier kommt jetzt die Stelle an der ich nicht weiss wie ich das objWDoc anzeigen lasse

'Mit objWord.Documents.Open objWDoc hat es nicht geklappt (Typen unverträglich, auch objWord.Documents.Open FileName:=objWDoc klappt nicht

End Function


Public Function saveDoc()

Set objWord = CreateObject("Word.Application")

Set objWDoc = objWord.Documents


'Hier stelle ich verschiedene Sachen mit dem Dokument an, ändern, füllen usw.


modDB.connectDB

modDB.query "INSERT INTO Formular('FormID','Name','Formular')" & _

                  "VALUES('2B', 'Blubb', " & objWDoc & ")"


End Function

Also eigentlich konnte ich mir schon denken, dass das mit dem Insert nicht so klappt, aber mir ist keine andere Möglichkeit eingefallen.

Bin für jede Hilfe, bzw. jeden weiterführenden Link dankbar.

mfg

Archiv

Dieses Thema wurde archiviert und kann nicht mehr beantwortet werden.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.