Watch, Follow, &
Connect with Us
Public Report
Report From: Delphi-BCB/VCL/Dialog Controls    [ Add a report in this area ]  
Report #:  89798   Status: Closed
TTaskDialog fails under Windows Class
Project:  Delphi Build #:  14.0.3593.2582
Version:    15.0 Submitted By:   David Heffernan
Report Type:  Basic functionality failure Date Reported:  11/18/2010 12:31:59 PM
Severity:    Serious / Highly visible problem Last Updated: 3/20/2012 2:24:39 AM
Platform:    32 Bit Internal Tracking #:   281258
Resolution: Fixed (Resolution Comments) Resolved in Build: : 16.0.4187.40539
Duplicate of:  None
Voting and Rating
Overall Rating: No Ratings Yet
0.00 out of 5
Total Votes: 6
Description
TCustomTaskDialog.DoExecute includes this line:

  if not ThemeServices.ThemesEnabled then
    raise Exception.CreateResFmt({$IFNDEF CLR}@{$ENDIF}SXPThemesRequired, [ClassName]);

This means that it cannot work under Windows Classic.  I suspect that the code should test ThemesAvailable.

Steps to Reproduce:
Show a Vista task dialog under the Windows classic theme
Workarounds
None
Attachment
None
Comments

Tomohiro Takahashi at 11/18/2010 7:02:33 PM -
> Show a Vista task dialog under the Windows classic theme
Do you get any error dialog or AccessViolation when calling Execute method?

> I suspect that the code should test ThemesAvailable.
Could you tell us more detail?

David Heffernan at 11/19/2010 7:38:24 AM -
The source code to TCustomTaskDialog.DoExecute raises an exception if themes are not enabled.  I included an extract in the description.

The error in the code is that the author mistakenly believes that the Vista TaskDialog requires themes to be enabled, but Vista TaskDialog works perfectly well when they are not, e.g. in Windows classic theme.

Server Response from: ETNACODE01