Hi @leebrg. Some of what you said did not make sense, or seemed to contradict itself, so I just wanted to clarify the details.
- A 'Sheet' does not have any 'scale' to it. It only has a Size (from DrawingSheetSizeEnum), Height, & Width.
- You want code that will place a single view of a model into a Sheet in a DrawingDocument.
- That task will most likely be using the DrawingViews.AddBaseView method, but there are lots of similar methods for adding views into a drawing, so not sure at this point.
- While doing that, you want to control the size of the view it places, so that it fits within the Sheet, without changing the size (or orientation) of the Sheet.
- What about the orientation of the model within the view itself?
- We do not know what orientation your sheet is in (portrait or landscape).
- We do not know what direction this view should be looking at the model from.
- We do not know what orientation your model is in, or how you would prefer it to be oriented within the view on the sheet.
- Do you want the code to change the orientation of the view, if that will help it fit into the sheet better?
This task would most likely require some relatively complex code that will measure the overall size of your model, in model space. Determine its orientation based on which directions it is narrowest in, and which it is longest in. Compare that to the size and orientation of the sheet. Determine if it must avoid borders and/or title blocks within the bounds of that sheet. If it must avoid those, then determine what area of the sheet is 'available' for a view, without overlapping the border or title block. Use that interior available space to compare to the model's size & orientation. Do the math to figure out what orientation will fit best, then what scale will be needed, and where within the bounds of that sheet to place the view. Lots of complex stuff to be figured out, and lots of code to make all that happen.
Wesley Crihfield

(Not an Autodesk Employee)