Author Topic: Help accessing hanger ancillary info in Revit  (Read 6380 times)

0 Members and 1 Guest are viewing this topic.

Offline bitterfitterTopic starter

  • Senior Member
  • ****
  • Posts: 451
  • Country: us
  • Gender: Male
Help accessing hanger ancillary info in Revit
« on: Jan 31, 2022, 16:55:19 PM »
I am looking to extract my hanger ancillaries using Dynamo.  I notice when I use the Snoop add-In on my hanger, I get a list of what looks to be many hidden parameters. See attachment 1

If I expand the "Get Part Ancillary Usage" line, I get the list shown in attachment 2

This looks promising as it references all the pieces that are in the set ancillary to that chosen hanger.  Any ideas on how I can access this list through Dynamo? I am thinking:
choose hanger elements
look for the parameter named " Get Part Ancillary Usage"
List these parameters
write each parameter to a new set of Shared parameters that I can then write in a schedule???
"If you think education is expensive, you should see what ignorance costs you"

Offline acad2015

  • Full Member
  • ***
  • Posts: 117
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #1 on: Jan 31, 2022, 19:19:21 PM »
I cobbled something together quickly to get you started. You should be able to build off of it to make it your own. If I have more time later on, I will try to supply you with a more finished product, but don't hold your breath. Haha.

Offline bitterfitterTopic starter

  • Senior Member
  • ****
  • Posts: 451
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #2 on: Jan 31, 2022, 19:40:17 PM »
Thanks for the head start!  I am going to see what kinda trouble I can get into with it... ;D  I will make sure to post any progress I make to help out the next guy.
"If you think education is expensive, you should see what ignorance costs you"

Offline bitterfitterTopic starter

  • Senior Member
  • ****
  • Posts: 451
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #3 on: Feb 01, 2022, 14:40:58 PM »
acad2015 - I started working with the custom node but I am encountering a naming error in line 38. I tried a few things but I could not seem to get it to work properly.  Any chance that you could just see if it is something basic I am just overlooking?  Other than that everything is working good....
"If you think education is expensive, you should see what ignorance costs you"

Offline acad2015

  • Full Member
  • ***
  • Posts: 117
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #4 on: Feb 01, 2022, 14:56:16 PM »
Here you go. I fixed it. This will get you the Ancillary Ids. It's not very useful as it is, but hopefully it will shed some light on how to access that data.

Offline bitterfitterTopic starter

  • Senior Member
  • ****
  • Posts: 451
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #5 on: Feb 01, 2022, 15:02:07 PM »
Thank you.  I really hated to ask for your help again after you took the time to post the node in the first place.
"If you think education is expensive, you should see what ignorance costs you"

Offline acad2015

  • Full Member
  • ***
  • Posts: 117
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #6 on: Feb 01, 2022, 15:21:11 PM »
Thank you.  I really hated to ask for your help again after you took the time to post the node in the first place.

Don't worry about that. If I have time to help, I will.

Offline bitterfitterTopic starter

  • Senior Member
  • ****
  • Posts: 451
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #7 on: Feb 01, 2022, 15:59:25 PM »
acad2015 - I think I broke it already..  ;D

I seem to be getting an error in line 35 - I may take a break and come back to this.  Starting to see double already LOL
"If you think education is expensive, you should see what ignorance costs you"

Offline acad2015

  • Full Member
  • ***
  • Posts: 117
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #8 on: Feb 01, 2022, 16:03:12 PM »
Haha. Ok. I'll try and find time to make a working version.

Offline bitterfitterTopic starter

  • Senior Member
  • ****
  • Posts: 451
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #9 on: Feb 01, 2022, 16:26:24 PM »
Here is a little info that might help.  I ran the node the first time and it generated the list of AncillaryIds as expected.  When I tried running it again, I started getting the error in line 35.  I even tried running the original node you posted and now I get an error at line 35 on that one also.  I am starting to think I may have broken something good.. :(
"If you think education is expensive, you should see what ignorance costs you"

Offline Axl

  • Full Member
  • ***
  • Posts: 176
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #10 on: Feb 01, 2022, 19:27:40 PM »
Sometimes, when you get critical issues with Dynamo the virtual machine (created by Dynamo) gets corrupted or damaged, close the script completely and try again, sometimes even requires to reload the view or Revit.
CADmep DB Manager
Content Manager
Scripting

Offline bitterfitterTopic starter

  • Senior Member
  • ****
  • Posts: 451
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #11 on: Feb 02, 2022, 13:53:48 PM »
I have tried reloading the script, shutting down Revit and restarting and even tried a different project.  Same error coming up.  see attachment
"If you think education is expensive, you should see what ignorance costs you"

Offline acad2015

  • Full Member
  • ***
  • Posts: 117
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #12 on: Feb 02, 2022, 14:08:09 PM »
Try having 2 items selected. I do not think I put in the necessary code to run on only one item. I truly did that way to quick and probably sent you down a rabbit hole with hardly anything to go on now that I look back at it.

Offline bitterfitterTopic starter

  • Senior Member
  • ****
  • Posts: 451
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #13 on: Feb 02, 2022, 14:28:14 PM »
You are a genius!  I tried it on three hangers and voila!!  worked as expected.  I can't believe I didn't catch this.  Sorry for taking up some much of your time. :-[
Can I just run one thing past you?  So to list the "Type" under FabricationAncillaryUsage, can I just simply replace "AncillaryId" with "Type"?
"If you think education is expensive, you should see what ignorance costs you"

Offline acad2015

  • Full Member
  • ***
  • Posts: 117
  • Country: us
  • Gender: Male
Re: Help accessing hanger ancillary info in Revit
« Reply #14 on: Feb 02, 2022, 14:50:31 PM »
Replace the one I circled with "Type".