Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 139279
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T07:24:23+00:00 2026-05-11T07:24:23+00:00

I need to add functionality to copy a rectangular selection of nodes and columns,

  • 0

I need to add functionality to copy a rectangular selection of nodes and columns, but I can’t find any way to actually select multiple columns in a Virtual Treeview (beside toFullRowSelect).

Am I just missing something? And if not, is there a descendant out there with grid-like multicolumn select support?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. 2026-05-11T07:24:24+00:00Added an answer on May 11, 2026 at 7:24 am

    So after some testing I came up with the following, thanks DiGi for the extra push. DrawSelection won’t work with this solution so it needs to be disabled. Since I don’t think I’ll need to do this again soon I didn’t write a descendant.

    Set toDisableDrawSelection, toExtendedFocus and toMultiSelect to True.

    Declare the following variables/properties somewhere suitable:

    StartSelectedColumn: integer; FirstSelectedColumn: integer; LastSelectedColumn: integer; Selecting: boolean; 

    Update the following events:

    OnKeyDown

    if (not Selecting) and (Key = VK_SHIFT) then begin   StartSelectedColumn := vtMain.FocusedColumn;   FirstSelectedColumn := StartSelectedColumn;   LastSelectedColumn := StartSelectedColumn;   Selecting := true; end; 

    OnKeyUp

    if Key = VK_SHIFT then   Selecting := false; 

    OnFocusChanged

    if Selecting then begin   if column < StartSelectedColumn then   begin     FirstSelectedColumn := column;     LastSelectedColumn := StartSelectedColumn;   end   else if column > StartSelectedColumn then   begin     FirstSelectedColumn := StartSelectedColumn;     LastSelectedColumn := column   end   else   begin     FirstSelectedColumn := column;     LastSelectedColumn := column;   end; end else begin   StartSelectedColumn := column;   FirstSelectedColumn := column;   LastSelectedColumn := column; end; 

    OnBeforeCellPaint

    if vtMain.Selected[node] and InRange(column, FirstSelectedColumn, LastSelectedColumn) then begin   if vtMain.Focused then     TargetCanvas.Brush.Color := vtMain.Colors.FocusedSelectionColor   else     TargetCanvas.Brush.Color := vtMain.Colors.UnfocusedSelectionColor;   TargetCanvas.Brush.Style := bsSolid;   TargetCanvas.FillRect(CellRect); end; 

    OnPaintText

    if vtMain.Selected[node] and InRange(column, FirstSelectedColumn, LastSelectedColumn) then begin   if vtMain.Focused then     TargetCanvas.Font.Color := clHighlightText   else     TargetCanvas.Font.Color := vtMain.Font.Color; end; 
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 222k
  • Answers 222k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer While <!doctype html> is perfectly fine, the WHAT-WG recommendation is… May 13, 2026 at 12:20 am
  • Editorial Team
    Editorial Team added an answer Are you doing this through a canvas application or Facebook… May 13, 2026 at 12:20 am
  • Editorial Team
    Editorial Team added an answer I found the error in your parser. In your last… May 13, 2026 at 12:20 am

Related Questions

What is the best way to create a completely new project in TFS by
I used to have a class in 1.1 for the Datagrid that inherited from
I'm looking for a better way to this. I have a chunk of code
I've some questions .. and I really need your help. I have an application.

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.