Results 1 to 11 of 11
  1. #1
    andypat is offline Novice
    Windows 10 Access 2016
    Join Date
    Aug 2019
    Posts
    4

    Setting MSAccess WebBrowser to view as list rather than defaul view of medium icons

    In a form on my database I have a Webrowser that point to different numbered folders via Control Source ="C:\Users\andy\MyFolders" & CStr([FolderID]) --- I have 500 folders numbered 1 to 500 which correlate with FolderID in my form/table



    It works fine but the WebBrowser viewer opens by default in Medium Icons View (see below) but I need it to programmatically open by default in list view? I'm new hear and hope someone can help please

    Click image for larger version. 

Name:	WebBrowser.png 
Views:	18 
Size:	33.5 KB 
ID:	39539

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    50,042
    Found a thread with this solution:

    WebBrowser0.Document.CurrentViewMode = 3

    However, doesn't work for me. It might be VB or VB.net, not VBA.

    Then I found this but haven't attempted to adapt https://social.msdn.microsoft.com/fo...rowser-control

    Then of course found ExpertExchange solution I can't read.

    Maybe this is not possible in Access.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    isladogs's Avatar
    isladogs is offline Very idle programmer
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    4,762
    Can you provide the code used to open the Web browser to that folder
    Colin (Mendip Data Systems): Website, email
    Try again. Fail again. Fail better.
    A
    sking for help isn't giving up. Its refusing to give up.

  4. #4
    andypat is offline Novice
    Windows 10 Access 2016
    Join Date
    Aug 2019
    Posts
    4
    Thanks for taking the time on this.

    Yes, I found those links, the first sounds simple but doesn't work, and the second doesn't seem to be vba.

  5. #5
    andypat is offline Novice
    Windows 10 Access 2016
    Join Date
    Aug 2019
    Posts
    4
    It's the webBrowser control in msaccess, there is no code, it just points to the source folder - example being ="C:\Users\andy\pictures)

  6. #6
    Ajax is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    8,963
    just out of curiosity, why not use filedialog?

  7. #7
    isladogs's Avatar
    isladogs is offline Very idle programmer
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    4,762
    Ah. I was thinking of the ActiveX version of the web browser.
    Ajax makes a very good point
    Colin (Mendip Data Systems): Website, email
    Try again. Fail again. Fail better.
    A
    sking for help isn't giving up. Its refusing to give up.

  8. #8
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    50,042
    Correct, the second is definitely VB.net and the simple one probably is as well. Sometimes I have been able to translate to VBA - unfortunately not in this case.

    Does sound like could be best to have user navigate with FileDialog.
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  9. #9
    andypat is offline Novice
    Windows 10 Access 2016
    Join Date
    Aug 2019
    Posts
    4
    Quote Originally Posted by Ajax View Post
    just out of curiosity, why not use filedialog?

    Excuse my ignorance, but has MSAccess a filedialog control -= I've never used this and cannot see it in ActiveX controls?

  10. #10
    Ajax is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    Mar 2015
    Posts
    8,963
    it is the windows filedialog and opens as a form in a separate window. Can be called from any application so not specific to Access.

    Here is a link https://stackoverflow.com/questions/...ccess-2007-vba

  11. #11
    isladogs's Avatar
    isladogs is offline Very idle programmer
    Windows 10 Access 2010 32bit
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    4,762
    Colin (Mendip Data Systems): Website, email
    Try again. Fail again. Fail better.
    A
    sking for help isn't giving up. Its refusing to give up.

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

Similar Threads

  1. Replies: 10
    Last Post: 02-06-2018, 02:37 PM
  2. Replies: 2
    Last Post: 03-05-2015, 01:10 PM
  3. Replies: 2
    Last Post: 03-09-2014, 03:21 PM
  4. Replies: 8
    Last Post: 04-29-2013, 11:23 AM
  5. Replies: 2
    Last Post: 09-21-2011, 07:23 AM

Tags for this Thread

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 - Senior Forums