Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Recent content by TekRite

  1. TekRite

    Using WORD Automation

    WC, Thanks again! Garry
  2. TekRite

    Using WORD Automation

    Walter, You are brilliant!! I am such a lame duck! YES...you were correct! When i checked to see if I had MS Word Object checked in the library...what was actually checked for diagram #2 that contained cmdButton #2 was MS Office Object...but MS Word Object had not been checked for that...
  3. TekRite

    Using WORD Automation

    Walter, I wish that would have worked...but that does not seem to be the issue. I even changed wdGoToPage to wdGoToBookmark...it works great with the first button I created. Here is the code for cmdButton #1: Option Explicit Private Sub cmdImpResTer_Click() ' 'Import Resources Procedures -...
  4. TekRite

    Using WORD Automation

    WC, Actually...I hadn't thought about checking each Visio document...I think I figured that that reference was global...once it was checked... I am at home...and I don't have access to the shared folders at work...from home...so I will check this out first thing in the AM and let you know...
  5. TekRite

    Using WORD Automation

    PH, Thanks for the TIP...I tried it but it still didn't work...After talking to the Program Manager overseeing this project...I think I'll need to find a true solution...she doesn't even want the 'hard coded' page numbers in there for maintenance reasons... Thank you though! Garry
  6. TekRite

    Using WORD Automation

    WC, I thought about that...which is why I copied the code identically...and pasted it to the 2nd button...but I still get the error... I am thinking about using a 'Bookmark' instead of a Page reference...because as the document changes...so will the Page numbers...but if I reference the Page...
  7. TekRite

    WORD Automation (wdGoToPage)

    The problem I am having with the code below seems to be with its "reusablity" with subsequent Command Buttons. The code "works fine...lasts a long time" with the initial Command Button it is assigned to... but when I copy and paste it to another Command Button I get either a 'Compile Error'...
  8. TekRite

    Using WORD Automation

    WC, Thank you for that TIP...once I get this working...I will put it in a sub-routine... I 'killed' all of my code and started from scratch...just to see if it was some kind of 'cyber' glitch or something. I used the working code that I had...along with the additions that you provided...and...
  9. TekRite

    Using WORD Automation

    Hi Walter, One more thing...I know this is crazy...but here is the code that works...well...at least for a single Command Button...I just cannot get it to work for any other buttons...(The problem lies within the wdGoToPage constant): Private Sub cmdImpResTer_Click() ' 'Import Resources...
  10. TekRite

    Using WORD Automation

    Walter, I must say...I have a true respect for programmers...I came in with a full head of hair today...and I am now down to just 2 strands of hair left! : ) I am still getting an error referencing wdGoToPage as an undefined variable...yet...my initial code does not give me that error...and it...
  11. TekRite

    Using WORD Automation

    Actually Walter...I think you have been extremely helpful! You have added the little extras that will keep many future errors out and keep this small program from crashing...and I appreciate that! I have already referenced the Object library (11.0 in my case) and have included reference to it...
  12. TekRite

    Using WORD Automation

    Walter, Once again...Thank you so much... For some reason I am now getting the Error Message 'Compile Error' "Variable not defined" and it is referencing: 'wdGoToPage' as the varibale not defined in the GoTo Method. I don't understand why it is trying to read the item as a variable. I even...
  13. TekRite

    Using WORD Automation

    Hi Walter, Thank you so much for this...I tried the code...but I am getting a 'Compile Error' "Variable not defined" for: ActiveWorkbook With my changes to your code...here is what it looks like so far: Option Explicit Sub OpenWord1() Dim Wd As Object Set Wd = Nothing ' 'Get Reference to...
  14. TekRite

    Using WORD Automation

    Hi Walter, That is an excellent question. I thought that the 'IfFound' statement would handle that...but I am not a VBA programmer...I just dabble a bit. I am actually a Technical Writer who discovered that my drawings would benefit greatly by adding ActiveX Controls running small...
  15. TekRite

    WORD Automation Dilemma...still hovering over me...

    I am still stuck with my problem...The code that I generated for a Command Button <cmdImpResTer> works great. It CREATES an instance of WORD...OPENS the specified document...then goes to the specified page...wdGoToPage. My problem is that when I use the code again for another Command Button...

Part and Inventory Search

Back
Top