Where Developers Matter
Integrated Development Environments for Windows, Java, and Web Developers
| | Log On

RAD Studio 2007 - List of Fixes to Delphi.NET in December Update

By: Chris Pattinson

Abstract: List of 157 fixes (40 from Quality Central) for RAD Studio 2007, Delphi.NET personality in the December Update

QC# Project Area
Delphi.Net IDE\HTML\ASP\Designer
Description: Steps:
When using "composite controls" in the designer the Control does not render correct (it shows as a small square thus being cropped). Once in the design mode, of the control is moved, it will paint correctly, however; toggling to aspx and back to design will again mispaint the control. Open attached project
Click on design tab.
Expected (see attached bmp):
Two textBoxes and a button
Actual:
small little box (composite)
Move the control to the right.
Notice the "actual" control renders

QC# Project Area
Delphi.Net Debugger\Evaluator
Description: Steps:
Format specifiers have no effect in the evaluator. Set a breakpoint on the line marked #1 and run.

Evaluate the following expression.

IntegerVar,h

See the following result.

42

The value expected was 2A or $2A.


program Test;

{$APPTYPE CONSOLE}

var
IntegerVar: Integer;

begin
IntegerVar := 42;
WriteLn(IntegerVar); // #1
end.

QC# Project Area
Delphi.Net Compiler\Language\Overloading
Description: Steps:
In .NET 2.0 the CLR introduced new overloaded methods to System.String.Split. One new overload takes a string array which is ambiguous with the char array version. Compile the following against .NET 2.0.40607:

procedure OverloadSplitTest(S: System.String);
var
splits: array of string;
begin
splits := S.Split([',','.']);
end;

It will now fail with an ambiguous overload error.

QC# Project Area
Delphi.Net IDE\HTML\ASP
Description: Steps:
Hard-coded string in source (see comment from Takeshi Arisawa for specifics).


Original bug description follows:
----------

One Filelist-Entry is not translated
"ASP.NET Files" should be
"ASP.NET-Dateien"
1. Click on DATEI - ÖFFNEN
2. open the Dateiliste
3. Scroll to ASP.NET Files

QC# Project Area
Delphi.Net Database\dbExpress Metadata
Description: Steps:
#6 - For SqlConnection.GetTableNames the tablescope property is not
being respected for either dbxmss30.dll when you include
tsSysTable in addition to tsTable.

For MsSql you are calling sp_table_rowset which only accepts 1 table type, and not a set of table types. If you specify just tsSysTable then it works.

QC# Project Area
Delphi.Net ECO\IDE Integration
Description: Steps:
please change the layout of the "Select UML Packages for the ECO Space" dialog for localization. "Cancel" button does not fit into the dialog after we translate.
------------
"Cancel" button in ECO's Select Packages wizard is slightly truncated.
- Open a new ECO WinForm;
- Go to EcoSpace Designer and click a grey folder icon in the lower left corner;
//"Select UML Packages for the ECO Space" dialog opens;
// See the attached screenshot.

QC# Project Area
Delphi.Net IDE\Packages
Description: Steps:
HOT FIX ROLL UP 1-10

Object ref not set on shut down of IDE if you uncheck a Win32 package, while you have a .NET app open.

STACK TRACE Attached
boot IDE
New VCL.NET App
Save All
Tools | Options - set Save Project Desktop ON
Save All
Shut down IDE
Start IDE
// VCL.NET app should be open
Component | Install Packages
uncheck one
OK
Close IDE

//Object Ref not found

QC# Project Area
Delphi.Net IDE\Help
Description: Steps:
Press F1 in Delphi.Net's WinForm or ASP WebForm's code editor got error

Error
---------------------------
Abstract Error.
---------------------------
OK Details >>
---------------------------

[HelpUpdate]
1. File | New | Delphi.Net | WinForm Application (or ASP Application)
2. click Code tab
3. click any keyword, ie : type or uses or anywhere
4. press F1

//Abstract Error.
+ $12[00347E7A]{rtl110.bpl } SysUtils.SysUtils.AbstractErrorHandler (Line 14258, "sys\sysutils.pas" + 0) + $12
+ $6[209D9271]{coreide110.bpl} EditorControl.EditorControl.TCustomEditControl.HelpKeyword (Line 4428, "EditorControl.pas" + 8) + $6
+ $17[209DF0D8]{coreide110.bpl} EditorControl.EditorControl.TCustomEditControl.AutoInvokeCodeCompletion (Line 7255, "EditorControl.pas" + 1) + $17
+ $6[0047D115]{vcl110.bpl } Controls.Controls.TWinControl.WndProc (Line 8923, "Controls.pas" + 129) + $6
+ $6[0047C8A8]{vcl110.bpl } Controls.Controls.TWinControl.MainWndProc (Line 8659, "Controls.pas" + 3) + $6
+ $0[0037107C]{rtl110.bpl } Classes.Classes.StdWndProc (Line 11596, "common\Classes.pas" + 8) + $0
+ $6A[77D48731]{USER32.dll } GetDC + $6A
+ $14A[77D48811]{USER32.dll } GetDC + $14A
+ $17F[77D4B4BB]{USER32.dll } DefWindowProcW + $17F
+ $1CD[77D4B509]{USER32.dll } DefWindowProcW + $1CD
+ $10[7C90EAE0]{ntdll.dll } KiUserCallbackDispatcher + $10
+ $44[77D5F3DE]{USER32.dll } SendMessageA + $44
+ $1B[209C9C7A]{coreide110.bpl} VClient.VClient.KeyBindingProc (Line 2644, "VClient.pas" + 20) + $1B
+ $2C[2099A20E]{coreide110.bpl} IDEKbd.IDEKbd.@interpret_bmi_macro$qqrp5BMI_tpcp11CmdMapTableppc (Line 30, "bmi.cpp" + 5) + $2C
+ $10[20998E0A]{coreide110.bpl} IDEKbd.IDEKbd... (Line 132, "kbpublic.cpp" + 88) + $10
+ $18[209C73B0]{coreide110.bpl} VClient.VClient.KbdFileOpen (Line 460, "VClient.pas" + 2) + $18
+ $8[20A6EA94]{coreide110.bpl} KbClient.KbClient.TIDEKBDFrameAPI.ProcessKeyStroke (Line 723, "KbClient.pas" + 141) + $8
+ $5[20A6E519]{coreide110.bpl} KbClient.KbClient.TIDEKBDFrameAPI.KeyboardChanged (Line 517, "KbClient.pas" + 6) + $5
+ $2[20A6E829]{coreide110.bpl} KbClient.KbClient.TIDEKBDFrameAPI.ProcessKeyStroke (Line 585, "KbClient.pas" + 3) + $2
+ $2[20A6F55C]{coreide110.bpl} KbClient.KbClient.TIDEKBD

    39104

QC# Project Area
39104 Delphi.Net ECO\Persistence Layer
Description: Steps:
[QC Short Description]
ECO crashes when selecting data conditionally from SQL 2005 when the number or rows exceeds certain amount.

[QC Description]
Attached is the test project I created. Please correct the connection string in order to connect to your own SQL server.
The EcoSpace is setup to use GUID as the keys; and the only ECO class is named "Class_1" with only one boolean attribute "Active". The winform contains 3 buttons, the "+ 10" would create and add 10 rows to the DB. the "All" would bind the datagrid to the expression "Class_1.allInstances" and the button "Active" would bind the datagrid to the expression "Class_1.allInstances->select(Active)"

1. setup SQL server and generate the schema
2. run the program and add 10 rows
3. check the "All" and "Active" buttons work properly
4. press 2 more times of the add buttons to add 20 more rows
5. check again the "All" and "Active" buttons work
6. close and restart the program
7. the "All" button works but the "Active" button would crash the program with exception "Conversion failed when converting from a character string to uniqueidentifier."

Reset the EcoSpace to use AutoInc as keys and repeat the test would result in exception: "Error executing SQL: SELECT Class_1_ALIAS.ECO_ID, Class_1_ALIAS.ECO_TYPE, Class_1_ALIAS.Active_COL FROM Class_1 Class_1_ALIAS WHERE Class_1_ALIAS.ECO_ID IN (, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , )"

P.S. my config:
Windows XP SP2 with all updates, BDS 2006 Update 1 with all hotfixes, MS SQL 2005 Express
QC Entry 39104
1. setup SQL server and generate the schema 2. run the program and add 10 rows 3. check the "All" and "Active" buttons work properly 4. press 2 more times of the add buttons to add 20 more rows 5. check again the "All" and "Active" buttons work 6. close and restart the program 7. the "All" button works but the "Active" button would crash the program with exception "Conversion failed when converting from a character string to uniqueidentifier." Reset the EcoSpace to use AutoInc as keys and repeat the test would result in exception: "Error executing SQL: SELECT Class_1_ALIAS.ECO_ID, Class_1_ALIAS.ECO_TYPE, Class_1_ALIAS.Active_COL FROM Class_1 Class_1_ALIAS WHERE Class_1_ALIAS.ECO_ID IN (, , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , , )"

QC# Project Area
Delphi.Net VCL
Description: Steps:
Access Violation in module rtl100.bpl when pressing F1 on a menu item (in this test case - the File menu)

//note - I notice no help is linked to these menu items. Is that related? CP

//This can put the IDE into a state where you need to close it, since the AV dialog keeps coming back up.

========== jt add =========
this is VCL Actionband component problem, new steps added.

regression from D2006, in D2006, no AV only "No context-sensitive help installed." pop up, which is as expected.

// Francois Piette
I still see it with build 2700.
---- See actionband steps for VCL.NET ----

Infrequent, but I can get this to reproduce and crash the IDE after doing three times

Project | Options
Click help to open
minimize the Help viewer
Open File menu
mouse over 'Open...'
click F1

//typically this is where the A/V occurs.

=================== jt add ===================
1. File | New | VCL Win32 Application
2. drop a TActionManager, TActionMainMenu, TMemo on designer
3. double click TActionManager, add Edit category standard Action
4. drag Edit Category from Customize Dialog to ActionMainMenuBar1
5. Run with debug
6. in Running application, click File
7. mouse hover on "Paste" menu item
8. press F1
---------------------------

---------------------------
Access violation at address 00439918 in module 'Project1.exe'. Read of address 00000040.
---------------------------
OK
---------------------------

9. click OK then
---------------------------

---------------------------
No context-sensitive help installed.
---------------------------
OK
---------------------------

QC# Project Area
Delphi.Net IDE\Refactoring\Rename
Description: Steps:
ORIGINALLY REPORTED FOR JA... BUT CAN REPRODUCE THIS ON EN.

[FUNCTION ISSUE]
Rename function is wrong. It was not changed definitely, for example, when I changed variable name from 'i' to 'test'. See attach image.
1. Startup | CodeGear RAD Studio
2. File | New | VCL Forms Application - Delfhi for .NET
3. Coding
4. Refactoring | Rename "..."

    48693

QC# Project Area
48693 Delphi.Net IDE\HTML\ASP\Designer\Web Controls
Description: Steps:
[QC Short Description]
You cannot bind properties to values in resource files using the expression dialog

QC Entry 48693
1) Create a new asp.net web application 2) Go to the designer for webform1.aspx and add a asp.net label to the designer surface 3) In the object inspector, inspect the label and click on the expressions property value to launch the label1 expressions dialog 4) select text as the bindable property 5) set expression type to resources 6) In the expressions properties, classkey and resourcekey are available properties expected: you should be able to enter a value for resourcekey actual: it appears to be readonly Note: If you modify the markup by hand ie <asp:Label id="Label1" runat="server" Text="<%$ Resources:Resource, Welcome %>"></asp:Label> Then classkey is set to Resource and resourcekey is set to Welcome Unfortunately The text property in the inspector is empty, it should be Expression: Resource, Welcome

    47453

QC# Project Area
47453 Delphi.Net IDE\Docking
Description: Steps:
[QC Short Description]
Dock Tabs appear at wrong position

[QC Description]
If for instance in the delivered Default Layout the Object Inspector is unpinned, it's caption appears as a vertical tab on the left of the structure view. Saving this layout, switching to another one and switching back makes the tab appears to the right of the structure view. Reselecting the current layout brings the tab back where it belongs.
QC Entry 47453
if necessary, copy the factory "Default Layout.dst" from "<program files>\CodeGear\RAD Studio\5.0\bin" to "<Application Data>\Borland\BDS\5.0\" (Borland???) - start IDE - select "Default Layout" - unpin Object Inspector - save current layout overwriting Default Layout - select Debug Layout - select Default Layout exp: Object Inspector tab left from Structure View act: Object Inspector tab right from Structure View - select Default Layout exp: Object Inspector tab left from Structure View act: Object Inspector tab left from Structure View

QC# Project Area
Delphi.Net IDE\Help
Description: Steps:
No help found for context" message when you click the Help button in the Template Libraries dialog. 1. File | New | Other
2. Right-click in right pane
3. Select Template Libraries...

QC# Project Area
Delphi.Net IDE\Code Parameters
Description: Steps:
parameter tooltip is not displayed correctly in this test case. Tooltip is not displayed for one of the parameters.

looks like code parameters are not working for membership provider.

(jpg attached)
1. Create ASP .NET App
2. On Page_Load function in Default.pas, write following
Membership.ValidateUser(
// exp: ValidateUuser has two parameters, username and password, so expect to have tooltip for "username" after "(" is entered
// act: tooltip for password is displayed

try FormsAuthentication.RedirectFromLoginPage also. Code completion displays the correct parameter, but parameter tooltips are completely wrong.

QC# Project Area
Delphi.Net IDE\HTML\ASP
Description: Steps:
Full source codes for the ASP.Net providers are not delivered in the build. The following files should be delivered:

$(BDS)\source\dotNet\asp\provider\aspnet_regdb.dpr
$(BDS)\source\dotNet\asp\provider\aspnet_regdb.dproj
$(BDS)\source\dotNet\asp\provider\aspnet_regdb.inc
$(BDS)\source\dotNet\asp\provider\Borland.Web.Commands.pas
$(BDS)\source\dotNet\asp\provider\Borland.Web.Management.AdoWebEventProvider.pas
$(BDS)\source\dotNet\asp\provider\Borland.Web.Management.DbSetup.pas
$(BDS)\source\dotNet\asp\provider\Borland.Web.Profile.AdoProfileProvider.pas
$(BDS)\source\dotNet\asp\provider\Borland.Web.Provider.dpk
$(BDS)\source\dotNet\asp\provider\Borland.Web.Provider.dproj
$(BDS)\source\dotNet\asp\provider\Borland.Web.Provider.inc
$(BDS)\source\dotNet\asp\provider\Borland.Web.Security.AdoMembershipProvider.pas
$(BDS)\source\dotNet\asp\provider\Borland.Web.Security.AdoRoleProvider.pas
$(BDS)\source\dotNet\asp\provider\Borland.Web.Strings.pas
$(BDS)\source\dotNet\asp\provider\Borland.Web.UI.WebControls.WebParts.AdoPersonalizationProvider.pas
$(BDS)\source\dotNet\asp\provider\Borland.Web.Utilities.pas
$(BDS)\source\dotNet\asp\provider\License.txt

QC# Project Area
Delphi.Net Modeling\Class Diagram
Description: Steps:
Delphi.Net: Show generic parameters of functions on the class icon. Now only class with generic parameters has distinction from ordinar class, it would be better if generic functions as well have distinctions. The better way to show these parameters as a part of name.
A = class
function F<T>:Integer; // now is shown as F, but F<T> is expected
procedure P<Y>; // the same
end;

QC# Project Area
Delphi.Net Documentation
Description: Steps:
The API signature information, such as method signatures, is missing in a lot of the documentation. For instance, the topic "Borland.Data.AdoDbxClientProvider.TAdoDbxDataAdapter.DeleteCommand" doesn't have a description of the method. 1. Go to topic "Borland.Data.AdoDbxClientProvider.TAdoDbxDataAdapter.DeleteCommand" at ms-help://borland.bds5/delphivclwin32/Borland_Data_AdoDbxClientProvider_TAdoDbxDataAdapter_DeleteCommand.html. Note there is no line with the method signature.
2. By contrast, look at the topic "TCustomActionCombo.DragDrop Method" at ms-help://borland.bds5/delphivclwin32/ActnCtrls_TCustomActionCombo_DragDrop@TObject@Integer@Integer.html. There are lines describing the method both in C++ and Delphi.

QC# Project Area
Delphi.Net Database
Description: Steps:
Implement TDBXBinaryLongSequenceGenerator

Use new TDBXBlobSequenceGenerator has getBytes and getString method.

QC# Project Area
Delphi.Net Database
Description: Steps:
Implement TDBXBinarySequenceGenerator

Use new TDBXBlobSequenceGenerator has getBytes and getString method.

QC# Project Area
Delphi.Net ECO\IDE Integration
Description: Steps:
When creating a WebForm app and a model package at the same time, the initialization of the EcoSpaceUnit fails with a designer error

1) File | New | Other | Eco | Eco Delphi.Net Project Wizard
2) Select the preset, Webform application and set the checkbox ON for "In separate assembly. click OK
//result:
EcoSpaceUnit opens in the designer with this error:
An error occurred while loading the document. Fix the error, and then try loading the document again. The error message follows:
Could not find type 'EcoSpaceUnit.PersistenceMapperSharer'. Please make sure that the assembly that contains this type is referenced. If this type is a part of your development project, make sure that the project has been successfully built. The variable 'PersistenceMapperSharer1' is either undeclared or was never assigned.
3) In Project Manager, double-click PersistenceMapperProvider.pas to open it
4) Click on the Design tab
//result:
Similar Designer errors
// comment from Jonas:
The project compiles without problems. if you close the project and reopen it, the designer works just fine.

If you create the project with the model in the same project as the rest (uncheck "In Separate assembly"), the same ecospace opens up just fine the first time.

The exception that actually occurs in the IDE is the following:

===
A first chance exception of type 'System.ComponentModel.Design.Serialization.CodeDomSerializerException' occurred in System.Design.dll

Additional information: The variable 'PersistenceMapperSharer1' is either undeclared or was never assigned.
===

callstack (see attached)

    50936

QC# Project Area
50936 Delphi.Net IDE\HTML\ASP\Providers
Description: Steps:
[QC Short Description]
Attempting to create users results in the error DuplicateProviderUserKey when the provider is attached to MySql via the AdoDbxClient

[QC Description]
The membership provider does not work against mysql and the adodbxclient
QC Entry 50936
1) Create a mysql database I'm using version 5.0.41-community-nt MySQL Community Edition (GPL) 2) Create a connectionstring in machine.config and run aspnet_regdb against that database 3) Open the supplied example 4) Modify the connectionstring in web.config so that it connects to your MySql database 5) Open CreateAccount.pas and set a breakpoint on procedure TWebForm4.CreateUserWizard1_CreateUserError(sender: TObject; e: System.Web.UI.WebControls.CreateUserErrorEventArgs); begin end; 7) Run the application and you should end up with CreateAccount.aspx in the browser 8) Enter all the user details and hit the create user button actual: The breakpoint is hit inspect e._error and its 10(0xa) 'DuplicateProviderUserKey' run the application The message below is displayed in the browser Your account was not created. Please try again. expected: The user should be created Note: I have successfully run this application against System.Data.SqlClient and Blackfish, so I think its something about about mysql or the dbxclient

QC# Project Area
Delphi.Net Modeling\Class Diagram
Description: Steps:
Delphi .Net and Win32: it should be possible to rename a procedure inplace in the diagram. Now new name is rejected and old one is kept.
Note 1: functions are renamed inplace ok
Note 2: the same procedures are renamed ok from Object Inspector.

[Highlander Update]

QC# Project Area
Delphi.Net Modeling\Patterns
Description: Steps:
Delphi.Net and Win32: Stub implementation: don't loose parameter's modifiers.

[Highlander Update]
1. Original code (e.g. for Win32):
Interface1 = interface
procedure Proc1 (const name: string; Var param1 : Integer; out param2 : Integer);
end;
Class1 = class (TInterfacedObject, Interface1)
end;
2. Now for Class1 generated Stub Implementation. Results:
Class1 = class (TInterfacedObject, Interface1)
procedure Proc1( name : String ; param1 : Integer; param2 : Integer);
end;
So, all parameters' modifiers (const, var, out) are lost and the code is not compilable.

QC# Project Area
Delphi.Net Documentation
Description: Steps:
deployJds.html deployment chapter is missing sections from sshaughnessy on how to deploy slip license files.

Also needs latest update for $(BDSCOMMONDIR)\license as one of the dirs to search for licenses.

I have provided content to Kim and Dee. Waiting for response that work is complete.
This refers to the Blackfish SQL Developer's Guide which is not in the help system. It is downloadable at: http://cc.codegear.com/Item/24980.

You can use the PDF search to find the section on slip licenses.

Thanks Emeli! -Dee

    51076

QC# Project Area
51076 Delphi.Net Database\Data Explorer
Description: Steps:
[QC Short Description]
Stored procedures cannot be dropped from the database if the dotnet implementation no longer exists

[QC Description]
If I have a Blackfish stored procedure in the database called SOMEOTHERMETHOD and I rename the method in the Delphi implementation I am no longer able to drop the method in Data Explorer
QC Entry 51076
1) Create a new Blackfish Remote database in Data Explorer 2) Open the supplied example and compile 3) Copy the assembly to wherever Blackfish is looking for assemblies 4) Register the method with Blackfish CREATE METHOD SomeOtherMethod as 'Other::Other.TMyStoredProcedures.SomeOtherMethod' 5) Stop the Blackfish service 6) Open Other.StoredProcedures in the edtior and rename the method SomeOtherMethod to AnotherSomeOtherMethod 7) Build and copy the assembly to the same place as step (3) 8) Start the Blackfish server 9) In dataexplorer example the stored procedure list SomeOtherMethod is listed but there are no parameters 10) In a sql window attempt to drop the method drop method "SomeOtherMethod" expected: stored procedure should be dropped actual: an error message is displayed [line1, col 1] A method with the name "SOMEOTHERMETHOD" doesn't exist

QC# Project Area
Delphi.Net Database\dbExpress Metadata
Description: Steps:
For Oracle, Boolean parameters are retrieved as Unknown Type.

[Nov Update]
1. For an Oracle db:

CREATE PROCEDURE BOOLEAN_ECHO_ORACLE(IN_PARAM IN BOOLEAN, OUT_PARAM OUT BOOLEAN) AS BEGIN OUT_PARAM := IN_PARAM;END;

2. In Data Explorer, navigate to this stored procedure and double click on it to view it's parameters

Exp. Value field blank
Act. Value field contains Object reference not set to an instance of an object

    51094

QC# Project Area
51094 Delphi.Net IDE\HTML\ASP\Designer
Description: Steps:
[QC Short Description]
The Smart Task Menu doesn't get displayed when the control is in a Panel or an UpdatePanel

[QC Description]
When the control is in a Panel, it's smart task menu doesn't be displayed. Please see the steps for details.
QC Entry 51094
- Download and open the sample project that I've attached. - Open Default.aspx in the designer and scroll down to the GridView. - Right click on the GridView. - Select Smart Task from this context menu. Actual: - Nothing happens. - However, there isn't the smart task's arrow in the top corner of the control. Expected: - The Smart Task shows up. Also the smart task indictator that is normally displayed in the top right hand corner of the control isn't visible

QC# Project Area
Delphi.Net Modeling
Description: Steps:
Delphi Win32 and .Net: add parameters with var/out/const modifier to global procedure/function using "Add/Remove Parameters for Operation" dialog both to interface and implementation sections. Now only in interface sections parameters with modifiers are partially set.
Adding parameters without modifier happens ok.
Adding paramerters with modifier to procedure/function within a class happens ok.

[Highlander Update]
1. Source code:
unit Namespace1;
interface
procedure p;
implementation
procedure p;
begin
end;
end.
2. case a. Now select p in Model View and try to change parameters from Object Inspector using "Add/Remove Parameters for Operation" dialog. Add one parameter and set any modifier var/out/const for it - parameter is added to both parts, but modifier is present only in interface part:
unit Namespace1;
interface
procedure p(out param0 : Integer);
implementation
procedure p( param0 : Integer ); // out is lost
begin
end;
end.

2. case b. Using the same dialog as in case a, try to add 2 parameters and modifier set only for first one (it's important that it should be a parameter after parameter with modifier). Result: exception dialog (see attachement).
Resulting code:
unit Namespace1;
interface
procedure p(out param0 : Integer ; param1 : Integer);
implementation
procedure p( param0 : Integer ); // out and other parameters are lost
begin
end;
end.

QC# Project Area
Delphi.Net Install
Description: Steps:
Missing required disk space size information at Setup Cache page during standalone Help_Setup process, attached screen shot. - install HL w/out Help
- start IDE and register it
- close IDE
// used Highlander.Help/0828.1/*
- install Help via Setup /upgrade

QC# Project Area
Delphi.Net Database\DBExpress
Description: Steps:
Putting a TSqlConnection on a VCL.Net form automatically pulls in the unit DBXpress. This is a virtually empty unit, it only contains a uses clause or two. the problem is that it is deprecated, so the compiler will issue a warning everytime it is used.

Holger pointed it out in the first place :)


the reason it is pulled in is because of:

procedure TSQLConnectionSelectionEditor.RequiresUnits(Proc: TGetStrProc);
begin
Proc('DBXpress');
end;

in <tp>\app\dotnetlib\db\Borland.Vcl.Design.DbxCtrlsReg.pas

description of the RequiresUnit:
Should call Proc with all the units that are needed to be used when using this class. The form designer automatically ensures the unit the class was declared in and all its ancestor's units are used in the user's program when they use this component. Sometimes, however, an event will use a type in one of its parameters that is not in its unit nor any of its ancestor's units. If this is the case a selection editor should be registerd that implements RequiresUnits and it should call Proc for each unit that declare the types needed by its events
new VCL.Net app
drop TSqlConnection on the form
compile

exp: compiles wihtout warnings
act: [DCC Warning] Unit1.pas(16): W1006 Unit 'Borland.Vcl.DBXpress' is deprecated

QC# Project Area
Delphi.Net Compiler\Language\Parameterized Types
Description: Steps:
Generic constraint checking fails spuriously for instantiation of a descendant of the constraint, using another type parameter in declaration of descendant (see example code)

More complicated generic solutions need this flexibility to reduce redundant dependent types when declaring descendants, since .NET doesn't have a typedef-in-template equivalent like C++.
This program doesn't compile:

Error: E2515 Type parameter 'U' is not compatible with type 'TBaseAlpha<TConcrete<T>.T>'

---8<---
{$apptype console}

type
TBaseAlpha<T> = class
private
F: T;
public
property P: T read F write F;
end;

TBase<T; U: TBaseAlpha<T>> = class
public
F: U;
procedure M(x: T);
end;

TConcreteAlpha<T> = class(TBaseAlpha<T>)
end;

TConcrete<T> = class(TBase<T, TConcreteAlpha<T>>)
end;

procedure TBase<T;U>.M(x: T);
begin
F.P := x;
end;

var
x: TConcrete<Integer>;
begin
x := TConcrete<Integer>.Create;
x.F := TConcreteAlpha<Integer>.Create;
x.M(42);
Writeln(x.F.P);
end.
--->8---

For comparison, here's the same program in C#:

---8<---
using System;

class TBaseAlpha<T>
{
T F;
public T P { get { return F; } set { F = value; } }
}

class TBase<T, U>
where U: TBaseAlpha<T>
{
public U F;
public void M(T x)
{
F.P = x;
}
}

class TConcreteAlpha<T> : TBaseAlpha<T>
{
}

class TConcrete<T> : TBase<T, TConcreteAlpha<T>>
{
}

class App
{
static void Main()
{
TConcrete<int> x;

x = new TConcrete<int>();
x.F = new TConcreteAlpha<int>();
x.M(42);
Console.WriteLine(x.F.P);
}
}
--->8---


QC# Project Area
Delphi.Net Compiler\Language\Overloading
Description: Steps:
Overloading generic method with open array method fails with internal error / AV Code fails to compile:

---8<---
{$apptype console}

type
C2 = class
class procedure P<T>(const x: array of T); overload;
class procedure P(const x: array of string); overload;
end;

procedure Go;
begin
C2.P([42]); // ##OUTPUT: array of T
C2.P(['42']); // ##OUTPUT: array of string
end;

class procedure C2.P<T>(const x: array of T);
begin
Writeln('array of T');
end;

class procedure C2.P(const x: array of string);
begin
Writeln('array of string');
end;

begin
Go;
end.
--->8---

QC# Project Area
Delphi.Net Compiler\Language\Overloading
Description: Steps:
Spurious ambiguous overload problem when generic class has overloaded methods taking open arrays, and one of the open array parameters is of a type parameter type Code (fails to compile with ambiguous error):

---8<---
{$apptype console}

type
C<T> = class
class procedure P(const x: array of T); overload;
class procedure P(const x: array of string); overload;
end;

procedure Go;
begin
C<Integer>.P([42]); // ##OUTPUT: array of T
C<string>.P(['42']); // ##OUTPUT: array of string
end;

class procedure C<T>.P(const x: array of T);
begin
Writeln('array of T');
end;

class procedure C<T>.P(const x: array of string);
begin
Writeln('array of string');
end;

begin
Go;
end.
--->8---

QC# Project Area
Delphi.Net IDE\Project Manager\Add reference
Description: Steps:
Together issue.
Removing a reference to System.Windows.Forms.dll from a VCL project causes a catastrophic error

the exception occurs in platformProjectImpl.cs, line 343.

IOTAReferences refs = p.References;
for (int i = 0; i < refs.Count; i++) {
IOTAReference iotaRef = refs[i];
string refName = iotaRef.Name; <<<< Here

bugfind credits goes to Holger

Workaround: Close the project, and reopen. Project builds and reference is removed.
Steps:
* New VCL .net form
* switch to model view tab
* enable modelling
* answer yes to all save dialogs
* Add reference to System.Windows.Forms.dll
* Remove the reference again

exp: reference gone
act: Catastrophic failure
------------------
ADDITIONAL: Project | Build results in a catastrophic faliure.
------------------
callstack on managed side:
[Managed to Native Transition]
> Borland.Studio.Together.dll!Borland.Studio.Together.Impl.Project.PlatformProjectImpl.updateReferences() Line 343 + 0x9 bytes C#
Borland.Studio.Together.dll!Borland.Studio.Together.Impl.Project.PlatformProjectImpl.onModified(object sender = {Borland.Studio.Interop.InteropModuleService.OTAProject}, System.EventArgs args = {System.EventArgs}) Line 955 + 0x7 bytes C#
[Native to Managed Transition]
[Managed to Native Transition]
Borland.Studio.Interop.dll!Borland.Studio.Interop.InteropModuleService.OTAModule.Borland.Studio.Interop.IInteropNotifier.Modified() Line 2063 + 0x15 bytes C#
[Native to Managed Transition]

callstack on native side:
[5304E633]{dotnetcoreide100.bpl} ToolsAPIWrapper.TInteropModule.Modified (Line 2577, "ToolsAPIWrapper.pas" + 3) + $2A
[4000A455]{rtl100.bpl } System.@CheckAutoResult (Line 18047, "sys\system.pas" + 6) + $0
[5217DA56]{coreide100.bpl} DocModul.TCodeIDocModule.NotifyModifiedEvent (Line 2355, "DocModul.pas" + 2) + $5
[0173666A]{designide100.bpl} ToolUtils.ForEach (Line 90, "ToolUtils.pas" + 5) + $F
[5217DAF0]{coreide100.bpl} DocModul.TCodeIDocModule.NotifyModified (Line 2362, "DocModul.pas" + 1) + $11
[5217A791]{coreide100.bpl} DocModul.TDocModule.Modified (Line 1235, "DocModul.pas" + 6) + $3
[520EB66E]{coreide100.bpl} ProjectModule.TBaseProject.Modified (Line 1204, "ProjectModule.pas" + 1) + $3

QC# Project Area
Delphi.Net Debugger\Interaction with IDE
Description: Steps:
You are unable to change either the Working directory or the Debug source path for an ASP.net app if the ASP.net option "Host with web server" is enabled Create a new delphi.net ASP.Net application
Run | Parameters
Note that the all the controls on the "Debugger" page are disabled.
Only the Host application and Parameters fields need to be disabled in this case

Note: If you uncheck "Host with web server" on the ASP.Net options page, then you can set the source path and working directory.

QC# Project Area
Delphi.Net Modeling\SCI
Description: Steps:
Find a solution to canhas projects with the same structure (names) in one folder.

[Highlander Update]
1. Create Delphi.Net Package project (Package1) in the default folder for projects.
2. Create namespace (Namespace1) in the project and Class (Class1) in this namespace.
3. Create another project (Package2) in the same folder.
4. Repeate item 2. for project Package2.

Class2 is not created.

AD : SCI asks VFSProject (for 'Package2') to create file with name 'Namespace1.pas' which already exists (in project 'Package1').


Now Class 2 is created and code is Ok.
But when project Package1 is opened, it can be noted that Class 2 is appeared.

    51165

QC# Project Area
51165 Delphi.Net IDE\Code Editor
Description: Steps:
[QC Short Description]
Code Folding: incorrect for generic classes/methods

[QC Description]
Code folding is sometimes missing, sometimes misplaced when a unit contains generic classes, interfaces and the methods of their implementations.

There is no obvious pattern to this behaviour, i.e. it is not always the first, second, etc. Neither is it resolved by scrolling and redrawing.
QC Entry 51165
open attached .pas file.

see code folding missing on line 43

--------------
Write a couple of generic classes/interfaces in the same unit. Ensure that they have a few methods each in the implementation section.

    51114

QC# Project Area
51114 Delphi.Net IDE\Code Editor\Error Insight
Description: Steps:
[QC Short Description]
ErrorInsight reports valid Methods as errors

[QC Description]
error-insight seems to report some entries that are actually correct. A
valid and existing method gets red-dotted.
QC Entry 51114
Please take the following example wich compiles fine: --------------------- uses System.Collections.Generic; type TApfel = class(TObject); TMyAepfelList = List<TApfel>; procedure Foo; var Apfel : TApfel; List1 : TMyAepfelList; begin Apfel:= TApfel.Create; List1:= TMyAepfelList.Create; List1.Add( Apfel ); // <-- error here 'Add' is red-dotted end; ---------------------

    51096

QC# Project Area
51096 Delphi.Net IDE\Class Completion
Description: Steps:
[QC Short Description]
class completion duplicates field of qualified type

[QC Description]
When class completion is invoked on a class having a property with a qualified type name (one with at least one dot), the corresponding field is created for each invocation.

This is as mainly seen in .NET where qualified types are common, but also reproducable in Win32.

I actually stumbled across it using ECO where each ECO form has an EcoSpace property of type Eco.Handles.DefaultEcoSpace. Thus each invoked class completion adds another field for that property.
QC Entry 51096
- start IDE - create new VCL Form Application - move to the public section - enter: "property Foo: System.Int64 read FFoo;" - press Ctrl-Shift-C for class completion - field FFoo: System.Int64 is created - press Ctrl-Shift-C for class completion again exp: nothing happens act: another field FFoo: System.Int64 is created

QC# Project Area
Delphi.Net IDE\Code Dom
Description: Steps:
Create ASP's event got

procedure Button1_Click(sender: TObject; e: System.EventArgs);

when it should be

procedure Button1_Click(sender: System.Object; e: System.EventArgs);
1. File | New | ASP Application
2. drop an asp:button
3. double click Button to Onclick
// procedure Button1_Click(sender: TObject; e: System.EventArgs);

// notice "TObject" should be "System.Object"

QC# Project Area
Delphi.Net IDE\HTML\ASP\Providers
Description: Steps:
ASP.NET application with Interbase, IIS.

Connecting to the interbase fails with the following error.


Could not load file or assembly 'Borland.Data.DbxDynalinkDriver, Version=11.0.5000.0, Culture=neutral, PublicKeyToken=a91a7c5705831a4f' or one of its dependencies. The system cannot find the file specified.

I wonder how the .Net picked up the publickeytoken when it's not specified in the connectionstring because the publicKeyToken specified in the error message is different from what I have in my gac.

******* See RESOLUTION history
1) Install Product and Interbase client on a clean VM
2) Run and do a new ASP.NET web application using Cassini
3) Modify the IBCONNECTION in DataExplorer to point a valid IB 2007 database connection containing the ASP.NET provider schema. I was using "medington4:d:\databases\interbase\aspnet.gdb" which is all setup and accessible if you want to use it as well.
4) Open web.config for the application and change the connection string to be:

<add name="BlackfishSqlAspNet"
connectionString="connectionnName=IBCONNECTION"
providerName="Borland.Data.AdoDbxClient"/>
5) Drop a login control on the default web form
6) Run without debugging
7) type something into the login control username and password and click the login button

//exp: Invalid username/password error
//act: assemply load error message with a wrong publickey tokey:

Could not load file or assembly 'Borland.Data.DbxDynalinkDriver, Version=11.0.5000.0, Culture=neutral, PublicKeyToken=a91a7c5705831a4f' or one of its dependencies. The system cannot find the file specified.

QC# Project Area
Delphi.Net Database\BlackFishSQL
Description: Steps:
BlackfishSQL
All the exception classes should be deserializeable.

i.e. they must implement:
a constructor and a GetObjectData
since the base class implements ISerializeable

TODO:
Add testcase which causes an exception, saves it to file and restored the exception object.

    51423

QC# Project Area
51423 Delphi.Net Compiler\Language\Parameterized Types
Description: Steps:
[QC Short Description]
Methods with different constraints will not always compile

[QC Description]
Depending on which constraints are placed on methods of a class, the code of one of the methods will or will not compile.

This won't compile:

type
Tester = class
function AreEqual<T: IEquatable<T>>(List: IList<T>;
Index1, Index2: Integer): Boolean;
function Compare<Z: IComparable<Z>>(List: IList<Z>;
Index1, Index2: Integer): Integer;
end;

function Tester.AreEqual<T>(List: IList<T>;
Index1, Index2: Integer): Boolean;
begin
Result := List[Index1].Equals(List[Index2]);
end;

function Tester.Compare<Z>(List: IList<Z>;
Index1, Index2: Integer): Integer;
begin
Result := List[Index1].CompareTo(List[Index2]);
end;

I get the error "undeclared identifier: 'CompareTo'". But the next code will compile, and 'CompareTo' is not undeclared anymore:

type
Tester = class
function AreEqual<T: IComparable<T>>(List: IList<T>;
Index1, Index2: Integer): Boolean;
function Compare<Z: IComparable<Z>>(List: IList<Z>;
Index1, Index2: Integer): Integer;
end;

function Tester.AreEqual<T>(List: IList<T>;
Index1, Index2: Integer): Boolean;
begin
Result := List[Index1].CompareTo(List[Index2]) = 0;
end;

function Tester.Compare<Z>(List: IList<Z>;
Index1, Index2: Integer): Integer;
begin
Result := List[Index1].CompareTo(List[Index2]);
end;

Note that the following will also compile, so is it perhaps that I am doing something wrong?

type
Tester2 = class
function AreEqual<T: IEquatable<T>>(Item1, Item2: T): Boolean;
function Compare<Z: IComparable<Z>>(Item1, Item2: Z): Integer;
end;

function Tester2.AreEqual<T>(Item1, Item2: T): Boolean;
begin
Result := Item1.Equals(Item2);
end;

function Tester2.Compare<Z>(Item1, Item2: Z): Integer;
begin
Result := Item1.CompareTo(Item2);
end;

Hmmm... This also compiles, even with different constraints:

function Tester.Compare<Z>(List: IList<Z>;
Index1, Index2: Integer): Integer;
var
Element: Z;
begin
Element := List[Index1];
Result := Element.CompareTo(List[Index2]);
end;

So how come the compiler can't recognize List[Index1] as implementing IComparable, but it can recognize Element doing that? Actually, even the cast IComparable(List[Index1]) was rejected. Note, if both methods have the same constraint, this seems to be unimportant.
QC Entry 51423
* Start a new Delphi for .NET console app * Change the code of the app to: program Project13; {$APPTYPE CONSOLE} uses SysUtils, System.Collections.Generic; { $DEFINE SAMECONSTRAINT} type Tester = class {$IFDEF SAMECONSTRAINT} function AreEqual<T: IComparable<T>>(List: IList<T>; Index1, Index2: Integer): Boolean; {$ELSE} function AreEqual<T: IEquatable<T>>(List: IList<T>; Index1, Index2: Integer): Boolean; {$ENDIF} function Compare<Z: IComparable<Z>>(List: IList<Z>; Index1, Index2: Integer): Integer; end; Tester2 = class function AreEqual<T: IEquatable<T>>(Item1, Item2: T): Boolean; function Compare<Z: IComparable<Z>>(Item1, Item2: Z): Integer; end; function Tester.AreEqual<T>(List: IList<T>; Index1, Index2: Integer): Boolean; begin {$IFDEF SAMECONSTRAINT} Result := List[Index1].CompareTo(List[Index2]) = 0; {$ELSE} Result := List[Index1].Equals(List[Index2]); {$ENDIF} end; function Tester.Compare<Z>(List: IList<Z>; Index1, Index2: Integer): Integer; begin Result := List[Index1].CompareTo(List[Index2]); // error!! end; function Tester2.AreEqual<T>(Item1, Item2: T): Boolean; begin Result := Item1.Equals(Item2); end; function Tester2.Compare<Z>(Item1, Item2: Z): Integer; begin Result := Item1.CompareTo(Item2); end; begin try { TODO -oUser -cConsole Main : Insert code here } except on E:Exception do Writeln(E.Classname, ': ', E.Message); end; end. * Build exp: compiles act: [DCC Error] Project13.dpr(37): E2003 Undeclared identifier: 'CompareTo' * remove the space before the $ in the $DEFINE line * Build exp: same error act: compiles * Also note: no error in class Tester2. * remove $DEFINE * Change the code of Tester.Compare<Z> to: function Tester.Compare<Z>(List: IList<Z>; Index1, Index2: Integer): Integer; var Item: Z; begin Item := List[Index1]; Result := Item.CompareTo(List[Index2]); end; * Build exp: error again act: compiles

QC# Project Area
Delphi.Net IDE\Code Editor
Description: Steps:
Code completion moves cursor to position before left ( of methods so that the user has to manually move behind it. 1. new vcl forms app
2. add System.IO to any uses
3. double click form
4. type System.IO.Directory.<wait>
5. select getParent
6. press enter

exp: cursor right of (
act: left of (

QC# Project Area
Delphi.Net Install
Description: Steps:
When installing Architect Trial the Wise Owl Demeanor checkbox is ON and disabled (making it appear that Wise Owl will and must be installed) Install the latest build using a trial key
//act:
Wise Owl Demeanor checkbox is ON and disabled
//exp:
Wise Owl Demeanor checkbox is OFF and disabled

QC#