You need to sign in to do that
Don't have an account?
Thomas Monson
Streaming API Pushtopic creation error
Hi,
I am trying to create a pushtopic in the developer console and I am getting an error Line: 5, Column: 1
Field is not writeable: PushTopic.NotifyForOperations
Here is my code
PushTopic pushTopic = new pushTopic();
pushTopic.Name ='RefreshAccounts';
pushTopic.Query='Select ID, Name FROM Account';
pushTopic.ApiVersion = 31.0;
pushTopic.NotifyForOperations ='edit';
pushTopic.NotifyForFields='Referenced';
Insert pushTopic;
I am trying to create a pushtopic in the developer console and I am getting an error Line: 5, Column: 1
Field is not writeable: PushTopic.NotifyForOperations
Here is my code
PushTopic pushTopic = new pushTopic();
pushTopic.Name ='RefreshAccounts';
pushTopic.Query='Select ID, Name FROM Account';
pushTopic.ApiVersion = 31.0;
pushTopic.NotifyForOperations ='edit';
pushTopic.NotifyForFields='Referenced';
Insert pushTopic;
Please try the below code: Hope this helps.
Please mark this as solved if it helps.
Best Regards,
Nagendra.P