PowerApps Audit Logging

Поделиться
HTML-код
  • Опубликовано: 2 май 2018
  • In this video, you will learn how to track when users modify your data with PowerApps. We do this using the User() and Now() function combined with OnSuccess. Not terribly complicated but an effective solution for tracking that info you need.
    Video on the User() function
    • PowerApps User Functio...
    Video on Patch
    • PowerApps Patch Function
    If you need further assistance feel free to contact www.PowerApps911.com
  • НаукаНаука

Комментарии • 64

  • @adalbertoabade
    @adalbertoabade 3 года назад +1

    always saving me with your videos. Thanks!

  • @altino91255268
    @altino91255268 3 года назад +1

    Great video Shane !! Without a doubt your classes are the best ...
    I thought of another way too, we could have put Now and the User function inside the card and made it invisible, this way whenever they edit the form itself it would collect the data.

  • @MrGregMelson
    @MrGregMelson 5 лет назад +1

    Thank you for sharing Shane :)

  • @wesleyvanderblom
    @wesleyvanderblom 5 лет назад +2

    Hi Shane, thanks, great video. When working with CDS, you can put the "user().FullName" as a default value in the field (a field like "EditedBy" of the entity). Set the field to visible 'false' and it works great, and automatically (and the user can't put false input into the field). A entity in CDS has by default already fields as LastModifiedBy (system user code) and LastModifiedDateTime. The last one (DateTime) you can use as the (in the video) mentioned 'when' field to audit.

    • @ShanesCows
      @ShanesCows  5 лет назад

      Thanks

    • @Thor_Underdunk_Caballerial
      @Thor_Underdunk_Caballerial 2 года назад

      Great tip. With my limited knowledge I tried to replicate this with SharePoint as a backend, but PowerApps didn't like "user().FullName" as the default value of the datacard and threw up "invocation of unknown or unsupported function."

  • @MrAmitav2000
    @MrAmitav2000 2 года назад

    Hi Shane, It would be helpful if you could post some videos on enable/disable "Audit changes to its data" feature under settings in a custom entity. Where are these logging data saved? Can I access these logs in my canvas App? I understand Auditing feature has to be enabled from Admin center for an environment.

  • @meniteshgoyal
    @meniteshgoyal 2 года назад

    Hi Shane,
    Thanks for such an informative video. Could you please provide me with steps for the following case --> Get data from Table A and write final form data in Table B?

  • @JonathanExcels
    @JonathanExcels 6 лет назад +3

    I was really excited when I saw the title of this video because it sounded like exactly what I am trying to do and your videos are easy to understand. I guess my need is slightly different. I have a SP list and I have versioning turned on so I can track each item as it changes. When I look at the history of an item is has all the detail I need. I just can’t figure out how to get that history to show in my form. Example, when I open a list item I would like to view who upload the attachment and then who subsequently approved it right on the power apps form. Is there a way to do this?

    • @ShanesCows
      @ShanesCows  6 лет назад +2

      Not that I know of. PowerApps doesn’t know about those properties. I am thinking custom connector. The client side object model knows what you want. Maybe Flow can help? Just not sure.

    • @ShanesCows
      @ShanesCows  6 лет назад

      In my head something similar to this is your answer. zpr.io/nFiYF

  • @martinwhite2369
    @martinwhite2369 Год назад +1

    Thanks for your videos Shane. Is there anyway to bring Dataverse Audit data into the app? (Assuming of course that auditing is enabled in that organisation/app/environment)

    • @ShanesCows
      @ShanesCows  Год назад

      I don't know Martin, I have never tried. 🤔 My best guess would be to look for the table and query it directly but i am just guessing.

  • @davidflockton4296
    @davidflockton4296 4 года назад +1

    Hi Shane, your videos are great and have helped me so much as a total newbie to create my own app!! I have followed this video and have it all working great, but wondered how I would go about changing user().fullname to show the data from a field in my SharePoint list called PreferredName instead? I have used this field in the browse screen (gallery) to show the users name. Thanks

  • @webdevguy_
    @webdevguy_ 6 лет назад +1

    Brilliant! Thanks!

    • @ShanesCows
      @ShanesCows  6 лет назад

      Glad you liked it. It seems so simple after the fact had a hard time describing it.

    • @webdevguy_
      @webdevguy_ 6 лет назад +1

      It was perfect! Keep up the good work!

  • @emanuelpinto7394
    @emanuelpinto7394 5 лет назад +1

    Hy Shane! It always takes me forever to Patch something on my apps. I was wondering if I could do this: get the correct code into de "Update" of mais EditBy and EditWhen DataCards, on the Form, and then make those DataCards not visible. Do you think that's gonna be a solution as good? And if I wanted a change history, so, not only the last editor, but who edited and when, from the record creation. What would you suggest??

    • @ShanesCows
      @ShanesCows  5 лет назад

      Yes, I use hidden cards all of the time. :)

  • @gandlaveeresh7232
    @gandlaveeresh7232 Год назад

    i am not getting the user and time details into the share point list as well as into powerapps gallery can you please help me with this?

  • @sidneyerickson5951
    @sidneyerickson5951 6 лет назад +2

    You can also have PowerApps fill in the hidden fields while the user is creating or editing the form, then use the SubmitForm command to save the UserName and Time stamp. In this way, you don't have to use Patch. I am not sure if there is any benefit either way, probably just a preference? Great Video by the way!

    • @ShanesCows
      @ShanesCows  6 лет назад +1

      Yup. Good point I sometimes think too much on best way to teach it vs best way to implement it. 😻

    • @sidneyerickson5951
      @sidneyerickson5951 6 лет назад +2

      Well, keep it up, cause you have the best way to teach down. I have learned more from your videos than any other source!

  • @gauravghai06
    @gauravghai06 2 года назад +1

    Thanks Shane for producing such a helpful tutorial. I have implemented the same to record Username (under modified by), time (modified at) and now trying my hands on created by and created on. My database is in SQL which is integrated with Powerapps. I managed to create created on field in SQL itself when a new record is created but now I am struggling to pass on username for created by using power apps as it has to be fixed. Would you be able to share some light on this?

    • @ShanesCows
      @ShanesCows  2 года назад +1

      You can use the User() function to get info about the logged in user. ruclips.net/video/FpXrF5NDZbI/видео.html

    • @gauravghai06
      @gauravghai06 2 года назад

      @@ShanesCows thanks! I am using the same to capture modified by. I am struggling to build the logic around Created by as everytime a new user logs in, it should only patch/update the modified by field but not the created by.

  • @zildjiandames7741
    @zildjiandames7741 5 лет назад +1

    Hi Shane! Great video as usual, good to know that we can audit, can we also record what was changed?

    • @ShanesCows
      @ShanesCows  5 лет назад

      You would have to add the logic yourself.

    • @rengon9611
      @rengon9611 3 года назад

      @@ShanesCows how would you add this logic? Any examples? I’m new to power apps. Thank you!

  • @bopraYT
    @bopraYT 6 лет назад +1

    Great! +1 subscriber :) . Could you do a video covering how do to add User Action(eg. edit, new, delete), OldValue and NewValue in a separate table?

    • @ShanesCows
      @ShanesCows  6 лет назад +1

      Try this video from my buddy Vivek m.ruclips.net/video/OM-rlhKJFTA/видео.html

    • @bopraYT
      @bopraYT 6 лет назад

      Thanks!

  • @kairbekshagiyev6628
    @kairbekshagiyev6628 2 года назад +2

    Thanks for video Shane! How can we use SharePoint List's Version History in PowerApps? Please share with us if you know)

    • @ShanesCows
      @ShanesCows  2 года назад

      You would have to use the rest api to call it. I have not done it before. This video introduces the concept ruclips.net/video/mVOtFWC6Q8E/видео.html

  • @fredbarnes196
    @fredbarnes196 6 месяцев назад

    This is nice and clean but in many cases you will have a blue house and then later you paint it red, then green then yellow. You want everyone to get credit for their work, not the last person to get all the credit. How do you log all of your "key updates" and make them available to your form

  • @santiago46
    @santiago46 5 лет назад +1

    Hello Shane, Do you have a video on how to use 0ffice365user function for user authentication? I need to create a login screen with the sign in button. what do I implement in the sign-in button to make the authentication happen... Thanks for your response!

    • @ShanesCows
      @ShanesCows  5 лет назад

      Hey James. Everyone has to authenticate ton
      Open the app so I don’t think you need a login screen?

  • @kyrstincote637
    @kyrstincote637 9 месяцев назад +1

    Do you have suggestions for when a Network error occurs on this function? :(

    • @ShanesCows
      @ShanesCows  9 месяцев назад

      Depends on when you are getting it. Most common reason I see it is a bad patch statement because you are not sending the data that it wants so it gets confused.

  • @tharindlaksh
    @tharindlaksh 5 лет назад +1

    Hi Shane, I have a problem that i want to save current time to one of the SharePoint field when im saving some other data. Im using patch function for this and im getting error on the equation of update portion. Is there any way to save current date in to SharePoint field using patch.

    • @ShanesCows
      @ShanesCows  5 лет назад

      You can use Today() function to write the current date.

    • @tharindlaksh
      @tharindlaksh 5 лет назад +1

      @@ShanesCows Hi Shane. Thanks for the reply.. it seems like i have got syntax incorrect earlier.. Today() work as charm.. :)

  • @jdguyz
    @jdguyz Год назад +1

    how do i create event log in sharepoint to update status as start, pause or finish when a button is clicked

    • @ShanesCows
      @ShanesCows  Год назад

      Create a SharePoint list with the columns you want to track. Have the button do whatever the button normal does and then Patch(YourList,Defaults(YourList), {YourColumns: "Your Message"})

  • @brightonalbert3237
    @brightonalbert3237 4 года назад +1

    thanks can i have multiple tracking of data changes i.e. if a data set was edited by who and at what time

  • @eulama1
    @eulama1 4 года назад +1

    Good Morning!
    I'm still in progress, I like it a lot, but in Spain it doesn't work to concatenate the functions where you use a comma. I try to put something but it doesn't work for me.
    Patch (Products; EditForm1.LastSubmit; {EditeBy: User (). FullName; EditeWhen: Now ()})
    I can't add the back () function
    What I can do?
    thank you!

    • @ShanesCows
      @ShanesCows  4 года назад +1

      When you see me use a ; you should use a ;; 😀

    • @eulama1
      @eulama1 3 года назад

      @@ShanesCows thanks

  • @messilois5941
    @messilois5941 4 года назад +1

    Hi, we are using one account, but i want to know who edit the record. Can i add a login screen with user name and password, then if the person who login edited the record, the re ord will show who edit it. If yes, how to add the edit by in the edit form which are usingnthe login user name.

    • @ShanesCows
      @ShanesCows  3 года назад

      You could make people "login" inside your app. I think that would be against the licenscing though so be careful.

  • @anantnd393
    @anantnd393 3 года назад +1

    Can I do the same with the excel file stored on blob?

    • @ShanesCows
      @ShanesCows  3 года назад

      Excel can only be a data source if it is in OneDrive for Business.

  • @rolando2742
    @rolando2742 4 года назад +1

    Hello,
    Somebody knows how to get the users ip address in Powerapps.
    Thanks.

    • @ShanesCows
      @ShanesCows  4 года назад

      Not possible today. Sorry

  • @deepanrajs2209
    @deepanrajs2209 5 лет назад +1

    Hai Shane,
    How do I find logged in users ???

    • @ShanesCows
      @ShanesCows  5 лет назад

      This video with ther User() function. ruclips.net/video/FpXrF5NDZbI/видео.html