error in "Navisworks.Timeliner.Plugin"

error in "Navisworks.Timeliner.Plugin"

Anonymous
Not applicable
560 Views
1 Reply
Message 1 of 2

error in "Navisworks.Timeliner.Plugin"

Anonymous
Not applicable

Hello;

I am using nw api and i assign some values to  timeliner tasks "user1" and "user2"  using TaskReplaceWithCopy.

it works for first and second run and assigns my value to all timeliner taks ; but when pressing button for third time a highlighted green error displays in my code , on the line TaskReplaceWithCopy (means external error);

propoerties of the erorr are as follow:

- $exception {"Object reference not set to an instance of an object."} System.Exception {System.NullReferenceException}

- Source "Navisworks.Timeliner.Plugin" string

 

StackTrace " at Autodesk.Navisworks.Timeliner.VM.GanttVM.GetTaskIndex(GroupItem task)\r\n at Autodesk.Navisworks.Timeliner.VM.GanttVM.CanIndent(TimelinerTask task)\r\n at Autodesk.Navisworks.Timeliner.VM.GanttVM.IsIndentValidForCurrentSelection()\r\n at Autodesk.Navisworks.Timeliner.VM.TasksTabVM.<.ctor>b__22(GanttVM vm)\r\n at System.Windows.Controls.Primitives.ButtonBase.UpdateCanExecute()\r\n at Microsoft.Practices.Prism.Commands.WeakEventHandlerManager.CallWeakReferenceHandlers(Object sender, List`1 handlers)\r\n at Autodesk.Navisworks.Timeliner.VM.TasksTabVM.OnGanttSelectionChanged()\r\n at Autodesk.Navisworks.Timeliner.VM.TasksTabVM.get_Gantt()\r\n at Autodesk.Navisworks.Timeliner.VM.TabsWindowVM.OnTimelinerCurrentTaskChanged(Object sender, TimelinerCurrentTaskNotifyEventArgs e)\r\n at Autodesk.Navisworks.Api.Interop.TimelinerCurrentTaskNotify.OnCurrentTaskChanged(Boolean from_external)\r\n at Autodesk.Navisworks.stub.LcTlCurrentTaskNotify.OnCurrentTaskChanged(LcTlCurrentTaskNotify* , Boolean is_from_interop)" string

 

any idea about this?

0 Likes
561 Views
1 Reply
Reply (1)
Message 2 of 2

Anonymous
Not applicable

i'm still working on this issue,

the root of this error is in  a method named "GetTaskIndex(GroupItem)" in  "Navisworks.Timeliner.Plugin.dll" :

 

  private int GetTaskIndex(GroupItem task) =>
task.Parent.Children.IndexOf(task);

 

and produces this error.

 

i think this is a bug and should be fixed.

0 Likes