Showing posts with label Script. Show all posts
Showing posts with label Script. Show all posts

Thursday, April 23, 2009

Where is my command in RAC2010 update

I posted a blog about an incomplete ‘where is my command in RAC 2010?” tool we had created. We have completed the tool as far as we could. Now it works for Design Bar, Tool Bars and Menu commands.
You can use the “Where is my command in RAC 2010?” tool online here.

Friday, April 17, 2009

Where is my command Revit 2010 Flash movie

Updated Post:
“Where is my command” is updated. You can use it online. Now it works for Design Bar, Tool Bars and Menu commands.
Original Post:

One of my friends and myself are working on a “Where is my command” interactive tool for Revit Architecture 2010 for Revit Architecture 2009 users. This tool is *similar* to Microsoft's Office 2007 ‘where is my command’ tool.
You can use the tool online here.
The tool is 1275 x 850 pixels and needs a high resolution monitor.
This tool is a work in progress. Currently this tool works for all Design Bar commands and Tool Bar commands. Menu commands are being added and should be up in a week.
Please add comments, bugs, thanks, etc <in the comments section. I hope this tool is useful to you.

Friday, April 10, 2009

Updated scripts

I wrote about a script I had written to copy values from an excel (or open office) spreadsheet to a Revit Schedule. I have updated the script and the prep work needed to run the script have been minimized drastically. The script also allows you to select the cell in Excel / Revit to start copying / pasting. The updated script, the script code, and the readme file are here for Revit 2009 and here for Revit 2010.

I also wrote about another script that can copy values from one Revit schedule to another. This script has also been enhanced to need minimal prep work. The updated script to copy a revit schedule, the code, and the readme file are here for Revit 2009.

Please add a comment if you find any bugs or if you have any requests. Thanks.

Thursday, March 19, 2009

Copy values from one Revit schedule to another

Here is a script I wrote in Autohotkey that copies values from one Revit schedule to another. This is not done through Revit API. Instead this uses the crude Windows copy/paste commands.

It expects the cells to be contiguous. The cell values need to be instance driven (as opposed to type driven). Trying to copy similar “Mark” values for different instances might trip an “Elements have duplicate 'Number' values” error in Revit.

The executable file + the code + readme file is available as a zip file here for Revit 2009. I have also posted the file at augi (login required.)

Thursday, March 5, 2009

Script to copy values from Excel to Revit Schedule

Update:
The evaluation copy of the updated script for Revit 2011 is available at:
http://bim.nichitecture.com/copyexcel.html

Here is a script I wrote using Autohotkey to copy cell values from Microsoft Excel or Open Office.org Calc into a Revit Schedule. You can download the zip file here for Revit 2009 and here for Revit 2010. I have also posted the zip file at augi (login required)
The script copies a bunch of cells (rows x columns) and pastes them into a revit schedule (contiguous rows x columns).
  1. he script works well if all the fields in Revit schedule are EDITABLE. (A normal schedule has lots of ‘read-only’ fields like Family name, Area, etc where this script will fail.)
  2. The script does not create blank rows for data in Revit (yet). You need to create as many rows as you might need using this button in the Revit option bar before running the script.
    image
Enjoy!

Monday, May 19, 2008

Revit startup script to swap INI file

Last week I had written a blog about a simple installation script for Revit. Somebody had asked about a startup script.  We use a script to launch Revit.  This allows us to change the Revit.ini (if need be), keyboardshortcuts file, add API extensions, etc in individual boxes as and when we want it, even after the initial installation. This helps people using laptops too, making the whole process transparent. (The laptop person has to borrow licenses to use Revit fully or should have a standalone license)

To set this up, we typically create two INI files: Revit.ini - points to network resources and Revit.loc - points to local resources. Both these files are copied to "C:\Program Files\Revit Architecture 2009\Program". The script checks for a network file. If it finds it, (= network is available) then Revit launches with REVIT.INI. If the script does not find the network, then it renames REVIT.INI to REVIT.NET and then renames REVIT.LOC to REVIT.INI and opens Revit.  While in the business of swapping INI files, we also run a BATCH file whenever Revit is launched. Currently this batch file is empty, but we could add commands as and when we need them!

Currently, when an user opens a RVT file directly from Windows explorer, the startup script for Revit does NOT run. We have not YET gone that far to link the RVT extension, etc to go through the batch file, but encourage users to open Revit first and then open the project within Revit. Here is the sample batch file, please use it at your own risk.

**********************

@echo off
if not exist "Z:\REVIT\Support\RAC2009Start.bat" goto RevitnoNet

:RevitNet
call Z:\REVIT\Support\RAC2009Start.bat
if exist "C:\Program Files\Revit Architecture 2009\Program\Revit.loc" goto Revit
rename "C:\Program Files\Revit Architecture 2009\Program\Revit.ini" Revit.loc
rename "C:\Program Files\Revit Architecture 2009\Program\Revit.net" Revit.ini
goto Revit

:RevitnoNet
@echo off
cls
@echo.
@echo.
@echo.
@echo.
@echo Please wait... Network connection is NOT detected...
@echo.
@echo.
@echo Please open 'Windows Explorer' to check if Z drive is present.
@echo.
@echo.
@echo If you are working on a laptop and off the network then,
@echo.
@echo.
pause
if not exist "Z:\REVIT\Support\RAC2009Start.bat" goto Revitlocal
goto RevitNet

:Revitlocal
if exist "C:\Program Files\Revit Architecture 2009\Program\Revit.net" goto Revit
rename "C:\Program Files\Revit Architecture 2009\Program\Revit.ini" Revit.net
rename "C:\Program Files\Revit Architecture 2009\Program\Revit.loc" Revit.ini
goto Revit

:Revit
rem sTART REVIT
"C:\Program Files\Revit Architecture 2009\Program\Revit.exe.lnk" %1
exit

**********************

Friday, March 21, 2008

Install custom Revit commands

Sometime back I created a custom utility to install revit command and uploaded at augi.com at http://forums.augi.com/showthread.php?t=67696 This exe file installed custom command DLLs one at a time.

I uploaded a tweaked version of this utility at
http://forums.augi.com/showthread.php?p=824503
that might help CAD Managers. This utility installs a bunch of DLLs in a system. CAD Managers can run this utility through a windows script or batch file.

You have to be a member to access augi links. Membership is free. (Or you can email me if you want a copy of the ZIP file that contains the instructions and the code)