[Pharo-project] NativeBoost Win32 Examples

Torsten Bergmann astares at gmx.de
Sat Nov 10 22:20:12 CET 2012

Hi Igor,

thanks for adding me to the NativeBoost repo. I uploaded some
basic samples for Win32 and adopted the config.

In Pharo 2.0 one can load latest stable right from the world menu
"Tools" -> ConfigurationBrowser" -> "NativeBoost"

Here are some samples people can now play with:

1. Set the pharo window title

   NBWin32Window getFocus setWindowText: 'Set Pharo window title'

2. Access environment variables:

   NBWin32Shell getComputerName
   NBWin32Shell getUserName
   NBWin32Shell getWindowsDirectory
   NBWin32Shell getNumberOfProcessors

3. Access to control panel applets 

   NBWin32Shell showODBCSettings
   NBWin32Shell showControlPanel

4. Open web pages, files, documents, ...

   NBWin32Shell shellBrowse: 'http://www.pharo-project.org'
   NBWin32Shell shellExplore: 'c:\'
   NBWin32Shell shellOpen: 'c:\pharo.pdf'

5. Lock workstation

   NBWin32Shell lockWorkstation

6. Sends a string to the debugger for display:

   NBWin32Shell outputDebugString: 'Trace me' 

   These outputs can be viewed with dbmon.exe from Microsoft
   or DebugView

Have fun!


More information about the Pharo-project mailing list