JTree Root Folder renaming...

hi,
In JTree, how to rename the label of the root folder.
any help please????

Try the following:
String newName = "whatever";
root = (DefaultMutableTreeNode)treeModel.getRoot();
root.setUserObject(newName);
treeModel.reload();
Hope this helps, Claire

Similar Messages

  • Error message: local root folder does not exist

    Greetings,
    I'm working on a MacPro 2x2.66Ghz, running DW from CS2 and
    through a strange combination of keyboard keystrokes while cleaning
    my keyboard yesterday I inadvertantly renamed my hard drive "-OX"
    from it's default. I can't seem to remember what the default name
    of my hard drive was, but i think it was simply "Macintosh". I've
    renamed it that, but on launching DW for the first time today I got
    an error message saying that "The local root folder, web_content,
    does not exist" and it gave me the option to manage sites and set
    my local root folder again. Is there a way to re-establish my local
    root folder for every site that I currently manage in one swipe, or
    do I have to go in and manually do this for each and every Site
    within my Files panel?
    Thanks for your ideas,
    Pedro

    Actually, it solved one issue but seems to have created
    another! So, at least now my Sites are all working okay with
    respect to a local root folder. But let's say I open an .html file
    by double-clicking it in the Files panel. With that file active if
    I choose Preview in Browser I get a "File Not Found" error message
    from Firefox.... even though it looks like the path to that file is
    correct.
    One thing I notice about the path in the address bar of
    Firefox is that there are 3 forward-slashes after the file: bit at
    the beginning of the line.
    For example, the page generating the error has this address:
    file:///Macintosh%20HD/Users/peter/Sites/MySite/web_content/index_vertical.html
    If you notice carefully there are 3 slashes at the beginning
    of the line. If I go to "Manage Sites" I have the settings set to
    "links relative to document" and my root folder and images folder
    show the proper locations. What have I done?
    The error message also says the following in the details
    section: Firefox can't find the file at /Macintosh
    HD/Users/peter/Sites/MySite/web_content/index_vertical.html.
    so there's a forward-slash before the hard drive.... is that
    okay?
    Thanks for your ideas!
    Pedro

  • How do you get the root folder to recognize updated file in nested folder?

    I believe in OS 9, a modified file nested in a folder would trigger the root folder to recognize and update to the top of the "date modified" column. As long as I've used the Mac (20 years) I've used the "date modified" to force my current client folders to the top of the column. Lately, I have many nested folders in the root client folder. When I make changes to a file in a nested folder, OS X doesn't make the root folder recognize changes within a nested folder. I realize there is not likely to be a fix for this in OS X, as Apple probably deems this behavior to be proper (I do not,) so my question would be expanded to include suggestions for third party software that may accomplish this.

    Sorry, posted that last post and ran out of time while editing it. It should read like this:
    "Yes, if you ADD a new item or folder to a folder, it updates the root folder, but if you simply MODIFY a file (like Photoshop) within a subfolder, the root folder WILL NOT update the date modified. Check it out."
    Actually, whether the directory that a file is re-saved in will be modified or not can depend on the application in question and how it saves files.
    Let's say a folder has a single file in it. The modification date of the folder will be the last time a change was made to the directory, either by adding or removing an item from it. (This can include the invisible .DS_Store file in which the Finder saves view settings for a folder, which can often be written without you're realizing it unless you have the Finder show all files like I do).
    Then, let's say you open that file, which is a stream of bytes, in an application. You make some changes which alters the representation of the stream of bytes in RAM. The application then saves the changes to the file by filling it with the stream bytes as they now are in RAM. Modifying the contents of a file in this manner does not alter the directory that it's in. The modified date of the folder should remain unchanged.
    Some applications use a different method than above to save files, however. Let's say that theoretically while the application is re-writing to the original file during a save, the power goes out and your computer shuts down. There's a good chance that the document that was being saved is now corrupt. A safer method that some applications use, is to first write out the information to a new file in the same directory as the original file, then delete the original file, and then rename the new file so that it has the same attributes as the old file. This method will, of course, modify the directory that the original file was in by adding and removing a file.
    Dual 2.7GHz PowerPC G5 w/ 2.5 GB RAM; 17" MacBook Pro w/ 2 GB RAM -   Mac OS X (10.4.8)  

  • Dreamweaver 6. I can't reference root folder on test server - any ideas please?

    Dreamweaver 6. I've set up a copy of a site onto a test server. All fine other than a problem with links to the root folder.
    The web URL for test server is set up as http://localhost:8080/bhtownsite/ but when I set up a link to the site root e.g. /photos/pictures.php, instead of going to http://localhost:8080/bhtownsite/ the system ignores the 'bhtownsite' folder and goes to http://localhost/photos/pictures.php which of course doesn't exist!!
    I've no hair left to pull - any suggestion would be greatly appreciated.
    Thanks

    @Murray,
    I don't have a Root Directory field in my Testing Server definition (CS6 12.2). 
    Server name:  Testing Server
    Connect using: Local/Network
    Server folder:  C:\wamp\www\MySiteName\
    Web URL:  http://localhost/MySiteName/
    Is that something new in CC?
    Nancy O.

  • Saving message to root folder

    I want to save a message to the root folder.
    In remote mode the root folder name returned by get_RootFolder method of the
    IGWAccount object corresponds to the 'From name' of the default GW account
    instead of the displayed name. Moreover, the ItemSaveMessageDraft token
    fails if this root folder name is used and the display name of the root
    folder is different from the 'From name'.
    Does anybody know any other method to save a message to the root folder in a
    TPH?
    Saurabh

    I have some basic troubleshooting steps here http://thunderbirdtweaks.blogspot.com.au/2014/02/basic-troubleshooting-for-thunderbird.html
    Please report back your results.

  • Getting error when placing jsp file in tomcat root folder

    hello experts,
    i have developed an application on netbeans 6.1 for mail.
    It is working perfect when i run it from netbeans, but when we copy those jsp files to ROOT folder of tomcat5.5 server, it is showing me following error.
    rg.apache.jasper.JasperException: Unable to compile class for JSP:
    An error occurred at line: 14 in the jsp file: /Mailer1.jsp
    Session cannot be resolved to a type
    11: <%!
    12: String nam = null, email = null, suggestion = null;
    13: RequestDispatcher disp = null;
    14: public static Session sess = null;
    15:
    16: %>
    17: <%
    An error occurred at line: 38 in the jsp file: /Mailer1.jsp
    sess cannot be resolved
    35:
    36: //SecurityManager security = System.getSecurityManager();
    37:
    38: sess= Session.getInstance(props,new javax.mail.Authenticator() //if u uses getDefaultInstance it will raise Security Exception
    39: {
    40: protected PasswordAuthentication getPasswordAuthentication()
    41: {
    An error occurred at line: 38 in the jsp file: /Mailer1.jsp
    Session cannot be resolved
    35:
    36: //SecurityManager security = System.getSecurityManager();
    37:
    38: sess= Session.getInstance(props,new javax.mail.Authenticator() //if u uses getDefaultInstance it will raise Security Exception
    39: {
    40: protected PasswordAuthentication getPasswordAuthentication()
    41: {
    An error occurred at line: 38 in the jsp file: /Mailer1.jsp
    javax.mail.Authenticator cannot be resolved to a type
    35:
    36: //SecurityManager security = System.getSecurityManager();
    37:
    38: sess= Session.getInstance(props,new javax.mail.Authenticator() //if u uses getDefaultInstance it will raise Security Exception
    39: {
    40: protected PasswordAuthentication getPasswordAuthentication()
    41: {
    An error occurred at line: 45 in the jsp file: /Mailer1.jsp
    sess cannot be resolved
    42: return new PasswordAuthentication("[email protected]","ratatouille");
    43: }
    44: });
    45: sess.setDebug(true);
    46:
    47:
    48: //sess = Session.getDefaultInstance(props);
    An error occurred at line: 50 in the jsp file: /Mailer1.jsp
    Transport cannot be resolved to a type
    47:
    48: //sess = Session.getDefaultInstance(props);
    49: //sess.setDebug(true);
    50: Transport trans = sess.getTransport();
    51: Message msg = new MimeMessage(sess);
    52: msg.setRecipient(Message.RecipientType.TO, new InternetAddress("[email protected]"));
    53: msg.setFrom(new InternetAddress(this.email));
    An error occurred at line: 50 in the jsp file: /Mailer1.jsp
    sess cannot be resolved
    47:
    48: //sess = Session.getDefaultInstance(props);
    49: //sess.setDebug(true);
    50: Transport trans = sess.getTransport();
    51: Message msg = new MimeMessage(sess);
    52: msg.setRecipient(Message.RecipientType.TO, new InternetAddress("[email protected]"));
    53: msg.setFrom(new InternetAddress(this.email));
    An error occurred at line: 51 in the jsp file: /Mailer1.jsp
    Message cannot be resolved to a type
    48: //sess = Session.getDefaultInstance(props);
    49: //sess.setDebug(true);
    50: Transport trans = sess.getTransport();
    51: Message msg = new MimeMessage(sess);
    52: msg.setRecipient(Message.RecipientType.TO, new InternetAddress("[email protected]"));
    53: msg.setFrom(new InternetAddress(this.email));
    54: msg.setSubject(this.nam);
    An error occurred at line: 51 in the jsp file: /Mailer1.jsp
    MimeMessage cannot be resolved to a type
    48: //sess = Session.getDefaultInstance(props);
    49: //sess.setDebug(true);
    50: Transport trans = sess.getTransport();
    51: Message msg = new MimeMessage(sess);
    52: msg.setRecipient(Message.RecipientType.TO, new InternetAddress("[email protected]"));
    53: msg.setFrom(new InternetAddress(this.email));
    54: msg.setSubject(this.nam);
    An error occurred at line: 51 in the jsp file: /Mailer1.jsp
    sess cannot be resolved
    48: //sess = Session.getDefaultInstance(props);
    49: //sess.setDebug(true);
    50: Transport trans = sess.getTransport();
    51: Message msg = new MimeMessage(sess);
    52: msg.setRecipient(Message.RecipientType.TO, new InternetAddress("[email protected]"));
    53: msg.setFrom(new InternetAddress(this.email));
    54: msg.setSubject(this.nam);
    An error occurred at line: 52 in the jsp file: /Mailer1.jsp
    Message.RecipientType.TO cannot be resolved to a type
    49: //sess.setDebug(true);
    50: Transport trans = sess.getTransport();
    51: Message msg = new MimeMessage(sess);
    52: msg.setRecipient(Message.RecipientType.TO, new InternetAddress("[email protected]"));
    53: msg.setFrom(new InternetAddress(this.email));
    54: msg.setSubject(this.nam);
    55: msg.setContent(suggestion, "text/plain");
    An error occurred at line: 52 in the jsp file: /Mailer1.jsp
    InternetAddress cannot be resolved to a type
    49: //sess.setDebug(true);
    50: Transport trans = sess.getTransport();
    51: Message msg = new MimeMessage(sess);
    52: msg.setRecipient(Message.RecipientType.TO, new InternetAddress("[email protected]"));
    53: msg.setFrom(new InternetAddress(this.email));
    54: msg.setSubject(this.nam);
    55: msg.setContent(suggestion, "text/plain");
    An error occurred at line: 53 in the jsp file: /Mailer1.jsp
    InternetAddress cannot be resolved to a type
    50: Transport trans = sess.getTransport();
    51: Message msg = new MimeMessage(sess);
    52: msg.setRecipient(Message.RecipientType.TO, new InternetAddress("[email protected]"));
    53: msg.setFrom(new InternetAddress(this.email));
    54: msg.setSubject(this.nam);
    55: msg.setContent(suggestion, "text/plain");
    56: trans.connect();
    Stacktrace:
         org.apache.jasper.compiler.DefaultErrorHandler.javacError(DefaultErrorHandler.java:93)
         org.apache.jasper.compiler.ErrorDispatcher.javacError(ErrorDispatcher.java:330)
         org.apache.jasper.compiler.JDTCompiler.generateClass(JDTCompiler.java:435)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:298)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:277)
         org.apache.jasper.compiler.Compiler.compile(Compiler.java:265)
         org.apache.jasper.JspCompilationContext.compile(JspCompilationContext.java:564)
         org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:302)
         org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:329)
         org.apache.jasper.servlet.JspServlet.service(JspServlet.java:265)
         javax.servlet.http.HttpServlet.service(HttpServlet.java:729)
    i m unable to find out the solution,
    please help me to resolve it.
    thnaks.

    Hi shams.hq,
    I don't understand how you bother to copy an application in your server directories. It's really piece of cake to deploy with Tomcat.
    All you have to do :
    - with Netbeans, you build the project : a WAR file will be created in the dist directory of your project;
    - launch the server, if it's not running;
    - with your web browser, connect to the Tomcat Manager;
    - from there, you may upload and deploy the WAR file of your project.
    Et voilà ! Tomcat will unzip the WAR and install your classes and libraries at the right place.

  • Error:  The local root folder, ZZZZZZ, does not exist.  Please...

    Dreamweaver newest - Cloud
    Windows 7 Prof 64b SP1
    Everyday now upon firing up Dreamweaver I am getting the same error. As long as I worked on this certain site last the day before, dreamweaver of course tries to load that site upon the next startup.
    The error:  The local root folder, ZZZZZZ, does not exist.  Please choose a new local root folder
    I have typed the path myself and browsed to it many times.  When I go into the Site manager/edit site to correct this, it already has the correct path listed there.  If I just leave what is there and hit save, it doesn't work.  Once re entering is done it allows me to work on the site again. Connecting to remote/upload files and everything works fine.  I can close DW and reopen and all will be fine, for a while.    If I close it and maybe two hours later come back to work on it, DW will report that same error again on startup.
    Other editors of the site with same cloud version of DW and same site settings are not having this error. We've combed for differences.
    I've deleted the site definition altogether and recreated it.  It does not stop the error.
    I found some old references to this issue in the old macromedia forums dealing with Mac and spaces or odd characters being an issue in the local folder path. I'm on windows, but the complaints sounded so similar I decided to try a test suggested there.  Their suggestion was to create a new blank html file, without saving, add some text, select the text, use the link icon in the properties manager to drag a link out to any file in the files panel.  Upon doing so, DW creates a full local path that you can see in your html since you haven't saved the file yet.  The suggestors of this test said you should see if your "mac" and DW was having trouble with spaces or odd characters in the path.   Well the following path shows a PIPE character being created in the path by DW on my test page. 
    file:///W|/private/09 Websites/zzzzzz/index.html
    Could this be showing there is some kind of issue that I need to correct?  Or is this typical?  See the pipe character being listed after the network drive letter of W
    Our local root folder path:
    W:\private\09 Websites\zzzzzz\
    Server Settings:
         Root Directory:
    public_html/zzzzzz.com/
         Web URL:
    HypertextTransferProtocolCOLON//worldwideweb.zzzzzz.commercial/
    Any help or suggestions would be appreciated.

    Sudarshan Thiagarajan wrote:
    remote
    /home/zzzzz/public_html/zzzzz.com
    Is this how your remote setting is defined? If it is, do you have a folder called zzzzz.com on your remote server trailing public_html? Ideally public_html is your website root - index.html resides within that, unless your configuration states otherwise.
    To come to your actual question of the local root folder, yes, your file manager wont show files if the connection fails. However, accessing it depends on the permissions you have on your network drive. Have you checked that?
    I'm not sure why our guy has another folder underneath public_html. My guess is he has some company related hosted test folders for various things under there.  I can see a couple other folders under public_html while checking with filezilla. I suppose he just directed our domain to our web folder under public_html. 
    Again, two others here are using these exact same settings with no root folder errors from DW. We've checked many times and all is the same for them.
      Here are some screen grabs of the settings if this makes it more clear.
    This last one showing the remote connection address under the files/assets panel is the one that looks strange to me.  It shows a home folder / then a folder with our site name / then public_html / then our sitename.com .    Seems convoluted to me.  But it works for everyone else so I'm not sure if this error I'm getting has anything to do with these settings or if there is just some old DW settings file hung up in my system that I need to find and delete or what.
    Thanks for any ideas.

  • Unable to open templates from server input form folder and server root folder from some system while the same can be open from others system

    Hi,
    I am unable to open input scheduled from server root folder and also from input form folder on some system while they can be open from others system.
    Please advice.
    Thanks in advance

    Hi Hengye,
    While opening , it dont give any error. When I try to open it , it takes some time to load then nothing happen.However I can open it on other system but not on mine my collegue and user system.
    Please advice.
    Thanks.

  • My DWCS6 doesn't want to choose a root folder

    I follow the directions on the tutorial video, and click on New Site. I get a two-line dialog box that matches the one in the tutorial, and in the upper field I insert the name I want the new site to have. Then in the lower field--the path to my preferred root folder--I click on the browse icon which opens another dialog box with a folder tree. I find the folder I want to use, and click once on it. But wait. . .in the tutorial video there is a button marked "choose" on this dialog box. The dialog box on my screen looks markedly different, and the live button says "open" rather than "choose." And when I click on "open" or double click on the folder I want, it simply opens that folder, revealing an empty space and an error message saying "no items match your search." DW simply refuses to make that folder be the root folder for the new site. Why not? And how do I make it do so?
    I am using DW CS6 on a Dell desktop running Win 7 64-bit Home Premium.
    DK

    There are subtle differences between the various versions of CS6 and CC.  See screenshots below from CS6 12.2
    Servers:
    More Options:
    Nancy O.

  • Question re. Column View/List View in Home Folder and Root Folder?

    <Edited by Host>
    When I set either my Home folder in the Dock or the Root Folder on the Desktop to open in Column View, everything opened is retracted upon closing.
    Is this just the way Leopard is, or am I missing something obvious I should know:
    First, on Tiger, my Home Folder opens directly in the Finder. I don't have to select "Open in Finder," as I have to in Leopard.
    Second, when I select the Column option when opening the Home Folder in the Finder, it automatically sets the Column option for the Root Folder on the Desktop, as well (and vice-versa). In Tiger, they can be set independently. I prefer to have the Root Folder set to List View and the Home Folder to Column View, and have both remain like that. This is what I meant, but got a bit confused before in asking the question.
    Also, is there some way, as in Tiger, to have the Home Folder in the Dock set to open automatically in the Finder, without having to select that option each time I go to the Home Folder?
    Actually, now that I remember, perhaps this isn't such surprising behavior. To get it there, I copied the Home Folder from its position in the Root Folder to the Dock. Maybe there is some other way to get the Home Folder into the Dock? Thanks.

    WZZZ wrote:
    Thanks. The option "Open in Finder" appears at the bottom of a small vertical menu when I click on the Home Folder in the Dock. Command clicking on the Home Folder brings up the other user account, Shared, and my user account, so it's not that useful.
    ah, you are right. well, one more option is to make an alias to the home folder, put it anywhere you want and put the alias on the dock. then clicking (no command-clicking needed) on the alias in the dock will open home in a finder window directly.
    The default in Finder Preferences was already set the way you suggested.
    Now that I know about cmd-n, that gets me directly to the Home Folder in the Finder. And now that it's set up to open in Column View, and remain that way independent of the View option for the Root folder, everything seems to be looking good. That's what I needed.

  • Moving a folder from one local root folder to another

    I've used Dreamweaver CS4 to build my website, and I've become basically familiar with the way it works. Now I'm just starting to build a second site - and I've run into a baffling problem.
    I've defined the new site in the normal way, and created the local root folder.
    I've got a folder full of image files that is currently sitting in the local root folder of my old site - I'd like to put this into the local root folder of my new site.
    This may seem silly, but I can't find a way to move that images folder from one local root folder to the other. I thought it would be a simple drag & drop move, but there doesn't seem to be a way to do this. I've moved the images folder to the desktop, from where it should be easy to drag it over the new local root folder icon in Dreamweaver and drop it in - but it doesn't work.
    Am I missing something obvious here...?

    You should be able to access your entire computer directory structure through the Files Panel in Dreamweaver.
    Click the drop down arrow next to the named site (the open site) at the top of the Files Panel and navigate up into the rest of your computer. You can then Ctrl-C (copy) the folder, re-select the name of your site (the green folders at the bottom of the directories, not in the computer structure), and Ctrl-V (paste) the folder where you want it. Contents will of course come with it.
    You could (alternately) just copy and paste it working within the computer's directory structure. Paste it into the new root folder and, in Dreamweaver, refresh the view in the Files Panel. The folder should show up fine.
    Notice that I have not been drag and dropping, though that should work with the last-mentioned technique.
    Beth

  • Publish the website to the root folder (without creating a new folder)

    Hi there! Sure this problem has already been discussed here many times and I'm not the only one who's interested this question, but how can I publish my website using FTP without creating a new folder, just to the root folder of my web hosting? Is that even possible or should I each time drag all the files from the folder created by iWeb and put them to the root folder manually? I'm a little bit confused. Guys help me with this, please! Many thanks in advance!!

    Yes, you're right, it has been discussed for the past several years and yes, you're not the only who's interested in that question.
    A simple googe search confirms it : avoid iweb sitename
    Try it, if you haven't done it already.
    Here's my answer :
    http://www.wyodor.net/htmlegg/TallCard/TallAjax.html?pg=avoidSitename

  • Unable to create a folder in lower levels of root folder

    It appears to me I cannot create a new folder in the lower levels of root folder. Currently, I have to create a new folder right below root folder and then drag it to lower level folder. Why I can't do it in one go. Thanks!

    Hi Ray. That is normal behavior for Snow Leopard now. The OS wants to reserve the root level for itself. Also, folders you create at the root level may not accurately reflect the correct permissions.
    You want to try to keep all your files/folders in your Home (User) folder. That way all your documents remain portable when you move to another Mac or migrate your data back after an Erase & Install. If your docs are scattered all over the drive there is a chance some stuff will not get transferred during a move. So try to keep everything inside your Home folder.
    If you have to place a new folder at the root level, try creating the folder on your Desktop, then dragging it to the root level.
    And Welcome to the Macintosh!
    You might find the following links helpful:
    http://www.apple.com/support/switch101/
    http://www.apple.com/support/mac101/
    Cheers!

  • Itunes can't locate root folder on ext HD

    Having solved half of my problem, I started a new thread for this problem. I now have Itunes not able to find the root folder on my external hard drive (f:) I have located Itunes library in several different locations on my C:, everywhere from My Music, my documents\my music, on my F:,etc. The only place where I can actually locate and access the complete updated list of music is when I have the F: connected,under the following path: C:\Documents and Settings\all users\Documents\Itunes library\itunes music.
    How do I get the Itunes to find the path anytime I click on a particular song without having to re-enter each song? Katrina S. has been a great help getting me to this point, but I lose myself in the different threads from others. I know I am a few steps away... Please help

    No I  get the error message
    but the insert image works fine thanks
    this is the error message generated when I try to create a new folder
    thanks ed

  • Why can't DW CS5 see jpgs, new files in website root folder in Bridge CS3?

    Help!  Upgraded to DW CS5.  Web site done in DW CS3, used PS3 and Bridge CS3 for photo prep etc. Root folder is  in Bridge CS3.  I tried to use "Place"  to DW CS5- but Bridge opens DW CS3 instead, even with page open in DW CS5. (Have deactivated DW CS3 in associations.)   New pages,files and additions are "invisible" to DW CS5.  Why?
    Before the upgrade,files in the root folder in Bridge were listed and  immediately available to DW on Local and Remote.   (Mac OS X10.5.8-2.2GHzIntel/mem 2GB 667 MHz)
    I'm new at this stuff and have combed the Help-Knowledge Bases-DW and Bridge and haven't found anything remotely helpful or even similar? .Must be something obvious everyone knows  to do.

    Problem went away this morning!
    I tried this step again (a third time) after starting up my computer:
    Still trying to get my composite in "B" recognized by LR, I first deleted the composite from "B" using explorer, then went into LR and moved the file from "A" (where LR recognized it), into "B". 
    This time it worked, the file moved successfully and appears normally in LR.
    Don't know if the re-boot helped, or I was making some silly mistake that a good night's sleep cured.  If the later, I apologize to all who scratched their heads over this one. 
    Thanks,
    Jerry

Maybe you are looking for