MFC & TreeView Control Question

This is a discussion on MFC & TreeView Control Question within the Windows Programming forums, part of the Platform Specific Boards category; Is it possible to rename a highlighted file in a treeview control? If so, could someone point me in the ...

  1. #1
    I am the worst best coder Quantrizi's Avatar
    Join Date
    Mar 2002
    Posts
    644

    MFC & TreeView Control Question

    Is it possible to rename a highlighted file in a treeview control?

    If so, could someone point me in the right direction?

  2. #2
    Registered User Codeplug's Avatar
    Join Date
    Mar 2003
    Posts
    4,702
    I'm assuming you mean edit... here's a start.

    gg

  3. #3
    I am the worst best coder Quantrizi's Avatar
    Join Date
    Mar 2002
    Posts
    644
    Originally posted by Codeplug
    I'm assuming you mean edit... here's a start.

    gg
    That works 90% of what I want, thanks.

    After looking at that, I have another question. Is it possible to get the string of the new file, and see if it has a certain extension, and if not, don't allow the rename?

  4. #4
    Registered User Codeplug's Avatar
    Join Date
    Mar 2003
    Posts
    4,702
    Handle the TVN_BEGINLABELEDIT Notification and send TVM_GETEDITCONTROL in the handler.
    (see remarks section in above link)

    gg

  5. #5
    I am the worst best coder Quantrizi's Avatar
    Join Date
    Mar 2002
    Posts
    644
    Originally posted by Codeplug
    Handle the TVN_BEGINLABELEDIT Notification and send TVM_GETEDITCONTROL in the handler.
    (see remarks section in above link)

    gg
    Thank you. I will try that out and see how it goes.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. (Visual C++) MFC Tree Control to do a settings page
    By guitarist809 in forum Windows Programming
    Replies: 6
    Last Post: 08-31-2008, 12:31 AM
  2. Visual C++ 2008 MFC Tab Control
    By guitarist809 in forum Windows Programming
    Replies: 2
    Last Post: 07-20-2008, 10:37 AM
  3. RickEdit control question
    By nomer in forum Windows Programming
    Replies: 6
    Last Post: 03-03-2006, 07:00 PM
  4. Question about document/view app in MFC
    By hpy_gilmore8 in forum Windows Programming
    Replies: 2
    Last Post: 05-06-2004, 08:51 PM
  5. MFC Dialog App Screen Refresh Question
    By Scotth10 in forum Windows Programming
    Replies: 2
    Last Post: 10-18-2002, 03:07 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21