CnPack Forum


 
Subject: Refactoring bug, CNPack v. Ver: 0.9.9.625_Unstable Build 2011.12.24
forum1
普通灌水员
Rank: 2



UID 64926
Digest Posts 0
Credits 93
Posts 30
点点分 93
Reading Access 10
Registered 2011-5-13
Status Offline
Post at 2012-2-26 03:57  Profile | Blog | P.M. 
Refactoring bug, CNPack v. Ver: 0.9.9.625_Unstable Build 2011.12.24

Make unit1 with new class name TObject.
Make public variable MyPublicStringVar : WideString; into class TObject.


Make one Form -> for example Form1.
Write this code in onButtonClick()

With TObject.Create do begin















   MyPublicStringVar := '0000';   















end;

Now place mouse cursor to variable "MyPublicStringVar " and press key "Ctrl+Shift+E"

Appear error on XE2, update 3

"Object reference not set to an instance of an object"

Detail error

[20155124]{refactoride160.bpl} RefactorCmds.UpdateRefactoringAction (Line 268, "RefactorCmds.pas" + 9) + $9
[500432F4]{rtl160.bpl  } System.@CheckAutoResult (Line 30183, "System.pas" + 4) + $6
[20155124]{refactoride160.bpl} RefactorCmds.UpdateRefactoringAction (Line 268, "RefactorCmds.pas" + 9) + $9
[5003C885]{rtl160.bpl  } System.@AsClass (Line 13357, "System.pas" + 2) + $8
[20156834]{refactoride160.bpl} RefactorCmds.TDelphiRefactorMenuItem.Update (Line 664, "RefactorCmds.pas" + 2) + $12
[500B5357]{rtl160.bpl  } System.Classes.TBasicAction.SetOnExecute (Line 13391, "System.Classes.pas" + 0) + $7
[5031B758]{vcl160.bpl  } Vcl.ActnList.TContainedAction.Update (Line 463, "Vcl.ActnList.pas" + 8) + $28
[500B5245]{rtl160.bpl  } System.Classes.TBasicAction.Create (Line 13331, "System.Classes.pas" + 0) + $D
[50437393]{vcl160.bpl  } Vcl.Menus.TMenuItem.InitiateAction (Line 2459, "Vcl.Menus.pas" + 0) + $B
[50437765]{vcl160.bpl  } Vcl.Menus.TMenuItem.InitiateActions (Line 2615, "Vcl.Menus.pas" + 2) + $B
[50439072]{vcl160.bpl  } Vcl.Menus.DoClick (Line 3689, "Vcl.Menus.pas" + 40) + $E
[50438FB5]{vcl160.bpl  } Vcl.Menus.DoClick (Line 3653, "Vcl.Menus.pas" + 4) + $A
[50439167]{vcl160.bpl  } Vcl.Menus.TMenu.IsShortCut (Line 3743, "Vcl.Menus.pas" + 38) + $6
[50339620]{vcl160.bpl  } Vcl.Controls.TWinControl.IsMenuKey (Line 11609, "Vcl.Controls.pas" + 8) + $12
[50339695]{vcl160.bpl  } Vcl.Controls.TWinControl.CNKeyDown (Line 11629, "Vcl.Controls.pas" + 5) + $4
[2076E36D]{coreide160.bpl} EditorControl.TCustomEditControl.CNKeyDown (Line 2049, "EditorControl.pas" + 16) + $5
[5033280D]{vcl160.bpl  } Vcl.Controls.TControl.WndProc (Line 7204, "Vcl.Controls.pas" + 91) + $6
[20FB0A92]{designide160.bpl} DeskUtil.SetFocusHook (Line 462, "DeskUtil.pas" + 4) + $C
[5033715B]{vcl160.bpl  } Vcl.Controls.TWinControl.WndProc (Line 9976, "Vcl.Controls.pas" + 152) + $6
[2173428F]{vclactnband160.bpl} Vcl.ActnMenus.CallWindowHook (Line 747, "Vcl.ActnMenus.pas" + 20) + $F
[503367B0]{vcl160.bpl  } Vcl.Controls.TWinControl.MainWndProc (Line 9689, "Vcl.Controls.pas" + 3) + $6
[500B6030]{rtl160.bpl  } System.Classes.MakeObjectInstance (Line 13921, "System.Classes.pas" + 0) + $0
[5045231C]{vcl160.bpl  } Vcl.Forms.TApplication.IsKeyMsg (Line 10072, "Vcl.Forms.pas" + 25) + $12
[504523B6]{vcl160.bpl  } Vcl.Forms.TApplication.IsHintMsg (Line 10093, "Vcl.Forms.pas" + 3) + $2
[504525C3]{vcl160.bpl  } Vcl.Forms.TApplication.ProcessMessage (Line 10158, "Vcl.Forms.pas" + 17) + $31
[5045262A]{vcl160.bpl  } Vcl.Forms.TApplication.HandleMessage (Line 10194, "Vcl.Forms.pas" + 1) + $4
[5045295D]{vcl160.bpl  } Vcl.Forms.TApplication.Run (Line 10331, "Vcl.Forms.pas" + 26) + $3



Sorry, I install new version and this is fixed ;)

For refactoring you must use this key => Ctrl + R + R

[ Last edited by  forum1 at 2012-2-26 04:40 ]
Top
Passion (LiuXiao)
管理员
Rank: 9Rank: 9Rank: 9


UID 359
Digest Posts 19
Credits 6750
Posts 3551
点点分 6750
Reading Access 102
Registered 2004-3-28
Status Offline
Post at 2012-2-26 09:13  Profile | Blog | P.M. 
Can't see CnWizards DLL in call stack. weird.
Top
 




All times are GMT++8, the time now is 2024-3-28 23:17

    本论坛支付平台由支付宝提供
携手打造安全诚信的交易社区 Powered by Discuz! 5.0.0  © 2001-2006 Comsenz Inc.
Processed in 0.010775 second(s), 7 queries , Gzip enabled

Clear Cookies - Contact Us - CnPack Website - Archiver - WAP