
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hello,
I'm new to C# and the Revit API. My question is about modifying the value of the "Key Source" parameter (KEY_SOURCE_PARAM) for Keynote Tags.
Basically what happened is we were using Material Keynotes, but then something came up and now a decision has been made that we should switch to using Element Keynotes instead. We have a workaround for this, but I thought this would be a good opportunity to learn a bit of C#. I've tried modifying the parameter using Dynamo and Python but it's saying that the parameter is read only.
It seems like it's the same for C#, but I just wanted to throw this out there in case someone might know of a way to modify this parameter.
Attached is the code I used to try to modify the parameter + the manifest file for the add-in. (Won't let me upload the manifest so i'll put it at the bottom of this post)
I was also using RevitLookup to check out the parameters and saw the "AsString" Method of the Key Source parameter. I am looking into this right now to see if it's something I can modify somehow. (Image attached)
I saw on a Dynamo forum saying that if it can't be done through the UI then it probably can't be done by code - hoping this could be the exception to that.
Thanks for any advice/direction on this.
Manifest:
<?xml version="1.0" encoding="utf-8"?>
<RevitAddIns>
<AddIn Type="Command">
<Name>KeynoteTagRehost</Name>
<FullClassName>KeynoteTagRehost.Class1</FullClassName>
<Text>KeynoteTagRehost</Text>
<Description>Keynote Rehoster Test</Description>
<VisibilityMode>AlwaysVisible</VisibilityMode>
<Assembly>C:\Users\rquiambao\source\repos\KeynoteTagRehost\KeynoteTagRehost\bin\Debug\KeynoteTagRehost.dll</Assembly>
<AddInId>7c1d4806-96ea-44d7-ad0c-72e0b175aad1</AddInId>
<VendorId>ADSK</VendorId>
<VendorDescription>Autodesk, Inc, www.autodesk.com</VendorDescription>
</AddIn>
</RevitAddIns>
Solved! Go to Solution.