Solved

Weird problem - buttons without caption...

Posted on 2006-11-25
7
213 Views
Last Modified: 2010-04-05
I am experiencing the weirdest thing I ever encountered in Delphi... and so far I cannot explain it. And also I cannot solve it.

Some components (usual ones like CheckBox, ComboBox, Buttons, MessageBoxes) seem to have their caption invisible. So the text is there because I can see the surrounding dotted rectangle around it when they receive focus. Also for Comboboxes, they dropdown in the list and the list is as long as it should be but there is no text there... if I browse through it and select one of it's invisible items... the combobox shows me the text that was supposed to be in the dropdown list.
Also some ShowMessage boxes do not have the message body, and neither the buttons on the showmessage box. So the ShowMessage and MessageDlg... shows me a form with no text on it, and 1 or 2 buttons (Ok Cancel) but the buttons have no text on them . Everything on the standard ShowMessage and MessageDlg is empty.

The interesting thing is that I have to very similar forms that contain almost the same components (anyway the same component types like Edits, ComboBoxes... and so on), so there are no other types of components on them. And one of the forms works like a charm, the other gives me headackes.
The most interesting thing is that this behavior only seems to appear on certain computers. On my own ones they work great. But on one of my client's computers (3 computers) don't.

At first I thought maybe it's something wrong in the registry... but if it were, then all the forms that have MessageDlg and ShowMessage , Checkboxes and Comboboxes on them should have the same problem, but they don't.

Another thing: On these two particular forms that are 98% identical (the one that works and the other that doesn't) half of the components are created in design time and the other half are created on runtime.
Also another thing is that on both of them I use standard Delphi VCL components plus a Jedi component called jvScrollMax (where I create on runtime some components). But since I do almost the same steps in both forms I don't think that this component is to blame.

So this is probabely something internal in Delphi, but I cann't figure it out.
Any ideeas?

0
Comment
Question by:calinutz
7 Comments
 
LVL 11

Author Comment

by:calinutz
ID: 18012536
And yes... I free all my runtime created components if anyone asks..
0
 
LVL 11

Author Comment

by:calinutz
ID: 18012554
Also weird... (that makes me think it's something wrong with the registry) is that another application from my applications pack sent to the same client started to behave similarly. I mean, there is no jvScrollMax component in that application, and still some checkboxes, and Buttons on some forms do not have Captions on them.
0
 
LVL 28

Expert Comment

by:ciuly
ID: 18012618
well, first thing is first: the application works perfectly just that the text is not displayed, right? in this case try to make a small application that send a WM_gettext message to one of thos components (must have handle) and see if it gets anything (this app will be run by your client. something like winspy, if you can make your client use that correctly to get you teh information. but safest is to just make this small app :) )
this will tell you if there is a problem displaying or there is no text there ;)
second: showmessage and messagedlg do not have text???? I find it hard to believe since those are standard windows controls. delphi just creates some kind of wrapper on them.
so question is: are there some "weird" applications in the clients machine?
they didn't by any chance upgrade to vista, did they? (since one of your clients "started" having the issue, makes me think something changed in their environment, and the OS is first in my mind)

then comes fird: are you using some sort of components for skinning? or anything that changes the UI/appearence? hooking maybe? localization (as in translations)?
consider this scenario:
- application wants to display something, so it makes the call
- this call is being intermediated by "something" (skinning module, translation module, whatever)
- the modules bailes out for some reason and since it's badly written, the call is forgot
- the application doesn't get the response so there is nothing to display

I am thinking of the translation/skinning part. am I close? :D
0
Top 6 Sources for Identifying Threat Actor TTPs

Understanding your enemy is essential. These six sources will help you identify the most popular threat actor tactics, techniques, and procedures (TTPs).

 
LVL 3

Accepted Solution

by:
Ghitza earned 500 total points
ID: 18012748
Do you use by any chance an exe packer called RLPack (basic edition)?
I had a similar behaviour after packing my executables with this one. If so, then try packing them with something else... like UPX or something.
RLPack is very strong but seems to count on some resources that are local or something like that... and when you deploy the app the named resources are just not there with your app.

Best regards
Ghitza
(salutari)
0
 
LVL 4

Expert Comment

by:Meldrachaun
ID: 18013076
I've seen this kind of thing with custom colors.  If you're using custom colors, try using the standard clWindowText for the font color, and see if the text shows up.  If it does, than some security crazed nut has locked the end user out of using custom colors, and the user profile needs to be fixed.
0
 
LVL 11

Author Comment

by:calinutz
ID: 18014177
ciuly -- I do not use theming nor skinning and yes the error appears even for windows standard controls.
ghitza -- yours is the right guess (merci) I actually was using the RLPack (silly mistake)
Meldrachaun -- I thought of custom colors from the start but it wasn't that (I wasn't using any custom colors (just the standard ones) and I even tested it with changed colors for the captions with the same result)

Thanks to all
0
 
LVL 11

Author Comment

by:calinutz
ID: 18014180
I notified the RLPack team about this bug, so hopefully no one else will encounter this problem
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

This article explains how to create forms/units independent of other forms/units object names in a delphi project. Have you ever created a form for user input in a Delphi project and then had the need to have that same form in a other Delphi proj…
In this tutorial I will show you how to use the Windows Speech API in Delphi. I will only cover basic functions such as text to speech and controlling the speed of the speech. SAPI Installation First you need to install the SAPI type library, th…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

707 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now