aboutsummaryrefslogtreecommitdiffstats
path: root/apps/windoze/CBuilder4/BibleCS/ddetest
diff options
context:
space:
mode:
Diffstat (limited to 'apps/windoze/CBuilder4/BibleCS/ddetest')
-rw-r--r--apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientForm.cpp46
-rw-r--r--apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientForm.dfmbin0 -> 1353 bytes
-rw-r--r--apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientForm.h41
-rw-r--r--apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientProj.cpp24
-rw-r--r--apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientProj.mak55
-rw-r--r--apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientProj.resbin0 -> 876 bytes
6 files changed, 166 insertions, 0 deletions
diff --git a/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientForm.cpp b/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientForm.cpp
new file mode 100644
index 0000000..4024da2
--- /dev/null
+++ b/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientForm.cpp
@@ -0,0 +1,46 @@
+//---------------------------------------------------------------------------
+#include <vcl\vcl.h>
+#pragma hdrstop
+
+#include "DDEClientForm.h"
+//---------------------------------------------------------------------------
+#pragma resource "*.dfm"
+TForm1 *Form1;
+//---------------------------------------------------------------------------
+__fastcall TForm1::TForm1(TComponent* Owner)
+ : TForm(Owner)
+{
+}
+//---------------------------------------------------------------------------
+void __fastcall TForm1::Button1Click(TObject *Sender)
+{
+ if (DdeClientConv1->SetLink("sword","Bible")) {
+ Application->MessageBox("DDE Link Successful!","DDE Information",MB_OK);
+ DdeClientItem1->DdeItem = "Lookup";
+ DdeClientItem2->DdeItem = "Search";
+ }
+ else {
+ MessageBox(Handle,"DDE Link Unsuccessful","DDE Information", MB_OK | MB_ICONERROR);
+ }
+}
+//---------------------------------------------------------------------------
+void __fastcall TForm1::DdeClientItem1Change(TObject *Sender)
+{
+ Memo1->Text = DdeClientItem1->Text;
+}
+//---------------------------------------------------------------------------
+void __fastcall TForm1::DdeClientItem2Change(TObject *Sender)
+{
+ Memo2->Text = DdeClientItem2->Text;
+}
+//---------------------------------------------------------------------------
+void __fastcall TForm1::Button2Click(TObject *Sender)
+{
+ DdeClientConv1->PokeData("Lookup", Edit1->Text.c_str());
+}
+//---------------------------------------------------------------------------
+void __fastcall TForm1::Button3Click(TObject *Sender)
+{
+ DdeClientConv1->PokeData("Search", Edit2->Text.c_str());
+}
+//--------------------------------------------------------------------------- \ No newline at end of file
diff --git a/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientForm.dfm b/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientForm.dfm
new file mode 100644
index 0000000..b964701
--- /dev/null
+++ b/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientForm.dfm
Binary files differ
diff --git a/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientForm.h b/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientForm.h
new file mode 100644
index 0000000..6f23c5f
--- /dev/null
+++ b/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientForm.h
@@ -0,0 +1,41 @@
+//---------------------------------------------------------------------------
+#ifndef DDEClientFormH
+#define DDEClientFormH
+//---------------------------------------------------------------------------
+#include <vcl\Classes.hpp>
+#include <vcl\Controls.hpp>
+#include <vcl\StdCtrls.hpp>
+#include <vcl\Forms.hpp>
+#include <vcl\DdeMan.hpp>
+#include <vcl\ExtCtrls.hpp>
+//---------------------------------------------------------------------------
+class TForm1 : public TForm
+{
+__published: // IDE-managed Components
+ TDdeClientConv *DdeClientConv1;
+ TPanel *Panel1;
+ TMemo *Memo1;
+ TMemo *Memo2;
+ TPanel *Panel2;
+ TEdit *Edit1;
+ TButton *Button1;
+ TButton *Button2;
+ TButton *Button3;
+ TEdit *Edit2;
+ TDdeClientItem *DdeClientItem1;
+ TDdeClientItem *DdeClientItem2;
+ void __fastcall Button1Click(TObject *Sender);
+ void __fastcall DdeClientItem1Change(TObject *Sender);
+
+ void __fastcall DdeClientItem2Change(TObject *Sender);
+ void __fastcall Button2Click(TObject *Sender);
+ void __fastcall Button3Click(TObject *Sender);
+private: // User declarations
+public: // User declarations
+ __fastcall TForm1(TComponent* Owner);
+};
+//---------------------------------------------------------------------------
+extern TForm1 *Form1;
+//---------------------------------------------------------------------------
+#endif
+ \ No newline at end of file
diff --git a/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientProj.cpp b/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientProj.cpp
new file mode 100644
index 0000000..12c3d74
--- /dev/null
+++ b/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientProj.cpp
@@ -0,0 +1,24 @@
+//---------------------------------------------------------------------------
+#include <vcl\vcl.h>
+#pragma hdrstop
+//---------------------------------------------------------------------------
+USEFORM("DDEClientForm.cpp", Form1);
+USERES("DDEClientProj.res");
+//---------------------------------------------------------------------------
+WINAPI WinMain(HINSTANCE, HINSTANCE, LPSTR, int)
+{
+ try
+ {
+ Application->Initialize();
+ Application->Title = "SWORD DDE Test Program";
+ Application->CreateForm(__classid(TForm1), &Form1);
+ Application->Run();
+ }
+ catch (Exception &exception)
+ {
+ Application->ShowException(&exception);
+ }
+ return 0;
+}
+//---------------------------------------------------------------------------
+ \ No newline at end of file
diff --git a/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientProj.mak b/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientProj.mak
new file mode 100644
index 0000000..20a6233
--- /dev/null
+++ b/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientProj.mak
@@ -0,0 +1,55 @@
+# ---------------------------------------------------------------------------
+VERSION = BCB.01
+# ---------------------------------------------------------------------------
+!ifndef BCB
+BCB = $(MAKEDIR)\..
+!endif
+# ---------------------------------------------------------------------------
+PROJECT = DDEClientProj.exe
+OBJFILES = DDEClientProj.obj DDEClientForm.obj
+RESFILES = DDEClientProj.res
+RESDEPEN = $(RESFILES) DDEClientForm.dfm
+LIBFILES =
+DEFFILE =
+# ---------------------------------------------------------------------------
+CFLAG1 = -Od -Hc -w -k -r- -y -v -vi- -c -a4 -b- -w-par -w-inl -Vx -Ve -x
+CFLAG2 = -I$(BCB)\include;$(BCB)\include\vcl -H=$(BCB)\lib\vcld.csm
+PFLAGS = -AWinTypes=Windows;WinProcs=Windows;DbiTypes=BDE;DbiProcs=BDE;DbiErrs=BDE \
+ -U$(BCB)\lib\obj;$(BCB)\lib -I$(BCB)\include;$(BCB)\include\vcl -v -$Y -$W \
+ -$O- -JPHNV -M
+RFLAGS = -i$(BCB)\include;$(BCB)\include\vcl
+LFLAGS = -L$(BCB)\lib\obj;$(BCB)\lib -aa -Tpe -x -v -V4.0
+IFLAGS =
+LINKER = ilink32
+# ---------------------------------------------------------------------------
+ALLOBJ = c0w32.obj $(OBJFILES)
+ALLRES = $(RESFILES)
+ALLLIB = $(LIBFILES) vcl.lib import32.lib cp32mt.lib
+# ---------------------------------------------------------------------------
+.autodepend
+
+$(PROJECT): $(OBJFILES) $(RESDEPEN) $(DEFFILE)
+ $(BCB)\BIN\$(LINKER) @&&!
+ $(LFLAGS) +
+ $(ALLOBJ), +
+ $(PROJECT),, +
+ $(ALLLIB), +
+ $(DEFFILE), +
+ $(ALLRES)
+!
+
+.pas.hpp:
+ $(BCB)\BIN\dcc32 $(PFLAGS) { $** }
+
+.pas.obj:
+ $(BCB)\BIN\dcc32 $(PFLAGS) { $** }
+
+.cpp.obj:
+ $(BCB)\BIN\bcc32 $(CFLAG1) $(CFLAG2) -o$* $*
+
+.c.obj:
+ $(BCB)\BIN\bcc32 $(CFLAG1) $(CFLAG2) -o$* $**
+
+.rc.res:
+ $(BCB)\BIN\brcc32 $(RFLAGS) $<
+#-----------------------------------------------------------------------------
diff --git a/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientProj.res b/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientProj.res
new file mode 100644
index 0000000..be31e84
--- /dev/null
+++ b/apps/windoze/CBuilder4/BibleCS/ddetest/DDEClientProj.res
Binary files differ