Results 1 to 3 of 3
  1. #1
    3 Star Lounger
    Join Date
    Jan 2001
    Location
    New England (Connecticut)
    Posts
    200
    Thanks
    1
    Thanked 0 Times in 0 Posts

    unbound frames (2003)

    Please Help, I am trying to use a list box populated by a query to change the object in an unbound list box using the onclick event. History: I established an unbound object frame and put a clip of a word document in it and displayed on a form. I then created a list box and tried to create an on click event to change the object in the frame to a new word document (I'm sort of using this as a document preview situation). However no matter what I try I can't get it to work. I looked at the help text and it described a way of linking but if I follow that method exactly it still will not work. I would appreciate any thoughts on this.

    I tried this code based on previous thread suggestions within this forum:

    " With Me.objFrmContractReviewPreview
    .CLASS = "Microsoft.Word"
    .SourceDoc = "WEPT400410SHAREContractReviewEDAN00024-00-C-2103 P00016.doc"
    .Action = acOLECreateEmbed ' or acOLECreateLink
    End With"

    and get this:

    "Run Time Error 2793

    Microsoft Office Access can't perform the operation specified in the action property of the visual basic procedure youre trying to run."



    Thanks
    Kevin
    Kevin

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: unbound frames (2003)

    1) Use .Class = "Word.Document.8"
    2) Make sure that you set Enabled = True and Locked = False for objFrmContractReviewPreview, either in design view or in code.

  3. #3
    3 Star Lounger
    Join Date
    Jan 2001
    Location
    New England (Connecticut)
    Posts
    200
    Thanks
    1
    Thanked 0 Times in 0 Posts

    Re: unbound frames (2003)

    Thank You it worked great
    Kevin

Posting Permissions

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