How can I pay the last mod to a file

I get the last mod of a file (file advanced range of I / O-> information file)

My problem is, I download files from an FTP server and the last mod of the downloaded file is not the same as on the ftp server (the local file always has the timestamp of downloaded time).

I can list the timestamp of the files on the ftp server, now I want to change the last mod to my local file in the same as on the ftp server.

How can I do this?

Thank you

Concerning

Thomas

Hello TheDharmaInitiative,

The "last modified" attribute of a file can be changed programmatically using Windows API functions.

For LabVIEW, I found a Post in an external Forum with a few attached Sourcecode:

http://www.labviewforum.de/index.php?s=c221d30094bfb9bd1edf87094f851b7f&showtopic=5895&St=0&p=28501&...

For VB, an example of source code can be found here:

http://www.vbmonster.com/Uwe/Forum.aspx/VB/31547/setting-a-file-s-timestamp

To change the "last modified" manually assigns a lot of free software and Open Source tools are available:

http://www.codeproject.com/kb/files/timestamp.aspx

Concerning

Moritz M.

Tags: NI Software

Similar Questions

  • How can I update the last line in a file.

    Hello

    I need to add text that should be on the 2nd last line of a text file. I get the last line using RandomAccessFile and surroundings,
            fileHandler.seek(fileHandler.length()-1-lastLine.length()-1);
            
            fileHandler.writeUTF("last_line\r"+lastLine.replaceFirst("0x00", "0x80"));
    updated the code above, I'm trying to add the text to the last line. But instead of add, the above code simply replaces the last line.
    How to solve this problem?

    BR
    Umer

    Just by adding a single line to rewrite the entire file may not be a good idea eapscially when the file is in MBs. so that is the reason why I use RandonAccessFile,.

    You don't know that? HDs store files on several trays at the same spot on the Board, so you won't lose anything in rewriting.

    I have also an other question. In other words, how I can I know the last line is achieved using PrintWriter?

    Steps to follow:
    1. read the entire file into a string
    2. parse the string by using the String.lastIndexOf ("\n") to the last character of line break.
    3. use printwriter to write the string up to the last line (use string.substring), then give your new data, and then enter the second part

    >

    BR
    Umer

  • sqlldr question - how can we ignore the last record of a file when loading?

    I use sqlldr to automate the loading of a file into a temporary table. I a = 1 skip to ignore the header record, but the file also contains a record of trailer that I also want to jump. Additional recording begins with a T0, but I don't know the number of records before loading.

    Since you said that tail record begins with SO you can use this:

    DOWNLOAD THE DATA
    INFILE 'fichier.dat' BADFILE, DISCARDFILE «file.dis» ' file.bad'
    ADD
    IN THE TABLE table_name
    WHEN (01)! = ' T '
    (
    column names);

    I used! = as the other is not equal to (lower, upper) symbol does not work here

  • How can I exit the recovery mode when I updated to iOS 10? !!!

    How can I exit the recovery mode when I updated to iOS10?

    Connect the device to your computer and use iTunes to reapply the update.  It worked with my Pro iPad after I first tried to live update. He went into recovery mode, so I had to download the update in iTunes and updated (new), but he returned right after that.

  • How can I stop the last post showing when I want to send this person a new Imessage.  I have an Iphone 5s

    How can I stop the last post showing when I want to send this person a new Imessage.  I don't want an old conversation appears constantly when I am a Messenger contact.  I have an Iphone 5s

    I don't know, but let me see if I understand what you're asking. You do not want to see the thread you have with a particular contact when you go to send them another message? The only way to do this is to remove the previous message thread. If you send a message to someone that you already have a thread of conversation with, it will continue to post in this thread. There is no such thing as having multiple threads with the same person. All conversations with the same person would remain in the same thread, unless you remove the previous discussions. If you delete your previous conversation, when you go to start a new conversation, he won't have any of the other answers.

  • How can I remove the silent mode when my phone is locked

    How can I remove the silent mode when my phone is locked?

    Settings - do not disturb = Off.

  • How can I change the duration of an MP3 file I downloaded? For example, I have a song that 1.5 last minute, but I want to only keep the 21 seconds. How can I culture there?

    How can I change the duration of an MP3 file I downloaded? For example, I have a song that 1.5 last minute, but I want to only keep the 21 seconds. How can I culture there?

    Your best bet would be looking for writers to mp3/wave. There are a few very good freeware/shareware sound there. I suggest this so that you can choose what format you want to save your file cropped as.

  • How can I move the Virtual Mode of Windows XP hard drive to another drive

    How can I move the Virtual Mode of Windows XP hard drive to another drive?

    TIA

    Hi Benyl,

    The vhd in programfiles basis cannot be moved or renamed, if done, xp mode stops at the start.

    To move the files under c, first to boot xp, instead of save mode the machine virtual., turn it off. (settings to prompt the user for action narrow close). Close the machine virtual., and then choose stop. This will remove the vsv file. Do not delete the .vsv file because it contains data if you have not registered in the virtual machine.

    Now, move it "C:\Users\CHRIS.domainname\AppData\Local\Microsoft\Windows virtual PC\Virtual Machines\Windows XP Mode.vhd" to a desired location.

    Parameters of xp mode open, go to the hard drive 1 setting and reposition the hard drive to the new location of the vhd. You should now be able to start the virtual machine.

    Thank you, and in what concerns:
    Shalini Surana - Microsoft technical support.
    Visit our Microsoft answers feedback Forumand let us know what you think.

  • How can we enable the html mode of the e-mail to the 9800 blackberry Simulator

    How can we enable the html mode of the e-mail to the 9800 blackberry Simulator?

    When I sent messages html Simulator, it only shows text.

    the Simulator does not support html emails

  • How can I make the last edition. I already have Adobe Creative Cloud?

    How can I make the last edition. I already have Adobe Creative Cloud?

    Is that what you mean?

    Previous through Cloud http://helpx.adobe.com/creative-cloud/help/install-apps.html#previous

    - and if you have Cloud application manager 2015 https://forums.adobe.com/thread/1906752 of difference

  • How can I force the Finder to show all files in a folder of Capitan?-instead of always having to click on "Show all" to see the full selection of files.

    How can I force the Finder to show all files in a folder of Capitan 10.11?-instead of always having to click on "Show all" to see the full selection of files.

    It is not often that I said ' what are you talking about"but" what are you talking about? "

    I do not know of all "show all" in the Finder. Can you provide a screenshot?

  • How can I get the back toolbar that says "file, editing, history, tools, etc.?

    How can I get the back toolbar that says "file, editing, history, tools, etc.?

    Don't see the menu bar (file, publishing, display, history...) (Help)? Hold down the key (key in OSX) and press the following letters in this exact order: V T M
    The bar of menus must now appear permanently, unless you turn it off again (view > toolbars). Turn on/off the menu bar is a new feature in version 3.6.
    See the other bars under view > toolbars. Click on one of them will place a check mark (display) or remove the check mark (not shown).
    To display the status bar, display, and then click status bar to place a control mark (display) or remove the check mark (not shown).

    • If items are missing then see if you can find them in the view > toolbars > customize window.
    • If you see the item in the window customize then bring her back in the window, customize the Navigation toolbar.
    • If you do not see this item then click Restore default set in the view > toolbars > customize window.
  • HDR-CX240... How can I get the camera to record all FILES VIDEO in MP4 format?

    HDR-CX240... How can I get the camera to record all FILES VIDEO in MP4 format. Is this possible? I can't find how to change what default file to save to. Any help would be appreciated.

    Hi dang201,

    There is no option to save the video in mp4 format only. You can check on the MProot folder on your memory card for mp4 files. The. MTS files are normally saved in another folder called flow.

    If my post answered your question, please mark it as "accept as a Solution.

  • How can I change the default icon for a file type

    Hey there,

    I know I did in Windows XP and I am hoping there is a way to do this in Windows 7.

    How can I change the default icon for a file type?

    I want to have all my .sql files appear with a regarless of the specific program's icon is defined as the default program to open with.

    I did some research, but he has only led hacks registry, I tried but not lucky? Does anyone know of a way?

    Here is a free software that will do it without risky registry changes.  Of course I would recommend when even take a few seconds to create a system restore point before using it, just to be sure.

    File of Type utility for Windows 7: http://types.sourceforge.net
  • How can I change the term of my video file?

    How can I change the term of my video file?  Windows DVD Maker is playing my video file listed as 26:18:32 only 26 hours instead of 26 minutes 18 seconds and 32 milliseconds.

    Hi MacChang,

     

    Thanks for posting in the Microsoft Community. It seems that you have a problem with the length of a video file playing on Windows DVD maker. This can be very frustrating for you, and I appreciate the efforts you have put in. Let us work together as a team to get this number fixed.

     

    We start with a few questions-

    (1) is specific to a particular video file?

    (2) have you made changes on the computer?

     

    I would like more information about the issue.

     

    Method 1-

     

    I wish that you disconnect any external devices to the computer. In addition, I would have you close all programs running in the background.

     

    Method 2-

    I recommend you perform the clean boot.

    Placing the computer in a boot minimum state helps determine if third-party applications or startup items are causing the problem. You must perform the steps in the article-

    How to troubleshoot a problem by performing a clean boot in Windows Vista or in Windows 7
    http://support.Microsoft.com/kb/929135

    Note: You must follow the step 3 of the article to return the computer to a Normal startup after you perform all the troubleshooting steps.

     

    In addition, see the article-

    Solve problems with creating a DVD-video using Windows DVD creation

    http://Windows.Microsoft.com/is-is/Windows7/troubleshoot-problems-with-creating-a-DVD-video-using-Windows-DVD-Maker

     

    We know if you need help. We will be happy to help you.

     

    Thank you.

Maybe you are looking for