Search found 1776 matches
- Fri Feb 26, 2021 9:59 am
- Forum: Technical
- Topic: Installing C++ Builder 6.0 on Win server 2012
- Replies: 1
- Views: 15
Re: Installing C++ Builder 6.0 on Win server 2012
How about installing it one time in a VM, and then move the VM around as needed?
- Wed Feb 24, 2021 1:14 pm
- Forum: Technical
- Topic: COM library initialization with C++Builder routine
- Replies: 1
- Views: 48
Re: COM library initialization with C++Builder routine
But, before the instantiation I need to initialize the COM library and here, where I cannot find a C++ Builder routine and forced to use the WINAPI function, HRESULT CoInitializeEx( LPVOID pvReserved, DWORD dwCoInit); . Am I missed something or this is the way COM should be used in case of no Type ...
- Wed Feb 17, 2021 3:20 pm
- Forum: Technical
- Topic: String with 0/1 representation of binary to convert
- Replies: 14
- Views: 1192
Re: String with 0/1 representation of binary to convert
Get yourself some good C++ books. And when you need online references, start with CppReference.com, which would have told you immediately that std::to_wstring() is declared in the <string> header:
- Wed Feb 17, 2021 12:02 pm
- Forum: Technical
- Topic: Filtering keystrokes using FMX
- Replies: 6
- Views: 136
- Wed Feb 17, 2021 11:49 am
- Forum: Technical
- Topic: String with 0/1 representation of binary to convert
- Replies: 14
- Views: 1192
Re: String with 0/1 representation of binary to convert
This is the code block in question: do { ModNum = DivNum%8; StrOut = std::to_wstring(ModNum); // This line errors under Windows10 only Bufr[CountOct] =StrOut[0]; CountOct--; DivNum = DivNum/8; }while (DivNum>=8); it compiles and runs properly using FMX when the target OS is Android. The same code t...
- Tue Feb 16, 2021 6:12 pm
- Forum: Technical
- Topic: Filtering keystrokes using FMX
- Replies: 6
- Views: 136
Re: Filtering keystrokes using FMX
The following code runs very nicely when used in a VCL based program. It compiles nicely under FMX, the program loads and runs in both Windows and Android, but this code is completely ignored when running on either platform. Which event are you actually using? In one place I trap on Key == vkReturn...
- Tue Feb 16, 2021 5:53 pm
- Forum: Technical
- Topic: String with 0/1 representation of binary to convert
- Replies: 14
- Views: 1192
Re: String with 0/1 representation of binary to convert
Unfortunately the best choices - std::to_wstring() (and std::to_string()) - will not compile under Windows using FMX. Why not? What does the code look like, and what do the error messages say? Are you using a C++11-enabled clang compiler, or are you using the classic Borland compiler? And again, as...
- Sun Feb 14, 2021 2:18 pm
- Forum: Technical
- Topic: String with 0/1 representation of binary to convert
- Replies: 14
- Views: 1192
Re: String with 0/1 representation of binary to convert
The larger problem I've been dealing with is a relatively painless method of dealing with user input in other number bases. There's plenty to handle Hex & Decimal, but Octal, Binary, and BCD are nearly untouched. wcstol()/std::stol() can handle decimal, hex, and octal. Embarcadero's RTL has StrToBc...
- Fri Feb 12, 2021 3:25 pm
- Forum: Technical
- Topic: String with 0/1 representation of binary to convert
- Replies: 14
- Views: 1192
Re: String with 0/1 representation of binary to convert
The suggested code: __int64 i1 = wcstoll(Edit1->Text.c_str(), NULL, 2); (as well as the std:: version) still errors-out. The message is: wchar.h(146): candidate function not viable: no known conversion from 'WideChar *' (aka 'char16_t *') to 'const wchar_t *' for 1st argument UnicodeString uses 'wc...
- Mon Feb 01, 2021 5:22 pm
- Forum: Technical
- Topic: Getting abstract class like getting Interface from TObject?
- Replies: 3
- Views: 255
Re: Getting abstract class like getting Interface from TObject?
My problem with Delphi interfaces is that I get weird result every time I use them. For example i have some class that inherit from interfaces and when I use TInterfacedObject as the docwiki says it raises exception when I use the TObject class if I used GetInterface with it to get one of my interf...
- Mon Feb 01, 2021 10:44 am
- Forum: Technical
- Topic: Embarcadero and AvSetMmThreadPriority
- Replies: 11
- Views: 794
Re: Embarcadero and AvSetMmThreadPriority
I saw that the avrt.h header file does not contain the functions I call. Yes, it does. Look again more carefully: _Success_(return != NULL) AVRTAPI HANDLE WINAPI AvSetMmThreadCharacteristicsA ( _In_ LPCSTR TaskName, _Inout_ LPDWORD TaskIndex ); _Success_(return != NULL) AVRTAPI HANDLE WINAPI AvSetM...
- Mon Feb 01, 2021 10:34 am
- Forum: Technical
- Topic: Getting abstract class like getting Interface from TObject?
- Replies: 3
- Views: 255
Re: Getting abstract class like getting Interface from TObject?
First off, you have to remember that TObject is written in Delphi, so it and its descendants are treated special in C++. They follow Delphi class rules, not C++ class rules. Delphi doesn't support multiple inheritance of classes, like C++ does. In Delphi, a class can have at most 1 base class, but i...
- Mon Feb 01, 2021 9:54 am
- Forum: Technical
- Topic: Embarcadero and AvSetMmThreadPriority
- Replies: 11
- Views: 794
Re: Embarcadero and AvSetMmThreadPriority
thanks Remy, but in the .lib installed with Embarcadero, when I compile, the following functions do not exist: [ilink32 Error] Error: Unresolved external 'AvSetMmThreadCharacteristicsW' referenced from D:\EMBC\MIDI_EXPERIMENT\WIN32\DEBUG\UNIT1.OBJ [ilink32 Error] Error: Unresolved external 'AvSetMm...
- Sat Jan 30, 2021 1:22 pm
- Forum: Technical
- Topic: Embarcadero and AvSetMmThreadPriority
- Replies: 11
- Views: 794
Re: Embarcadero and AvSetMmThreadPriority
I looked for the avrt.lib file and I found it, but strangely the compiler can't find it. LIB files are handled by the linker, not the compiler. And the linker is not supposed to look for that LIB file by default. Only a small subset of core system LIB files are automatically linked into programs by...
- Fri Jan 29, 2021 12:28 pm
- Forum: Technical
- Topic: Embarcadero and AvSetMmThreadPriority
- Replies: 11
- Views: 794