« Split Personality and Revit API Class Diagram | Main | Re-Researching Lighting Family Instance Placement »

March 27, 2015

Comments

Hi Jeremy

I can't cast an Element into a View, in runtime it gives null, here's the code:
var cals = originalView.GetReferenceCallouts();

foreach (ElementId eid in cals)
{
Element elm = doc.GetElement(eid);
View vvv = elm as View;
//rest of code
}

I'll try to send this question through ADN as soon as I figure out the new subscription system! I need a support ticket on how to file a support ticket!!

thanks in advance

Dear Ammar,

1. Check in the Visual Studio debugger what type your variable 'elm' really has. That may clarify a lot.

2. No need to submit to ADN. Submitting to the Revit API discussion forum achieves exactly the same thing. Unsolved ADN member requests are automatically escalated to ADN after a little while.

Cheers, Jeremy.

Verify your Comment

Previewing your Comment

This is only a preview. Your comment has not yet been posted.

Working...
Your comment could not be posted. Error type:
Your comment has been posted. Post another comment

The letters and numbers you entered did not match the image. Please try again.

As a final step before posting your comment, enter the letters and numbers you see in the image below. This prevents automated programs from posting comments.

Having trouble reading this image? View an alternate.

Working...

Post a comment

Your Information

(Name and email address are required. Email address will not be displayed with the comment.)

Jeremy Tammik

AboutTopicsIndexSource