gis_set_error.py 741 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. """!
  2. @package gis_set_error.py
  3. GRASS start-up screen error message.
  4. (C) 2010 by the GRASS Development Team
  5. This program is free software under the GNU General Public License
  6. (>=v2). Read the file COPYING that comes with GRASS for details.
  7. @author Martin Landa <landa.martin gmail.com>
  8. """
  9. import os
  10. import sys
  11. import gui_modules.globalvar as globalvar
  12. import wx
  13. def main():
  14. app = wx.PySimpleApp()
  15. if len(sys.argv) == 1:
  16. msg = "Unknown reason"
  17. else:
  18. msg = ''
  19. for m in sys.argv[1:]:
  20. msg += m
  21. wx.MessageBox(caption = "Error",
  22. message = msg,
  23. style = wx.OK | wx.ICON_ERROR)
  24. app.MainLoop()
  25. if __name__ == "__main__":
  26. main()