c++builder

“Save to Files” on iOS (FMX)

可紊 提交于 2019-12-23 03:14:35
问题 I want to save email attachments to my app’s doc folder (C++ FMX app for iOS & Android). How do I register my app as a target? The screen shots below show that an app on my phone named Termius is a target to save files to. I want my app to be a target like this. Just need user to get files into my app folder. relayman 回答1: Based on Sherlock70 tutoring i was able to easily add my app's Documents folder as a "save to files" target. I selected iOSDevice64 as my target platform and then went to

Winsock bind() failing with WSAEADDRNOTAVAIL for directed broadcast address

两盒软妹~` 提交于 2019-12-22 20:29:03
问题 I am setting up a UDP socket and trying to bind what should be a valid network broadcast address to it (192.168.202.255 : 23456), but bind fails with error 10049, WSAEADDRNOTAVAIL. If I use a localhost broadcast address, 127.0.0.255, it succeeds. WSAEADDRNOTAVAIL's documentation says that "The requested address is not valid in its context. This normally results from an attempt to bind to an address that is not valid for the local computer. This can also result from connect, sendto, WSAConnect

Winsock bind() failing with WSAEADDRNOTAVAIL for directed broadcast address

偶尔善良 提交于 2019-12-22 20:28:38
问题 I am setting up a UDP socket and trying to bind what should be a valid network broadcast address to it (192.168.202.255 : 23456), but bind fails with error 10049, WSAEADDRNOTAVAIL. If I use a localhost broadcast address, 127.0.0.255, it succeeds. WSAEADDRNOTAVAIL's documentation says that "The requested address is not valid in its context. This normally results from an attempt to bind to an address that is not valid for the local computer. This can also result from connect, sendto, WSAConnect

Is there a way to write a BSTR literal?

百般思念 提交于 2019-12-22 08:18:03
问题 When calling a function that expects a BSTR it'd be nice to be able to write something like: iFoo->function( bs"HELLO" ); However the only workaround I'm aware of is to use a wrapper that calls SysAllocString etc., e.g.: iFoo->function( WideString(L"HELLO").c_bstr() ); which is kind of ugly. Is there actually such an option to create a BSTR literal? Motivation: easier-to-read code, and faster runtime performance by avoiding an allocation and deallocation. Clarification: I am only talking

c++ Builder xe5 Error detected (LME288)

馋奶兔 提交于 2019-12-22 04:56:35
问题 c++ Builder xe5 [ilink32 Error] Error: Unable to perform link [ilink32 Warning] Warning: Error detected (LME288) that happened when i tried to compile a test project c++ builder xe5 on windows xp 回答1: I got some information on this from Embarcadero which may help. The error is an "out of memory", error. The reason for "Out Of Memory" errors (which come in different guises) in the linker, is that the linker has to pre-allocate memory in contiguous heaps that it then uses as it links, in the

c++ Builder xe5 Error detected (LME288)

我怕爱的太早我们不能终老 提交于 2019-12-22 04:56:05
问题 c++ Builder xe5 [ilink32 Error] Error: Unable to perform link [ilink32 Warning] Warning: Error detected (LME288) that happened when i tried to compile a test project c++ builder xe5 on windows xp 回答1: I got some information on this from Embarcadero which may help. The error is an "out of memory", error. The reason for "Out Of Memory" errors (which come in different guises) in the linker, is that the linker has to pre-allocate memory in contiguous heaps that it then uses as it links, in the

Enable Safe Exception Handling in C++ Builder

孤者浪人 提交于 2019-12-22 03:09:31
问题 For Windows 8 application certification, there are (among other) these requirements: 3.2 Your app must be compiled using the /SafeSEH flag to ensure safe exceptions handling 3.3 Your app must be compiled using the /NXCOMPAT flag to prevent data execution 3.4 Your app must be compiled using the /DYNAMICBASE flag for address space layout randomization (ASLR) I wasn't able to find out how to enable either of these in C++Builder XE. For /NXCOMPAT and /DYNAMICBASE , one can use editbin.exe from VS

Convert the Linux open, read, write, close functions to work on Windows

耗尽温柔 提交于 2019-12-21 21:22:53
问题 The code below was written for Linux and uses open, read, write and close. I am working on a Windows computer where I normally use fopen, fgets, fputs, fclose. Right now I get a no prototype error for open, read, write and close. Is there a header file I can include to make this work on a Windows computer or do I need to convert the code? Can you show how to convert it so it works the same on Windows or at least point me to an online document which shows how to convert it? #include <stdio.h>

Change CheckBox state without calling OnClick Event

China☆狼群 提交于 2019-12-21 07:25:52
问题 I'm wondering so when I change state of CheckBox CheckBox->Checked=false; It calls CheckBoxOnClick Event , how to avoid it ? 回答1: You could surround the onClick event code with something like if myFlag then begin ...event code... end; If you don't want it to be executed, set myFlag to false and after the checkbox state's change set it back to true. 回答2: Another option is to change the protected ClicksDisable property using an interposer class like this: type THackCheckBox = class

Change CheckBox state without calling OnClick Event

醉酒当歌 提交于 2019-12-21 07:25:07
问题 I'm wondering so when I change state of CheckBox CheckBox->Checked=false; It calls CheckBoxOnClick Event , how to avoid it ? 回答1: You could surround the onClick event code with something like if myFlag then begin ...event code... end; If you don't want it to be executed, set myFlag to false and after the checkbox state's change set it back to true. 回答2: Another option is to change the protected ClicksDisable property using an interposer class like this: type THackCheckBox = class