Microsoft Office Forums

Go Back   Microsoft Office Forums > >

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #1  
Old 06-26-2020, 06:48 AM
AntCTAZ AntCTAZ is offline Excel VBA - Detect in Coauthoring Mode Windows 10 Excel VBA - Detect in Coauthoring Mode Office 2019
Novice
Excel VBA - Detect in Coauthoring Mode
 
Join Date: Mar 2020
Posts: 2
AntCTAZ is on a distinguished road
Default Excel VBA - Detect in Coauthoring Mode

Hello,



My company utilizes Excel Coauthoring using Office 365 and SharePoint. We also utilize an Excel Add-in full of macros I've created for the team. For one macro, I need it to only be able to be used when not in coauthoring mode. There were two ways I thought I could approach this:

(1) Somehow be able to detect if coauthoring is enabled; or
(2) Count the number of users currently in the coauthored Excel file.

I found and tried the VBA function UserStatus, however reading up on that, it seems to only work in a Shared workbook environment, not coauthored environment - with other people from my organization coauthoring an Excel workbook...

Users = ThisWorkbook.UserStatus
For usernum = 1 To UBound(Users, 1)
MsgBox Users(usernum, 1)
Next

only returned one user (me). I also tried this code for ActiveWorkbook instead of ThisWorkbook.

I did a lot of googling on how to tell if you're in coauthoring or count the number of activeusers, but couldn't find anything helpful.

Any help would be appreciated - Thank you!
Reply With Quote
 



Similar Threads
Thread Thread Starter Forum Replies Last Post
Excel for the Web Tool Bar in Viewing Mode RFeds0320 Excel 0 01-13-2020 01:39 PM
Conrol / detect Latex mode for equation editor George Keeling Word VBA 0 11-05-2019 08:26 AM
Why are Portrait mode JPG Images changed to landscape mode KHH0725 PowerPoint 0 02-22-2017 01:51 PM
Microsoft Office Word Online Text Space is Different in Reading Mode from When it's in Editing Mode darkjanggo Word 1 12-15-2015 05:06 PM
Excel VBA - Detect in Coauthoring Mode Word won't come back to normal mode from proofreading mode prg4hire Word 2 09-25-2010 09:46 AM

Other Forums: Access Forums

All times are GMT -7. The time now is 09:09 AM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, vBulletin Solutions Inc.
Search Engine Optimisation provided by DragonByte SEO (Lite) - vBulletin Mods & Addons Copyright © 2025 DragonByte Technologies Ltd.
MSOfficeForums.com is not affiliated with Microsoft