URL:s, the way to specify them ?

I have a file on my filesystem, lets say C:\file.txt.
I want to send an URL to a server so it can connect to my computer and download it via http ( in this case the file file.txt). Therefore I need to specify the host ( in my case my computer ) when creating the URL like this:
URL url = new URL ( "http://123.456.789/<what shall I write here, so the receiver knows the file is on my C-drive and is called file.txt" ?>When I try to do something like :
URL url = new URL ( "http://123.456.789/C:/file.txtI just got a FileNotFoundException ??

so it can connect to my computer and download it via httpYou need to have a http server running on your computer. And the file
needs to be hosted by this server. Then pasing C:\file.txt is not an url:
http://host/somedir/somefile.txt is a url.
As for passing a value from the client to the server you can use POST.
http://forum.java.sun.com/thread.jspa?threadID=645830
second post

Similar Messages

  • How to arrange songs on ipod shuffle the way I want them to be played

    I just got an Ipod shuffle in India.....2 GB....I want the songs to be played in a particular order only the way I can do on MP3 players....How do I arrange songs the way I want them to be played serially?

    If you have iOS 5 on the iPad then you can create new albums directly on the iPad - you should get an Edit button at the top of the Albums screen in the Photos app. That will allow you create and 'copy' photos into those new albums (you can't copy photos into synced albums), but you can't delete the original photo - if you do delete it then all copies of it that you've put in other albums will also be deleted. I don't think that the total number of photos increases on the iPad when you copy photos into new albums, so I think that you effectively just creating pointers to them in those new albums, so if you delete the original photos on the iPad then all pointers to it will also be deleted.

  • How do I get my bookmarks to display again in a column on the left of my screen, just as it always has and the way I like them. I do not want to use full screen display without the bookmarks showing.

    I have a full screen and cannot see my bookmarks.
    How do I get my bookmarks to display again in a column on the left of my screen, just as it always has and the way I like them. I do not want to use full screen display without the bookmarks showing.

    View > Sidebar > Bookmarks (Ctrl+B)
    Press F10 or tap the Alt key to bring up the "Menu Bar" temporarily.

  • HT1296 When I sync my ipad I get a message that 25% or more of my contacts will be changed.  Contacts on the ipad on the way I want them to stay.  What do I do?

    When I sync my ipad I get a message that 25% or more of my contacts will be changed.  Contacts on the ipad on the way I want them to stay.  What do I do?

    What is the exact error. You need to be more specific

  • How do I sort photos the way I want them to appear within an Event? Sort Manually is always grayed out. SAR

    Keep trying but sort manually stays grayed out. All I want to do is sort photos within one event the way I want them to appear.

    It's like iTunes:
    You can view an music album on iTunes and there are all the tracks. The hit single, the annoying filler that they stuck on, all there.
    Or you can create a Playlist of just the singles, or tracks from various albums that work together well, or just your favourite tracks from different artists and so on.
    In iPhoto: the Event has all the photos taken at that time. So, all 812 photos you took at the Wedding. All there.
    An Album allows you to just use the 50 best ones, and possibly group them with 12 from the Rehearsal and five others from the day after. Just the best shots. Or bunch all the photos of the groom from birth to today, or all the photos of the bride and her dog. Or whatever. Really, the limit is your imagination.
    Like Playlists in iTunes, images in an iPhoto album are simply referenced from the Library. So a photo can be in any number of albums and use no extra disk space.
    Then, once you couple your imagination with metadata...
    I use Events simply as big buckets of Photos: Spring 08, July - Nov 06 are typical Events in my Library. I use keywords and Smart Albums extensively. I title the pics broadly.
    I keyword on a
    Who
    What
    Where basis (The When is in the photos's Exif metadata). I also rate the pics on a 1 - 5 star basis.
    Using this system I can find pretty much find any pic in my 50k library in a couple of seconds.
    So, for example, I have a batch of pics titled 'Seattle 08' and a  typical keywording might include: John, Anne, Landscape, mountain, trees, snow. With a rating included it's so very easy to find the best pics we took at Mount Rainier.
    File -> New Smart Album
    set it to 'All"
    title contains Seattle
    keyword is mountain
    keyword is snow
    rating is 5 stars
    Or, want a chronological album of John from birth to today?
    New Smart Album
    Keyword is John
    Set the View options to Sort By Date Ascending
    Want only the best pics?
    add Rating is greater than 4 stars
    The best thing about this system is that it's dynamic. If I add 50 more pics of John  to the Library tomorrow, as I keyword and rate them they are added to the Smart Album.
    In the end, organisation is about finding the pics. The point is to make locating that pic or batch of pics findable fast. This system works for me.

  • Metadata Columns will not stay the way I order them

    I have PPro CS6 and cannot get the Metadata columns or their off/on status to stay the way I want them.  I've tried saving my settings to a custom name and find that using it to try and restore my settings does nothing, at least not in terms of the order I want the columns to be.  Also, should the Metadata panel settings change when I change Workspaces?  Am I doing something wrong?  Any help would be appreciated.  Thanks.

    Mark,
    Many thanks for your very clear explanation of how this works.  After posting I played around some more and I began to see a pattern which pointed to what you've written.
    I'll have to experiment with some scenarios to make sure I understand this more fully.  I was getting pretty frustrated. 
    None of the training I've done explains this beyond the most basic level, but as I'm discovering, there are many little "gotchas" which most training simply glosses over.  Having said that, I do enjoy the challenges... keeps me on my toes.  PPro is one hell of a product, and I use it as an amateur for my own personal stuff.
    Again, I appreciate your taking the time to explain this to me.  Thanks.
    Jim

  • How do I maintain the file structure in iphoto 6 the way i want them?

    For the past few years I have been scanning forty years worth of slides on my windows based PC. I have approximately 9500 scan as this point. Each scan is given a number such as "009500" followed by the names of persons or places shown on the picture. They are generally in chronological order. Obviously the creation of the scan has nothing to do with the date of the actual shooting of the picture. They are in the order that I want them in.
    I can import them either from an external hard drive or from cds containing a few hundred scans each.
    Is there anyway that I can maintain that kind of file structure in iphoto 6?
    Frankly, I am somewhat disappointed by all of this. My kids told me how easy the mac was for photos and I now find that it may well complicate my computer life even more.
    Mad Judge

    MJ,
    Once your files are imported into the library you can view them in many ways. When you import a file, iPhoto uses the filename as the photo title. I think you can achieve what you want by using View > Sort Photos > by Title. This will display all of your scans in the alpha-numeric order of their titles. You could then move the size slider toward the left (to reduce the thumbnail size) and quickly group your photos into Film Rolls. Click on the first photo, shift-click on the last photo, and all photos in between will become selected. Then use File > Create Film Roll to group these photos together into manageable chunks. Each time you create (or select) a film roll you can give it a descriptive title and edit the roll date. When you set the View to Film Rolls, each roll is listed in chronological order by the date of the roll - not the date of the photos within the roll. This is handy, since you can easily set the date for each roll, and it's a much less daunting task than redating your entire library. Photos within one roll will display in chronological order based on the date of the photos. I realize that with your scans these will not be accurate. So you could either change the date in iPhoto (but you said this would be a huge task) or don't worry about it. [You could use Photos > Batch Change to quickly redate the photos in a roll. Even if you don't take the time to set the exact dates, you can assign the group to a date or series of dates. By doing this you can use the calendar tool to filter your library by date. It is just one more way to make iPhoto a powerful organizer. Click on a year, month, or date in the calendar tool, and iPhoto filters your library to show the photos with those dates.] This is where your grouping into film rolls helps make your library organized - if the photos in a roll are from relatively the same time frame, then perhaps the internal order of the roll will be less important. And you can always switch your View back to Sort by Title when you need the photos to display in the exact order you have designated with your filenames. Just don't re-title the photos once they are in your library.
    If you divided your library into Film Rolls, then you could create an Album for each roll (by simply dragging the roll to the Source Pane). The advantage there is that with regular Albums, you have the option to sort the photos manually by dragging them around. (View > Sort Photos > Manually) You can switch to another sort order, and iPhoto remembers your manual order when you return to it. You do have the option to reset your manual order if you wish.
    iPhoto is very flexible, and with so many views, sorts, and filters you may well find a method that works for you. There is a shift in thinking from the way Windows software works, and if you are used to file browsers then you have to learn to play by the rules of using a database. If you can be patient and work through the learning curve, you may be rewarded. If I can clarify anything for you, please let me know.

  • Can I import bookmarks/favorites WITHOUT having them reorganized the way FF wants them?

    This issue seems common to every browser, but it's maddening to me and has prevented me from changing browsers before, but I'm really tired of IE.
    I have a lot of folders with bookmarks, and within those folders are other folders with bookmarks. The folders are in the order I want them in, as are their contents. After importing, everything has been alphabetized, and the whole structure has become worthless to me. Dragging and dropping a couple of hundred items individually is not what I want to do. Is there a way to import things exactly as they are? Would this be a logical option to have for a feature like this?

    You can export the favorites in IE to an HTML file and import this file in the Firefox Bookmarks Manager.
    If you do not have the menu bar in IE then right-click the toolbar at the top to enable the Menu Bar.
    *Export the favorites in IE to an HTML file (bookmarks.html):<br>File > Import and Export
    *Import the HTML file in Firefox:<br>Bookmarks > Show All Bookmarks > Import & Backup > Import Bookmarks from HTML
    See "Import from another browser" and "Import from file":
    *http://kb.mozillazine.org/Import_bookmarks

  • Why do my folders in my finder keep changing size and the way I set them up ....??!?!?!?!

    I cant seem to post a picture here but they are dis proprtionate to each other and ALL over the place, I set them up to be set up a certain way and it keeps changing. It is really getting me angry!!!! Any help??

    Good grief!!!!  I see what you mean now.
    Hold down the option key>Finder>Go>Library>Preferences.  Trash the com.apple.finder.plist file, repair permissions and restart your computer.   Empty the trash. 
    Open up your messed up document folder and click on the gear like icon in its menu>Arrange by - select your arrangement>Show View Options.  Click the Use As Default button.  Your arraingements should now stick.

  • How to organize tracks the way I want them?

    So this concept is very simple but might be impossible to do in iTunes. My scenario is that I am a mobile DJ, so for years I have been organizing my audio tracks on my computer following this file naming format: "Artist - Track Name.mp3", which makes my songs very easy to sort through. So, I bought my iPod classic and imported all of my tracks into iTunes, thinking that I would be able to follow this same format, but I quickly noticed that while there are many "column" options to sort the library by (title, genre, etc.), there seems to be no option to allow for my desired format. Correct me if I'm wrong, but it seems that iTunes loads in tracks according to ID3 tag info (which is often incorrect, missing info, and so on). Simply put, I cannot figure out how to get the library in Itunes to follow my "Artist - Track Name" system, which makes sorting through nearly 10,000 songs very hard and confusing, especially when I use the iPod in conjunction with my car's Alpine head unit. So, my question is, can I get the tracks to appear how they are named on my computer using the "Artist - Track Name" format, or am I being left to edit the ID3 tag info for each song (which would royally suck for 10,000 songs!). Help.

    Katrina:
    Too late on your warning unfortunately! I did have that option checked off, so iTunes screwed up about half of my files on my external HD before I stopped the process it was doing once I figured out what was going on. I've had to spend hours getting everything back to the way it was. So frustrated.
    ed2345:
    Thanks for the information. It's disappointing because I like my iPod, but in my opinion iTunes as a bundled program is complex and lacks basic things when it comes to library organization. As a DJ who requires specific control over all of my music, the iTunes system is horrendous.

  • I forgot my security questions answers. cant find the way to reset them

    I forgot my security questions answers. cant find the way to reset them

    Try this Discussion...
    https://discussions.apple.com/thread/4305745

  • How get links the way I want them on new pages?

    For new pages, is there a way I can tell DW to make the links the color I want on all new pages? thanks.

    Yes you can by learning how to style your links:  I suggest try this link:
    <http://www.w3schools.com/css/css_link.asp>
    Make sure these new links are local to your pages.  this is done by putting the styles in the header section (avoid using inline styles for reasons best kept secret to avoid arguments).
    hth

  • Why won't websites I visit stay the way I set them up when I use Firefox?

    As an example: When I go to MSNBC I set the number of articles for different subjects and they revert to default every time I open firefox. This does not happen with IE. Another is I have to log in to get to my hotmail & Gmail account every time I re-enter the browser. Please help .
    Thanks, Nicholas

    You have accidentally told Firefox not to remember cookies, or to refuse them.
    Cookies are small text files that websites use to store information used by them, such as your session ID (so you can "remember" sessions), a tracking ID (used by ad platforms to offer you personalised advertisements), or simply few preferences websites have.
    This cookies are sometimes abusive (for example, the tracking IDs), so some users may want to disable them.
    In order to tell Firefox to allow cookies again, go to Firefox/Options (Edit/Preferences), privacy tab and choose Firefox will: "Remember history" in the combo box.
    If you tried to disable browser history, that's the reason for which you have this problem. In that case you want firefox not to remember your browsing history, choose Firefox will: "Use custom settings for history" and uncheck "Always use private browsing mode" and "Clear history when Firefox closes" and check the "Accept cookies from websites" checkbox.

  • I like to have firefox 3.6.13 for Mac (OS X 10.6) to auto fill url exactly the way safari does it. Is there any way to get this done?

    It's really annoying that in firefox you need to type two letters, then go down using the arrow and then hit enter.
    In safari it's easy: you type two letters and the url and just hit enter.

    Firefox 3.6 requires at least OS X 10.4, the last version that works on OS X 10.3.9 is Firefox 2.0.0.20 available from ftp://ftp.mozilla.org/pub/mozilla.org/firefox/releases/2.0.0.20/mac/en-US/

  • Pages dont show up on web the way I saved them

    Hello,
    I'm fairly new to using IWEB. So far Ive created a site and have published it to my desktop and uploaded it using cyberDuck to web. At first all was OK. Recently I made some changes to some pages, I uploaded the new pages which supposedly overwrites the old pages. When I pulled up my website, there were all types of old fonts that I had experimented with when I was building the site, on the website. It seems somehow IWEB had remembered old versions and published them. Do I have to somehow delete old versions before I publish to my desktop folder? I thought when I hit save it would overwrite any old version. Would appreciate any help.

    Ok I checked the preferences and set it to overwrite files. There is a status bar that comes up during the transfer which also asks me if I want to overwrite the g file. I hit ok and it continues, overwriting the existing file. I,m not getting the old files any more but the fonts on text that I change, move to a different line and change color from white to black making it difficult to read against the dark background. And yes I am clearing my cache. Im using Firefox and I clear the history before I refresh. I talked to a tech support person at the web host I'm using, 1 & 1. They somehow changed the font of my text, in the code or what ever and that corrected the color change problem for that page. When I tried changing the font on my end and uploaded it it doesn't work. I just dont get it. Any other suggestions

Maybe you are looking for