Results 1 to 8 of 8

Thread: [RESOLVED] ms access/ vba display ms word preview window

  1. #1

    Thread Starter
    Fanatic Member
    Join Date
    Sep 2005
    Posts
    586

    Resolved [RESOLVED] ms access/ vba display ms word preview window

    I was wondering how could you display a preview window of an ms word document from within ms access application.

    I'd like to create word documents based on variables from my access database without needing to go from ms access window to ms word windows which gets messy once you want to preview different word docs.

    any ideas?

  2. #2
    PowerPoster Static's Avatar
    Join Date
    Oct 2000
    Location
    Rochester, NY
    Posts
    9,390

    Re: ms access/ vba display ms word preview window

    stick an unbound object frame in your form. Access will prompt you for what you want in it.. pick MS Word Doc...

    does that help?
    JPnyc rocks!! (Just ask him!)
    If u have your answer please go to the thread tools and click "Mark Thread Resolved"

  3. #3

    Thread Starter
    Fanatic Member
    Join Date
    Sep 2005
    Posts
    586

    Re: ms access/ vba display ms word preview window

    sure, but how do you program the unbound object control to display a filename variable. meaning something like (this doesnt work) :

    Private Sub Filename_Click()
    me.unbound_object.SOURCEFILE = me.filename
    me.unbound_object.requery
    End Sub

  4. #4
    PowerPoster Static's Avatar
    Join Date
    Oct 2000
    Location
    Rochester, NY
    Posts
    9,390

    Re: ms access/ vba display ms word preview window

    couldnt get it to work either.. sorry. never tried it before.
    JPnyc rocks!! (Just ask him!)
    If u have your answer please go to the thread tools and click "Mark Thread Resolved"

  5. #5

    Thread Starter
    Fanatic Member
    Join Date
    Sep 2005
    Posts
    586

    Re: ms access/ vba display ms word preview window

    you can think of it better as a "MS Word File Viewer" - when you press a certain file name, this file content will show in the object frame.

    any ideas?

  6. #6

    Thread Starter
    Fanatic Member
    Join Date
    Sep 2005
    Posts
    586

    Re: ms access/ vba display ms word preview window

    I don't think it should be with a unbound object ,but rather with a bound object. but question is how do you program a bound object?

  7. #7
    Ex-Super Mod RobDog888's Avatar
    Join Date
    Apr 2001
    Location
    LA, Calif. Raiders #1 AKA:Gangsta Yoda™
    Posts
    60,709

    Re: ms access/ vba display ms word preview window

    You could import a richtextbox vb6 control to your access form but you would also need to distribute the ocx with yoiur db. Then you can display the document contents in the rtb.
    VB/Office Guru™ (AKA: Gangsta Yoda®)
    I dont answer coding questions via PM. Please post a thread in the appropriate forum.

    Microsoft MVP 2006-2011
    Office Development FAQ (C#, VB.NET, VB 6, VBA)
    Senior Jedi Software Engineer MCP (VB 6 & .NET), BSEE, CET
    If a post has helped you then Please Rate it!
    Reps & Rating PostsVS.NET on Vista Multiple .NET Framework Versions Office Primary Interop AssembliesVB/Office Guru™ Word SpellChecker™.NETVB/Office Guru™ Word SpellChecker™ VB6VB.NET Attributes Ex.Outlook Global Address ListAPI Viewer utility.NET API Viewer Utility
    System: Intel i7 6850K, Geforce GTX1060, Samsung M.2 1 TB & SATA 500 GB, 32 GBs DDR4 3300 Quad Channel RAM, 2 Viewsonic 24" LCDs, Windows 10, Office 2016, VS 2019, VB6 SP6

  8. #8

    Thread Starter
    Fanatic Member
    Join Date
    Sep 2005
    Posts
    586

    Re: ms access/ vba display ms word preview window

    1. how do I import a control from vb6?
    2. is there no way I can program a bound object control?

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