Can you secretly show when your workbook is on someone else's computer when they're sharing their screen with you?

rizzo93

Active Member
Joined
Jan 22, 2015
Messages
303
Office Version
  1. 365
I want to detect when a workbook of mine is being shown on my computer as opposed to someone else's. Let me explain.

If someone shares their screen on say, Microsoft Teams, and shows a workbook I've created (or worse, is pretending that they are, but has modified the data), I want there to be a visual way that only I know about that shows it's not on my computer. So if someone else happens to take a screenshot and passes it along, I can protect myself by showing it's not my file.

Sound paranoid? Perhaps, but I want to leave no doubt that the data I send to people is not being manipulated.

To this end, I was thinking of creating a connection to an internal server that, if a connection is made (i.e. it's really me) then a character or color will subtly indicate that on a worksheet. But if Excel cannot make the connection (i.e., it's on someone else's computer outside of my company), then the character or color will change to something else.

Again, this all needs to be behind the scenes and not make users aware this protection is in place, meaning no logins are required, no password-protection, no error messages to say a connection could not be found, etc. I'm not looking to protect the file as much as I am trying to identify when the file has been manipulated.

Your thoughts are welcome. :)
 

Excel Facts

VLOOKUP to Left?
Use =VLOOKUP(A2,CHOOSE({1,2},$Z$1:$Z$99,$Y$1:$Y$99),2,False) to lookup Y values to left of Z values.
One method :

Create code in your workbook that references a tiny text file located somewhere on your computer other than the location of your workbook.
If the tiny text file is there - nothing occurs. If the text file is absent, then have additional code that creates the "character or color" you
previously mentioned.
 
Upvote 0
Solution
One method :

Create code in your workbook that references a tiny text file located somewhere on your computer other than the location of your workbook.
If the tiny text file is there - nothing occurs. If the text file is absent, then have additional code that creates the "character or color" you
previously mentioned.
Thanks, Logit. Sounds simple enough. I'll give it a go.
 
Upvote 0
you could try something like this:
VBA Code:
Private Sub Worksheet_Change(ByVal Target As Range)
Application.EnableEvents = False
 With Worksheets("Sheet1")
 Aw = .Columns("A").ColumnWidth
 If Application.UserName = "your username" Then
 .Columns("B").ColumnWidth = Aw * 0.9
 .Columns("C").ColumnWidth = Aw * 1.1
 Else
 .Columns("B").ColumnWidth = Aw * 1.1
 .Columns("C").ColumnWidth = Aw * 0.9
 End If
 End With

Application.EnableEvents = True

End Sub
 
Upvote 0
One method :

Create code in your workbook that references a tiny text file located somewhere on your computer other than the location of your workbook.
If the tiny text file is there - nothing occurs. If the text file is absent, then have additional code that creates the "character or color" you
previously mentioned.
Yep, this did the trick!
 
Upvote 0
Great ! Glad you have an answer.
 
Upvote 0
you could try something like this:
VBA Code:
Private Sub Worksheet_Change(ByVal Target As Range)
Application.EnableEvents = False
With Worksheets("Sheet1")
Aw = .Columns("A").ColumnWidth
If Application.UserName = "your username" Then
.Columns("B").ColumnWidth = Aw * 0.9
.Columns("C").ColumnWidth = Aw * 1.1
Else
.Columns("B").ColumnWidth = Aw * 1.1
.Columns("C").ColumnWidth = Aw * 0.9
End If
End With

Application.EnableEvents = True

End Sub
Thanks, offthelip! I like your idea, too. But I couldn't get it to work.

I changed your code to simply show a msgbox indicating if the username matched what I made it equal to. I also made it execute when I opened the file (I used my real name, of course ;) ). It didn't work though.

VBA Code:
Private Sub Workbook_Open(ByVal Target As Range)
Application.EnableEvents = False
    With Worksheets("Dashboard")
'        Aw = .Columns("A").ColumnWidth
            If Application.UserName = "Doe, John" Then
            MsgBox "yes it's you"
'            .Columns("B").ColumnWidth = Aw * 0.9
'            .Columns("C").ColumnWidth = Aw * 1.1
            Else
            MsgBox "not you"
'            .Columns("B").ColumnWidth = Aw * 1.1
'            .Columns("C").ColumnWidth = Aw * 0.9
            End If
    End With
    Application.EnableEvents = True
End Sub

What am I missing?
 
Upvote 0

Forum statistics

Threads
1,223,911
Messages
6,175,337
Members
452,637
Latest member
Ezio2866

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top