Results 1 to 10 of 10
  1. #1
    anandram is offline Novice
    Windows XP Access 2007
    Join Date
    Mar 2011
    Posts
    27

    Lightbulb Save files through form into a folder (drag and drop)


    Hi,

    I currently have buttons that create folders in windows in my forms. User creates folder then opens from form and puts file inside (pdf/word doc/whatever)

    I was just thinking whether it is possible to be able to drag a file into a particular text box/field in the access form and for the file to be saved at the backend folder.

    I basically wanted to see if i could limit the users navigating around the backend windows folders, and for everything to be able to be opened and saved from within access form itself?

    Note i dont want the files as attachments in the forms (DB would get too big).

    I guess this is a simple drag and drop operation? Any ideas?

    Thanks for the ideas/help.

  2. #2
    ajetrumpet is offline VIP
    Windows Vista Access 2007
    Join Date
    Mar 2010
    Location
    N/A
    Posts
    2,694
    you can actually simulate the windows explorer in an access form. I have an example of it and it runs pretty fast actually.

    If you'd like to see if I could upload it here. You'd obviously have to do the keystroke captures though, but the explorer functionality is already there. It's pretty neat.

  3. #3
    anandram is offline Novice
    Windows XP Access 2007
    Join Date
    Mar 2011
    Posts
    27
    I'll take a look if thats ok?

  4. #4
    ajetrumpet is offline VIP
    Windows Vista Access 2007
    Join Date
    Mar 2010
    Location
    N/A
    Posts
    2,694
    this is a sample FTP app I used one time.

    the right side of the form is the windows explorer portion. It's just as fast as the actual explorer, if not faster.

    what I was saying is that you can use this stuff the way this is set up and simply capture keystrokes. you can also use highlighted files in the directory window to copy, move, delete, or whatever. When I do it, I use the DOS command in vba. It's a one liner and it doesn't take but a millisecond to run.

  5. #5
    khalid's Avatar
    khalid is offline MS-Access Developer
    Windows 7 64bit Access 2010 64bit
    Join Date
    Mar 2010
    Location
    Kuwait
    Posts
    244
    Hi Adam,

    I got the missing or broken reference to the file 'MSPPT.OLB' version 2.9 error while opening the .mdb file (I have .accdb Access-2010 installed on my pc).

    I wanna study the codes of the utility

  6. #6
    ajetrumpet is offline VIP
    Windows Vista Access 2007
    Join Date
    Mar 2010
    Location
    N/A
    Posts
    2,694
    just go in and uncheck the MISSING references in the vba editor, my friend.

    MSPPT.OLB is powerpoint for ms office. I must have it checked on accident.

  7. #7
    anandram is offline Novice
    Windows XP Access 2007
    Join Date
    Mar 2011
    Posts
    27
    Quote Originally Posted by ajetrumpet View Post
    this is a sample FTP app I used one time.

    the right side of the form is the windows explorer portion. It's just as fast as the actual explorer, if not faster.

    what I was saying is that you can use this stuff the way this is set up and simply capture keystrokes. you can also use highlighted files in the directory window to copy, move, delete, or whatever. When I do it, I use the DOS command in vba. It's a one liner and it doesn't take but a millisecond to run.
    hey, thanks for this. although i dont understand what you mean by capturing keystrokes or why that is important. Could you elaborate please?

    The other question and i hope it doesnt come across rude or ungrateful, but why would i want to use this explorer over the windows one and for the purpose i was looking for in the original post? Aside from the fact it is integrated in access? Would it not just give the same functionality as the windows explorer? Excuse my ignorance

  8. #8
    ajetrumpet is offline VIP
    Windows Vista Access 2007
    Join Date
    Mar 2010
    Location
    N/A
    Posts
    2,694
    Quote Originally Posted by anandram View Post

    I was just thinking whether it is possible to be able to drag a file into a particular text box/field in the access form and for the file to be saved at the backend folder.
    THAT is what you asked my friend. the purpose of what I posted was to give you the tools (code and otherwise) to get that done.

    DRAG AND DROP is extremely difficult in access. Pretty much impossible, to where it concerns developers anyway.

    my point of the "key captures" statement was: say you tell your users that "X" cuts a file from it's current location and "Y" pastes it into another folder. Obviously you can use ASC() and CHR() functions to capture those keystrokes and run a DOS function to actually move the file in the windows explorer "in the background". Does that make sense to you??

    The code is very difficult to understand. so obviously it's for experts. But that was the point of this whole thing. Make sure you remember what you first asked!

  9. #9
    anandram is offline Novice
    Windows XP Access 2007
    Join Date
    Mar 2011
    Posts
    27
    Like i said i wasn't trying to sound rude. I recall what i asked but it wasn't what i had in mind that's all.

    Also, I tried to open the DB and the file said it was corrupt or something. Although i think what you have just explained above may be a bit more than what i need, and beyond my ability. Thanks for the help though, i think i'll prob just stick with "create folder", and allow users to open and drop files into the explorer window.

  10. #10
    ajetrumpet is offline VIP
    Windows Vista Access 2007
    Join Date
    Mar 2010
    Location
    N/A
    Posts
    2,694
    no problem. for the corruption, see KHALID's post earlier.

Please reply to this thread with any new information or opinions.

Similar Threads

  1. show filters files form a Folder
    By jimmyp75 in forum Programming
    Replies: 5
    Last Post: 03-16-2011, 12:46 PM
  2. Drag and Drop into Textbox
    By jagvent in forum Forms
    Replies: 1
    Last Post: 12-20-2010, 09:31 AM
  3. Drag n Drop BETWEEN textbox and web browser
    By kirklandwater123 in forum Programming
    Replies: 4
    Last Post: 10-29-2010, 01:23 AM
  4. Drag and Drop Between Textboxes. Please Help!
    By kcpope in forum Programming
    Replies: 2
    Last Post: 10-19-2010, 05:03 PM
  5. Drag N Drop example between 2 listboxes
    By pkstormy in forum Code Repository
    Replies: 0
    Last Post: 08-30-2010, 10:10 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums