Jump to content

Leaderboard

Popular Content

Showing content with the highest reputation on 09/05/2017 in all areas

  1. Here is a fun fact I just discovered: If you want to get the host name of your machine in LabVIEW, there is a function for that: If you want to get the host name using .NET, then you can call the method System.Net.DNS.GetHostName using an invoke node: https://msdn.microsoft.com/en-us/library/system.net.dns.gethostname(v=vs.100).aspx Now the fun part: If you call each of these functions on a Window7 OS they execute fairly quickly: LabVIEW Method: 0.000289767 seconds consistently. .NET Method: 0.182981 first call, 0.000417647 seconds subsequent calls (must be a cache) Next, try the same thing on a Windows Server 2012R2 OS: LabVIEW Method: 4.53384 seconds (WTF LabVIEW???) .NET Method: 0.187395 first call, 0.000350523 seconds subsequent calls (again, must be a cache) So, let's say you are using the machine name at a unique identifier to manage a networked messaging architecture. And as a result, you are often getting the machine name to tag a message you are sending with the sender's 'name'. And you decide to run you system on Windows Server 2012R2 OS. It will *work* but your performace will be down the tubes... Any ideas on what could possibly be causing this? I know I could come up with my own cache of the host name in my code and then access it via FGV or something simular, but that is no excuse for this dismal performance. FWIW, there is yet another way to do this: https://msdn.microsoft.com/en-us/library/system.environment.machinename.aspx execution time: 7.91631E-5 seconds on Both OSes. This leads me to the fact that a lot of the advice out there on this topic may need updating. http://digital.ni.com/public.nsf/allkb/4B3877DB13370AA586257542003945A9 https://decibel.ni.com/content/docs/DOC-3917 http://forums.ni.com/t5/LabVIEW/Get-Computer-Name/td-p/101433 -John
    1 point
  2. Although strict-typing is a valid reason to argue for separate User Events for each “message”, the freedom to Register selectively for messages is something that can be achieved in other ways. The “ObserverRegister” in “Messenger Library” allows selective registration. Also the flip side of the advantages of strict-typing are the advantages of being able to write generic code.
    1 point
  3. Now supports recursive cluster elements for selection. SetClusterElement.zip
    1 point
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.