How to add the activity stream for custom tables

J_r_my1
Kilo Guru

Hello everyone,

I have created an applet for my custom tables. I have created a new field Additional comments as my table is not a child table from task. I have added it in my activity inside my form.

But when I try to add comments from the agent application mobile in the activity stream, I got an error, and I can't add any additional comments. I got the error failed to add additional comments

find_real_file.png

 

 

I have been able to add comments if I create a function but not from the activity stream. Does anyone know where my error is? 

8 REPLIES 8

P-Rudenko-SN
ServiceNow Employee
ServiceNow Employee

You should normally create an activity formatter for you custom table.

  1. Navigate to System UI > Formatters.
  2. Click New.
  3. Enter a name for the formatter, such as Activities (task).
  4. Select a Table (your custom one).
  5. Enter activity.xml in the Formatter field.
  6. Leave the Type as Formatter.
  7. Click Submit.

Please let me know if this helps.

I tried this solution but unfortunately, it didn't work.

Does someone know where I can finds the logs for this issue, as I am not able to found any in the log system

Fernando Koenra
Kilo Sage
Hi Jérémy,
 
Maybe you've solved it by now, but I'm just updating this post for others as I was experiencing the exact same issue. 
 
In my case it was that the comments field was corrupt (recreated it) and there being scope application issues.
For this mobile journal activity there is no scope issue entry written in the log, so it is difficult to pinpoint. 
 
 
Solution: 
Make sure that in case of a non-extended custom table; 
1) Make sure you created a Journal Input field on the table with the column name 'comments' and if desired       one for 'work_notes'. 
     If these are named differently they are typically not picked up by the journal activity screen segment. 
 
2) Go to sys_db_object (Tables) table and open your custom table in question. 
     In the 'Application Access' tab make sure that Can read and Can update are checked on. 
 
After this it should work as expected. 

In my case both the mobile page and table record were in the same scope - so editing fields and comments worked but the journal activity screen segment will still fail. I suspect that this goes through some kind of global or mobile scoped scripts/functions which is why point 2 is needed. 
 
Kind regards,
Fernando

Hi Fernando,

How do you create a field where the name is "work_notes" or "comments", the system always adds "u_". Is there a way to skip that?