Results 1 to 3 of 3

Thread: [RESOLVED] File saving

  1. #1

    Thread Starter
    Lively Member
    Join Date
    May 2008
    Posts
    90

    Resolved [RESOLVED] File saving

    Hi, hope you can help.

    I would like to know if it is possible to make my application be able to save the file as the current date. the idea is to have it where the staff login to the application and the application opens the file with the current day.

    This means that in the morning before staff open the program the office staff can put up the information, i.e. like briefing sheet, daily notes. etc

    Hope you can help
    Sorry for the bad explanation
    Stuart
    Last edited by Hack; Mar 18th, 2009 at 06:08 AM. Reason: Added RESOLVED to thread title and green resolve checkmark

  2. #2
    Super Moderator jmcilhinney's Avatar
    Join Date
    May 2005
    Location
    Sydney, Australia
    Posts
    111,221

    Re: File saving

    I assume you mean saving a file with a name that represents the current date. You can save a file with any name you like, as long as it follows Windows rules regarding length and legal characters. You can use the String.Format or Date.ToString method to create a string containing the current date. I'd suggest using the yyyyMMdd format as it means that alphabetical order and chronological order will be synchronised, e.g.
    vb.net Code:
    1. Dim fileName As String = String.Format("{0:yyyyMMdd}.txt", Date.Now)
    Why is my data not saved to my database? | MSDN Data Walkthroughs
    VBForums Database Development FAQ
    My CodeBank Submissions: VB | C#
    My Blog: Data Among Multiple Forms (3 parts)
    Beginner Tutorials: VB | C# | SQL

  3. #3

    Thread Starter
    Lively Member
    Join Date
    May 2008
    Posts
    90

    Thumbs up RESOLVED: File saving

    Hey, Thanks for that.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width