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.

dbaccess makro mit sql

Empfohlene Antworten

Veröffentlicht

Hi Leute,

ich habe ein kleines Problem. Und zwar möchte ich ein Formular Programieren das wenn ich auf einen Button drücke einen SQL ausführt und das ergebnis des SQL´s in einem Textfeld /Layer darstellt (rückgabewert des SQL´s = INT)

kann mir jemand helfen. habe leider keine ahnung von SQL + VB4AP bzw dem Formular zeugs von DBaccess

gruss

kills

Mh hi

ich bin mir zwar nicht ganz sicher ob das die komplette Lsg für dein Problem ist, aber sicherlich ein Ansatz.

Du gehst in VBA-Code für dein Button und deklarierst nen String.

In diesem String speicherst du deine SQL-Anweisung.

Dann lässt du das über DoCmd ausführen.

Müsste ungefähr so aussehen:

dim sqlstr as string

sqlstr = "Select ... from..."

DoCmd.RunSql sqlstr

Ich hoffe es hilft :D

Ciaoi SMU

ist ja alles wunderbar aber wie gebe ich an wo der rückgabewert des SQL steht?

ist bloß eine zahl( eine spalte, eine zeile)! wie gebe ich an das das in dem layer drinne is?

danke für den vorschlag

gruss kills

Vielleicht sucht du so etwas: (Im OnClick-Ereignis eiens Buttons)

Dim rs as DAO.recordset

set rs = Currentdb.OpenRecordset("Select INTSpalte from Tabelle where ID = 1")

Form!DeinFormular!DeinTextfeld = rs!INTSpalte

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.