vcl

Unresolved external SHCreateItemFromParsingName referenced VCL.LIB / Dialogs

孤街醉人 提交于 2019-12-11 09:46:40
问题 I have a C++ Builder application I'm porting from C++ Builder 6 to XE on Windows XP. A number of 3rd party controls are in use as well. I'm compiling with Dynamic RTL = False If I compile without run time packages I get the subject error message: [ILINK32 Error] Error: Unresolved external 'SHCreateItemFromParsingName' referenced from C:\PROGRAM FILES\EMBARCADERO\RAD STUDIO\8.0\LIB\WIN32\RELEASE\VCL.LIB|Dialogs If I compile with run time packages the error goes away. Googling around reveals

Creating a button with which a running process can be killed or terminated

∥☆過路亽.° 提交于 2019-12-11 07:58:52
问题 I would like to add a button to my form with which a running process (loop which runs several thousand times) can be terminated if the user wishes to stop the process for any reason or load another file. The program has a part which performs an interpolation for multiple cases and creates and saves a text file for each case. Once the process is launched (this is done by pressing a button after the necessary files have been loaded), it starts running and cannot be stopped until it is completed

make cppcheck skip the PACKAGE definition

僤鯓⒐⒋嵵緔 提交于 2019-12-11 06:58:03
问题 I'm using the GUI version of cppcheck 1.64 for static code analysis on C++-Builde-6 code. For DLL exports and imports, the definition of PACKAGE is necessary: /// A dialog exported from a BPL (a VCL-specific kind of DLL) class PACKAGE MySharedDialog { public: // lots of methods to-be checked private: // lots of methods to-be checked // lots of members }; Cppcheck stops when it encounters PACKAGE because it doesn't know what it means: The code 'class PACKAGE TAppInfoDialog {' is not handled.

Delphi XE2 VCL styles, weird glitch, window invisible

China☆狼群 提交于 2019-12-11 06:57:39
问题 I'm experiencing a very weird problem with VCL styles. Sometimes, when either starting the program with a predefined style, or setting one later on, one or some of the program windows dissapear. This happens very randomly, maybe once every 10-20 times, and not in any specific window. I have 2 forms open at runtime, sometimes it's one, sometimes the other. When this happens, I check some properties while the window is not visible, the Visible property is true, the window boundaries are correct

Assigning events to a VCL control created dynamically at runtime (2)

心不动则不痛 提交于 2019-12-11 05:05:11
问题 This is related to Assigning events to a VCL control created dynamically at runtime. I used the above listed/reference post to solve a problem that I had with some code. Thank you for providing that example. I found it very useful, and implemented the "alternative" way that it provided as I was unable to make the first way work. I am using C++Builder 10.x from Embarcadero. I just updated to C++Builder 10.3. This new update is now throwing a warning: [bcc32c Warning] LogitToMemo.cpp(196):

Delphi cxtreelist looping through nodes

心已入冬 提交于 2019-12-11 04:52:05
问题 I have a tcxTreeList with 3 columns the first column has set property of Node.CheckGroupType := ncgCheckGroup; , and 2nd column contains Key of the First root node and third column contains the keys of all child nodes under the root node. How can i get the key of root node whether it is checked or not and keys of all checked child nodes into 2 variables to insert into db and Load back items from keys we get from DB My code for adding items is as below APNode := tv.Add; APNode.CheckGroupType :

Delphi - Capturing the Window/Form which has current focus

元气小坏坏 提交于 2019-12-11 03:15:41
问题 I have an MDI application with numerous MDI Children (and also non MDI forms) and would like to track which form is currently activate and has the focus at all times. When a user switches from one form to another within the application I would like to trap the window activation message and in the background set a global variable to a property of the form which is active (this property is inherited from a base class). I originally put code in the OnActivate event handler for the base class

Closing a secondary delphi form causes the main form to lose focus

a 夏天 提交于 2019-12-11 00:49:12
问题 When showing a secondary form from the main form and from the second form showing a third form and then closing both forms will cause the main form to lose focus. Using Delphi 2009 with XP SP3 Here are my steps for reproducing the problem: Create a new VCL forms applications Drag a button onto the created form In the click handler create a new TForm1 and show it Run the program. Click the button to show a second form. Click the button on the second form to create a third form. When closing

How do you find the package a Delphi component comes from?

巧了我就是萌 提交于 2019-12-11 00:37:56
问题 You used to be able to get the package a Delphi component was installed under from the palette. That functionality doesn't seem to be in the lastest versions, though. How can I find which package a component belongs to under D2007 or D2009? 回答1: I don't know of any way to do this through the Delphi IDE. However, you can do a search in your registry for the component name. For instance, to find the package that TBitBtn belongs to, open RegEdit and do a search (on Keys only) for TBitBtn. The

How can I add a border to every form in my application without modifying each form's code?

自古美人都是妖i 提交于 2019-12-10 21:23:08
问题 We have a large legacy database driven VCL application which consists of over 300 different forms. We would like to provide a practice (dummy) database along with our software which is installed alongside their production database - with the ability to switch in-between them (for training / practice, etc.). The problem is that when users are using the practice mode, we have to make something very clear to stand out to them so they know they're working in the practice mode. The most ideal