You're almost there! Please answer a few more questions for access to the Applications content. Complete registration
Interested in joining? Complete your registration by providing Areas of Interest here. Register

Copying Object with WorkspaceRibbonButton AddIn

Received Response
11
Views
1
Comments
edited May 8, 2015 9:44AM in UI Extensibility 1 comment

Content

Hi all,

I have developed a WorkspaceRibbonButton AddIIn, which has to copy some fields from Answer object, then make a new Answer object with pasted fields.

The case is that when I make new Answer object with

IRecordContext _recordContextanswer2 = (IRecordContext)_globalContext.AutomationContext.CreateWorkspaceRecord(RightNow.AddIns.Common.WorkspaceRecordType.Answer);

the new AddIn is made and I lose RecordContext, so I can't fill the fields on new Answer object.
The error is "Object reference not set to an instance of an object", but I think that the issue is making an AddIn that can pass the values of the fields in the CreateWorkspaceRecord or make an AddIn that (when new Answer is made) will not be in the Ribbon(so that AddIn won't be in infinite loop after clicking its button).

Howdy, Stranger!

Log In

To view full details, sign in.

Register

Don't have an account? Click here to get started!