c++builder-2010

How should I embed Python in a C++ Builder / Delphi 2010 application?

社会主义新天地 提交于 2019-12-03 08:23:12
I'm interested in experimenting with embedding Python in my application, to let the user run Python scripts within the application environment, accessing internal (C++-implemented) objects, etc. I'm quite new to this so don't know exactly what I'm doing. I have read Embedding Python in Another Application , though this seems to talk only about a C API and flat C functions, not classes or objects (unless I've missed something) and its "Embedding Python in C++" section is only two sentences long. However, I also came across how to use boost::python and this looks excellent. There's one problem:

Implementing SNMP SendTrap using Indy components

你说的曾经没有我的故事 提交于 2019-12-02 09:31:31
I need to report errors from my application on C++Builder via SNMP. I started implementing SNMP SendTrap using Indy components. void __fastcall TMainForm::btSendTrapClick(TObject *Sender) { UnicodeString myEnterprise = "1.5.5.5.5.5.5.5"; UnicodeString eventType = "1.5.5.5.5.5.5.5.1"; UnicodeString eventDistance = "1.5.5.5.5.5.5.5.2"; TIdSNMP * idSnmp = 0; TSNMPInfo * infoSnmp = 0; idSnmp = new TIdSNMP(NULL); infoSnmp = new TSNMPInfo(idSnmp); idSnmp->Host = edHost->Text; idSnmp->Community = "public"; infoSnmp->Host = edHost->Text; infoSnmp->Community = "public"; infoSnmp->Enterprise =

What do I need to know to upgrade a complex application from C++Builder 2007 to 2010?

五迷三道 提交于 2019-12-01 00:45:22
My company's main application is mostly written in C++ (with some Delphi code and components). We are upgrading from RAD Studio 2007 to 2010 for the next release, starting in about a week. What do I need to know to ensure this upgrade goes smoothly? Points I have thought of so far are: Unicode. This one looks really complicated. Our app contains a horrible mix of std::string-s and AnsiString-s with casts to and from them. I have lots of questions about this, such as "is wstring capable of holding everything a UnicodeString can, and should we just do a search/replace", or "should we avoid all C