Log On
Embarcadero Home
Watch, Follow, &
Connect with Us
Share This
QualityCentral
Communities
Articles
Blogs
Resources
Downloads
Help
QualityCentral
Kylix
VCLX
Align
Anchors
Constraints
Drag & Drop
MDI
MenuDesigner
QT
Styles
TActionList
TAnimate
TApplication
TBevel
TBitBtn
TBitmap
TBrush
TButton
TCanvas
TCheckBox
TCheckListbox
TClipBoard
TColorDialog
TComboBox
TControl
TControlBar
TCustomControl
TDirectory
TDirectoryTreeView
TDrawGrid
TDrawing
TEdit
TFileEdit
TFileHistoryComboBox
TFileIconView
TFileListView
TFilterComboBox
TFindDialog
TFont
TFontDialog
TForm
TFrame
TGraphic
TGroupBox
THeaderControl
Themes
THint
TIcon
TIconView
TImage
TImageList
TLabel
TLCDNumber
TListBox
TListView
TMainMenu
TMaskEdit
TMemo
TMenuItem
TMouse
TOpenDialog
TPageControl
TPaintBox
TPalette
TPanel
TPen
TPicture
TPopupMenu
TPrinter
TPrinterDialog
TProgressBar
TRadioButton
TRadioGroup
TReplaceDialog
TRichEdit
TSaveDialog
TScreen
TScrollbar
TScrollBox
TShape
TSpeedButton
TSpinEdit
TSplitter
TStatusBar
TStringGrid
TTabControl
TTextBrowser
TTextViewer
TTimer
TToolbar
TTrackBar
TTreeView
TWidgetControl
You are not logged in.
Help
Print
Public Report
Report From:
Kylix/VCLX/TTreeView
[ Add a report in this area ]
Report #:
11629
Status:
Withdrawn
Item Index Wrong Assignment
Project:
Kylix
Build #:
3.0
Version:
3.0
Submitted By:
Francisco Silva
Report Type:
Issue
Date Reported:
3/26/2005 9:01:50 AM
Severity:
Serious / Highly visible problem
Last Updated:
3/26/2005 9:10:45 AM
Platform:
Kylix Pascal IDE
Internal Tracking #:
Resolution:
None
Resolved in Build:
:
None
Duplicate of:
None
Voting and Rating
Overall Rating:
No Ratings Yet
0.00 out of 5
Total Votes:
None
Description
When I have a TreeView with some Items in it, if I try to Insert a new item the new Item gets the next available Index and NOT the NEXT Index of where I inserted. But if I call the AbsoluteIndex function I DO get the right Index. But the issue here is that the Absolute Index of an Item is NOT the same as the TRUE Index of the Item in the TreeView.
For example:
- one (Absolute index = 0)
- two (Absolute index = 1)
- three (Absolute index = 2)
- four (Absolute index = 3)
now lets say that I want to Insert a new Item between "two and three"
- one (Absolute index = 0) real Index =0
- two (Absolute index = 1) real Index =1
- NewItem (Absolute index = 2) real Index =4
- three (Absolute index = 3) real Index =2
- four (Absolute index = 4) real Index =3
If I want to Access directly the "NewItem" I should type:
Caption := TreeVew1.Items[2].Text;
this should show the text of the newItem in the Form Title, but it dosn't, It will show the Text of the Item "three";
Steps to Reproduce:
Download the source code
Workarounds
None
Attachment
None
Comments
None
View Your Reports
Search
Server Response from: ETNACODE01
Developer Tools
Blackfish SQL
C++Builder
Delphi
FireMonkey
Prism
InterBase
JBuilder
J Optimizer
HTML5 Builder
3rdRail & TurboRuby
Database Tools
Change Manager
DBArtisan
DB Optimizer
ER/Studio
Performance Center
Rapid SQL
Technical Articles
Tutorials
White Papers
Press Releases
Newsletters
Add Content (GetPublished)
Audio
Audio & Video
Video
Bugs & Suggestions (QualityCentral)
Discussion Forums
Examples (CodeCentral)
Tags
Technology Partners
Downloads
Free Trials
Registered User Downloads
Beta Programs
Add Content (GetPublished)
Articles
Blogs
Bugs & Suggestions (QualityCentral)
Discussion Forums
Examples (CodeCentral)
Member Services
About
Connect with Us