Results 1 to 2 of 2
  1. #1
    Join Date
    Jul 2012
    Posts
    1

    Question Unanswered: Getting Access to create a file folder with the value in a text box on a form.

    Hi all I am using Access 2007 to create a project management tool. the work case I am trying to solve is that as I create a "project" record I want to create a series of folders titled with information from the form I am using to create the "project" record.

    Example: as I create a record for a project with the title "120724 Phone Recording" I want to have Access/VBA create a folder with the title "120724 Phone Recording". I am assuming I would need to enter the name into the field, then hit a button with a macro that creates the folder.

    What I currently have working is a simple MkDir command that creates a file where I want, but with no variable information pulled from access.

    My question is: How do I get information to pass from Access to the VBA environment? I this example how can I get momentary information from a field into VBA in a way that I can use it as a element to name a folder with the MkDir command?

    Thanks all!

  2. #2
    Join Date
    May 2005
    Location
    Nevada, USA
    Posts
    2,888
    Provided Answers: 6
    In general, you concatenate data references with fixed text. If it's on the form the code is running form, this type of thing:

    "C:\Whatever\" & Me.TextboxName
    Paul

Posting Permissions

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