3

Access にインポートされたパラドックス テーブルからの単一のエントリ出力があります。これで、レポートを作成し、レポート内で Paradox のデータセットにデータ バインディングを実行しました。Paradox で作業を行うと、単一エントリの出力が変更されます... テーブルを手動で再インポートせずに、アクセスを開いてレポートの値を自動的に更新するにはどうすればよいですか?

目的は、アクセスが開かれると、印刷前に検査のためにレポートがすぐに表示されることです。

4

4 に答える 4

3

データをインポートする代わりに、リンクされたテーブルを使用します (paradox のプロバイダーが利用可能であると仮定しますが、これは可能性が高いと思われます)。

于 2009-01-24T09:59:17.770 に答える
0

From the design view of the report, go to the property sheet and the Event tab. Find the On Load event and click the elipsis button. Select Code Builder if presented with the Choose Builder dialog. This will drop you into the VBA editor in the Report_Load event. Edit to look something like this:

Private Sub Report_Load()

DoCmd.TransferDatabase acImport, "Paradox 7.x", "c:\yourdata\yourfile.tbl", acTable, "SourceTable", "YourAccessTable"

End Sub

I'm not sure on the specifics for the Paradox version, the file naming convention, etc. (I only dabbled with Paradox briefly and don't remember it's specifics). Watch the intellisense or put the cursor on TransferData and press F1 to get the Help for the TransferDatabase method for reference.

Ahead of the TrasferDatabase statement you might want to run something like:

CurrentDb.Execute "DELETE FROM TableName"

That will blow out the destination table on the Access side ahead of the load from the Paradox side.

于 2009-01-25T04:15:11.457 に答える
0

メニューの GetData を使用して、テーブルを Paradox ファイルにリンクします。dbファイルがあるルートディレクトリからファイルを選択して選択します。リンクを維持し、日付の関係をデータセットにバインドします。Paradox データベースを使用して更新すると、Access のテーブルも更新されます。データベースの実行とアクセスを同時に行ってはなりません。そうしないと、ジェット エンジンが動作しません。

于 2009-01-24T20:20:41.213 に答える
0

Paradox テーブルへの直接リンクは機能するはずです。インポートを自動化するためにあなたが求めたことを行う方法は、autoexec マクロまたはレポートの OnLoad イベントで DoCmd.TransferDatabase を実行することです。おそらく、テーブルもリセットするために削除クエリから始めたいと思うでしょう。

于 2009-01-24T14:59:19.677 に答える