Ridiculous Question, but can I have SAS return the computer's volume level?
To aid in the ability to multitask, I added a datastep that would play the first three notes of hot cross buns after my program would finish, so I could just minimize SAS and do something else while it runs. The thing is, I've had a few complaints from colleagues that they would forget that their volume was up all the way, and would receive a not-so-pleasant surprise when their program would complete. Is there a way to pull in system info, more specifically, the computer volume level, so I can set a threshold in which the music will play or not?
It can be done but is not easy or elegant - especially if you want to distribute the code. If you wanted to do it programmatically you would have to make a call to the relevant windows API DLL from SAS: http://support.sas.com/documentation/cdl/en/hostwin/63285/HTML/default/viewer.htm#overdll.htm As the article says it's not easy (and not guaranteed to work). The DLL you would be interested in is the one below: http://stackoverflow.com/questions/294292/changing-master-volume-level A kludge solution would be to find a 3rd party program that takes command line calls to change the volume: http://www.google.com/search?hl=en&client=firefox-a&hs=Tql&rls=org.mozilla%3Aen-US%3Aofficial&q=windows+change+volume+command+line&aq=f&aqi=&aql=&oq= You could then call that using the 'x' comamnd in SAS. The issue here would be that you would need to install the 3rd party app on every machine that used your volume code. Cheers Rob
I think the short answer is the the SAS SOUND function has two parameters: pitch and duration. Since volume is not a parameter, you can't control the volume without making a call to the OS.
What check to make in exec-missing in PINTOS
What does the kernel do while another process is running
Not able to understand fork() system call clearly?
Process termination by his parent or other processes
Using SIMD instructions in application oriented to multiple platforms and OS
Identify operating system
Do CPU and main memory need drivers to work?
Page frame number vs. Page table entry
About FAT-32 File System
Does a virtual address always translate to a physical one
How does the Virtual Memory Management System determine the backing store location in the disk?
Paged virtual address translation using a linear page table
Condition for deadlock to happen
Upating page table when an entry is evicted from TLB
what is the difference between kernel and system software?
Does a 64 bit runtime run faster than a 32 bit?