Trond Hoyem
New member
- Local time
- Today, 09:26
- Joined
- Jun 22, 2021
- Messages
- 13
Hi
I am adding some activity logging to my database. For this I have created a public sub in my module "CommonFunctions" called "activity" What it basically does is just to add a record in the activity table with the user name and a short text describing what has been done, like "log in", "deleted article" and so on.
Now, my problem is that in one of my forms (a subform to the article list-form) I am not able to add anything to the activity log. I normally call the public sub like this:
When I do this within the subform, nothing happens in the activity log:
Any idea why?
I am adding some activity logging to my database. For this I have created a public sub in my module "CommonFunctions" called "activity" What it basically does is just to add a record in the activity table with the user name and a short text describing what has been done, like "log in", "deleted article" and so on.
Now, my problem is that in one of my forms (a subform to the article list-form) I am not able to add anything to the activity log. I normally call the public sub like this:
Code:
Call activity("Added new article", Me.txtArticleNumber)
When I do this within the subform, nothing happens in the activity log:
Code:
Private Sub Delete_Click()
If MsgBox("Dette vil slette denne tag for alle artikler. Det er ikke mulig å angre denne handlingen. Vil du fotsette?", vbYesNo + vbExclamation + vbDefaultButton2, "Sletter tags") = vbYes Then
Call CommonFunctions.activity("Deleted article tag.", "")
DoCmd.SetWarnings False
DoCmd.OpenQuery "qryDeleteTag"
Forms!frmEditArticle!sfrmEditTags.Requery
DoCmd.SetWarnings True
Else
Exit Sub
End If
End Sub
Any idea why?