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 7005819
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 27, 20262026-05-27T21:23:58+00:00 2026-05-27T21:23:58+00:00

Here is the application on codeplex all i did is created a new text

  • 0

Here is the application on codeplex all i did is created a new text box and trying to get path of current node selected into this text box, but i am getting extra things which i dont need at all,

Link to application,

Codeplex app

Code Line i am using is ,

TextBox1.Text = nodeCurrent.FullPath;

and output i am getting is something like this,

My Computer\C:\\Documents and Settings\Administrator\Desktop

My Computer here is Root Node, which i dont need, all i want is

C:\Documents and Settings\Administrator\Desktop

Picture added

enter image description here

Here is the function i am using it

private void tvFolders_AfterSelect(object sender, System.Windows.Forms.TreeViewEventArgs e)
    {
        //Populate folders and files when a folder is selected
        this.Cursor = Cursors.WaitCursor;

        //get current selected drive or folder
        TreeNode nodeCurrent = e.Node;
        string newPath = getFullPath(nodeCurrent.FullPath);
        tbDirectory.Text = newPath;


        //clear all sub-folders
        nodeCurrent.Nodes.Clear();

        if (nodeCurrent.SelectedImageIndex == 0)
        {
            //Selected My Computer - repopulate drive list
            PopulateDriveList();
        }
        else
        {
            //populate sub-folders and folder files
            PopulateDirectory(nodeCurrent, nodeCurrent.Nodes);
        }
        this.Cursor = Cursors.Default;
    }
  • 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. Editorial Team
    Editorial Team
    2026-05-27T21:23:58+00:00Added an answer on May 27, 2026 at 9:23 pm

    add the following line in the code and it will remove recurring “\” in the path

    newPath = newPath.Replace("\\\\", "\\");
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Get all alarms saved in the alarm application here I have read there is
i have downloaded sample mvc application from here http://ravenmvc.codeplex.com/releases/view/45994 It works just fine. But
I'm trying to create a basic application, i created facebook application before but everything
I was created one small business application..Here I got the data from server and
I am trying to do something similar to the Clipper application here http://www.polyvore.com/cgi/clipper I
I have windows forms application wich runs another console application here is the part
From My Previous question sending request to apple - from iphone custom application Here,
I'm currently using the validation code listed here in an application. I'd like to
Here's the scenario: A C# Windows Application project stored in SVN is used to
Here is a simplified version of my application showing what I'm doing. /* in

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.