See the top rated post in this thread. Click here

Page 1 of 2 12 LastLast
Results 1 to 10 of 20

Thread: XREFSTATE

  1. #1
    Certifiable AUGI Addict ccowgill's Avatar
    Join Date
    2004-08
    Location
    Iron Station, NC
    Posts
    3,198
    Login to Give a bone
    0

    Default XREFSTATE

    does anyone have any experience with the XREFSTATE system variable? I was running process monitor to check on some issue's I've been having, and I noticed that when nothing is going on that AutoCAD is constantly checking the status of the system variable, which is supposed to be stored in the registry (according to help), but apparently doesnt exist. is this a bug?

  2. #2
    Certifiable AUGI Addict
    Join Date
    2015-11
    Location
    Jo'burg SA
    Posts
    4,512
    Login to Give a bone
    0

    Default Re: XREFSTATE

    Not sure about XRefState as a sysvar / environment var. I think it's an internal function, checking the xref entity's last load against the file's modification date. I.e. that's how ACad "knows" that an xref was modified and pops up that message to reload it.

  3. #3
    Administrator rkmcswain's Avatar
    Join Date
    2004-09
    Location
    Earth
    Posts
    9,805
    Login to Give a bone
    0

    Default Re: XREFSTATE

    Quote Originally Posted by irneb View Post
    Not sure about XRefState as a sysvar / environment var. I think it's an internal function, checking the xref entity's last load against the file's modification date. I.e. that's how ACad "knows" that an xref was modified and pops up that message to reload it.
    See also:
    http://forums.autodesk.com/t5/AutoCA...TE/m-p/3467052

    Your theory makes sense, but that registry key does not get created or populated when an xref is updated, so there is no point in checking it every ±0.26 seconds.
    R.K. McSwain | CAD Panacea |

  4. #4
    Certifiable AUGI Addict
    Join Date
    2015-11
    Location
    Jo'burg SA
    Posts
    4,512
    Login to Give a bone
    0

    Default Re: XREFSTATE

    Quote Originally Posted by rkmcswain View Post
    See also:...so there is no point in checking it every ±0.26 seconds.
    Woa! Now that's a lot of CPU expense for no benefit at all! I'd have imagined they'd use some sort of folder/file/registry listener event instead - i.e. similar to what Process Explorer does internally. That way most (if not all) the CPU work only happens when needed, not all the time. And seeing as it doesn't exist in registry, I'm sure it's less efficient than it would be if it did exist. Not sure by how much though.

    I'm sure this is some sort of "error" in AC2013's programming. Does it actually pick-up a change to an xref's state? Sorry I don't have 2013 to test this.

  5. #5
    Administrator BlackBox's Avatar
    Join Date
    2009-11
    Posts
    5,719
    Login to Give a bone
    0

    Default Re: XREFSTATE

    Interesting... You'd think that for any drawing opened in the Editor, the Application would instantiate a new System.IO.FileSystemWatcher() for each ExternalReference Object.

    Here's a non-AutoCAD related example from TechRepublic.

    I am unsure of the performance hit for attempting to read/write to a registry key that doesn't exist, but registry is significantly faster than XML, and on par with, or faster than INI, and Config files (and you don't have to deal with undocumented commands like "REFRESHSHORTCUTNODE" to update the Working Folder in Civil 3D!).

    /vent

    If nobody can help sooner, I have a licensed copy of AutoCAD 2013 at home, if there's anything someone would like for me to check out after hours?
    "How we think determines what we do, and what we do determines what we get."

    Sincpac C3D ~ Autodesk Exchange Apps

    Computer Specs:
    Dell Precision 3660, Core i9-12900K 5.2GHz, 64GB DDR5 RAM, PCIe 4.0 M.2 SSD (RAID 0), 16GB NVIDIA RTX A4000

  6. #6
    Administrator rkmcswain's Avatar
    Join Date
    2004-09
    Location
    Earth
    Posts
    9,805
    Login to Give a bone
    0

    Default Re: XREFSTATE

    Quote Originally Posted by irneb View Post
    Does it actually pick-up a change to an xref's state?
    I'm saying no. I opened a drawing with an xref, edited the reference and saved, switched back to the parent drawing and waited for the notice to appear in the tray. Nothing ever changed in the Process Explorer log. The registry key was not populated or created.

    I had an informal conversation with @AutodeskCare (Autodesk Support) via twitter and they said "Hey so I found out this is a system variable for AutoCAD for Mac."

    That doesn't prove anything. It could be a coincidence that the "missing registry key" just happens to be a SysVar in AcadMac.

    Quote Originally Posted by irneb View Post
    I'm sure this is some sort of "error" in AC2013's programming.
    That would be my guess also, but unfortunately we are all just speculating.....
    Last edited by rkmcswain; 2012-08-08 at 01:13 PM. Reason: clarify
    R.K. McSwain | CAD Panacea |

  7. #7
    Certifiable AUGI Addict
    Join Date
    2015-11
    Location
    Jo'burg SA
    Posts
    4,512
    Login to Give a bone
    0

    Default Re: XREFSTATE

    Quote Originally Posted by rkmcswain View Post
    That would be my guess also, but unfortunately we are all just speculating.....
    Yep, though we're used to ADesk "fixing" that which wasn't broken. And leaving the broken stuff to live on for decades. So it might be "speculation", though experience tells me it's more likely "inference".

  8. #8
    Administrator rkmcswain's Avatar
    Join Date
    2004-09
    Location
    Earth
    Posts
    9,805
    Login to Give a bone
    0

    Default Re: XREFSTATE

    Quote Originally Posted by irneb View Post
    So it might be "speculation".....
    My point was that I wish Adsk had a small team that could look at issues like this and respond in a reasonable amount of time with something like "Yea, it shouldn't be doing that. We'll address that in SP1", or something....anything is better than silence. On the other hand, does anyone who is high enough up at AdSk to figure this out, even know about it? Probably not.

    Meanwhile, here is ±1 second of activity for "Acad.exe"

    promon.png
    R.K. McSwain | CAD Panacea |

  9. #9
    Administrator rkmcswain's Avatar
    Join Date
    2004-09
    Location
    Earth
    Posts
    9,805
    Login to Give a bone
    0

    Default Re: XREFSTATE

    So I manually CREATED these registry entries, and the madness STOPPED. (See attached image)

    (HKEY_LOCAL_MACHINE\SOFTWARE\Autodesk\AutoCAD\Rxx.x\ACAD-xxxx:xxx\Variables\XREFSTATE)


    reg1.png
    Last edited by rkmcswain; 2012-11-01 at 04:43 PM. Reason: add more info
    R.K. McSwain | CAD Panacea |

  10. #10
    Certifiable AUGI Addict
    Join Date
    2015-11
    Location
    Jo'burg SA
    Posts
    4,512
    Login to Give a bone
    0

    Default Re: XREFSTATE

    Thanks RK! So it's litterally an extremely simple fix ... all that's needed is to create a registry key! Now you can't tell me ADesk cannot include such in their next update - they could even do this in a minor hotfix FFS!

Page 1 of 2 12 LastLast

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •