See the top rated post in this thread. Click here

Page 1 of 10 12345 ... LastLast
Results 1 to 10 of 94

Thread: Find and Replace

  1. #1
    I could stop if I wanted to Danny Polkinhorn's Avatar
    Join Date
    2003-12
    Location
    San Francisco, CA
    Posts
    448
    Login to Give a bone
    1

    Default Find and Replace

    All,

    I put together a simple Find and Replace utility that searches text notes in the Revit model. I am publishing it here so you can see the source and modify/update it as you see fit. If you make changes to the source, please post a new compiled version and your source here.

    Important:
    I'm not responsible for what this utility does to the text in your project. While I have made every effort to ensure that this works properly, you should check the text yourself. You can always undo.

    To use:

    Download the FindReplace-Compiled.zip file and unzip it in the location of your Revit.exe file. Place the contents of FindReplace-Revit.ini into your Revit.ini file. After launching Revit, you'll find it under Tools > External Tools > Find and Replace. You can add a keyboard shortcut for it if you want.

    It works fastest if you select the text you want to search prior to running the command. Otherwise, it has to search the ENTIRE model looking for text notes. This could take a while if you have a large model.

    It only searches text notes, not parameters in tags.

    If you have spaces at the beginning or end of a text note, they will be lost. I think this is an issue with Revit.

    Source notes:

    The utility uses the Revit API for RB 8.1/RS 2. For later versions of Revit, you will need to re-reference the RevitAPI.dll and recompile.

    The VB.NET source and solution files are in the FindReplace-SourceCode.zip file. The source is commented so you can follow it. If you have any questions, please post here.

    Enjoy,
    Attached Files Attached Files

  2. #2
    Super Moderator beegee's Avatar
    Join Date
    2003-05
    Location
    crusing 11 kms above Australia
    Posts
    5,153
    Login to Give a bone
    0

    Default Re: Find and Replace

    Keep up the good work Danny.

  3. #3
    I could stop if I wanted to Danny Polkinhorn's Avatar
    Join Date
    2003-12
    Location
    San Francisco, CA
    Posts
    448
    Login to Give a bone
    1

    Default Re: Find and Replace

    Here's an updated version for Revit 9. No changes, just re-compiled for 9.
    Last edited by Danny Polkinhorn; 2006-05-12 at 12:34 AM. Reason: Sorry, recompiled with the old RevitAPI still referenced. Download this one.

  4. #4
    100 Club Eric Stewart's Avatar
    Join Date
    2003-09
    Location
    Raleigh, NC USA
    Posts
    138
    Login to Give a bone
    0

    Default Re: Find and Replace

    Now THAT'S service!!

    Thanks again.

  5. #5
    AUGI Addict christopher.zoog51272's Avatar
    Join Date
    2003-04
    Location
    Cinnaminson, NJ / NYC
    Posts
    1,096
    Login to Give a bone
    0

    Default Re: Find and Replace

    Sweet! Somehow I missed this when it was first posted, thanks Danny!
    Chris
    SOM | New York

  6. #6
    100 Club Eric Stewart's Avatar
    Join Date
    2003-09
    Location
    Raleigh, NC USA
    Posts
    138
    Login to Give a bone
    0

    Default Re: Find and Replace

    For some reaseon, I can't get it to work in 9.0.

    Quote Originally Posted by czoog
    Sweet! Somehow I missed this when it was first posted, thanks Danny!

  7. #7
    I could stop if I wanted to Danny Polkinhorn's Avatar
    Join Date
    2003-12
    Location
    San Francisco, CA
    Posts
    448
    Login to Give a bone
    0

    Default Re: Find and Replace

    Sorry, I didn't realize that it was still referencing the old RevitAPI.dll. Fixed that bug and made the required changes to the Execute command. New one is posted here.
    Attached Files Attached Files

  8. #8
    100 Club Eric Stewart's Avatar
    Join Date
    2003-09
    Location
    Raleigh, NC USA
    Posts
    138
    Login to Give a bone
    0

    Default Re: Find and Replace

    Once again, thank you.

  9. #9
    AUGI Addict Scott Hopkins's Avatar
    Join Date
    2003-05
    Location
    Santa Barbara, CA
    Posts
    1,197
    Login to Give a bone
    0

    Question Re: Find and Replace

    Danny,

    Thanks for posting this. It looks cool. Unfortunately I can't get ti to work. I keep getting the same error message:

    "Object reference not set to an instance of an object."

    Am I doing something wrong?

  10. #10
    I could stop if I wanted to Danny Polkinhorn's Avatar
    Join Date
    2003-12
    Location
    San Francisco, CA
    Posts
    448
    Login to Give a bone
    0

    Default Re: Find and Replace

    Scott,

    I'll need a little more information I think.

    Are you using the correct version? There's 2 posted here, one for 8.1 and one for 9.
    Are you selecting text prior to running the command or running it without selecting?
    Does it work in a blank project with just a few pieces of text?

Page 1 of 10 12345 ... LastLast

Similar Threads

  1. 2007: Find & replace
    By nextvkin in forum AutoCAD General
    Replies: 6
    Last Post: 2015-09-06, 11:19 PM
  2. Find and Replace
    By RMEYER.46723 in forum AutoCAD Civil 3D - General
    Replies: 5
    Last Post: 2009-06-09, 01:53 AM
  3. Find and Replace
    By U.Rackharrow in forum AutoCAD General
    Replies: 9
    Last Post: 2007-10-16, 02:44 PM
  4. Find / Replace
    By gs in forum Revit Architecture - General
    Replies: 3
    Last Post: 2005-12-09, 07:16 PM
  5. Find & replace
    By markl.70662 in forum Revit Architecture - Wish List
    Replies: 4
    Last Post: 2005-05-25, 05:12 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
  •