I can not project txWeldLocation,
following code throw "Error in application" exception:
TxWeldLocationOperation notProjected = txObjEditBoxCtrl_orginal.Object as TxWeldLocationOperation;
notProjected.Project(notProjected.WeldPoint.LeadingPart as ITxLocatableObject, false );
I make sure that part and mfg are displayed. But it does not help
I've never used this method, but a few things to check:
1 - Is the WeldPoint assigned to a part? (Check that 'notProjected.WeldPoint.LeadingPart' is not a null object)
2 - If you change 'projectToApproximation' property to true, do you get the same error?
Can you send the exception returned when debugging the command? I implemented something really simple and I'm not being able to reproduce the error (unless I force some impossible conditions, like trying to project a non-projectable object or trying to project a location without a part to project on).
The exception is "error in application" so I am not able to figure out where is the problem, please take a look on screen.
Right now I found that the function txWeldLocation.Project() works sometimes.
But I also found a way to generate error:
1. add Mfg to weld path.
2. project MFG.
3. delate projection (leave MFG in path but not projected).
4. Now you are not able to project MFG by command and also by API.
I tested it on two cells and get the same result.
By weld path do you mean weld operation? Because I still can't reproduce the error. Are you using connected or disconnected Process Simulate (and which version)?
Although, looks that is not an error from implementation itself, but more likely a software behavior that is limiting it. Maybe someone from Siemens can help on a fix.