ArcGIS for Desktop

  • Documentation
  • Pricing
  • Support

  • My Profile
  • Help
  • Sign Out
ArcGIS for Desktop

ArcGIS Online

The mapping platform for your organization

ArcGIS for Desktop

A complete professional GIS

ArcGIS for Server

GIS in your enterprise

ArcGIS for Developers

Tools to build location-aware apps

ArcGIS Solutions

Free template maps and apps for your industry

ArcGIS Marketplace

Get apps and data for your organization

  • Documentation
  • Pricing
  • Support
Esri
  • Sign In
user
  • My Profile
  • Sign Out

Help

  • Home
  • Get Started
  • Map
  • Analyze
  • Manage Data
  • Tools
  • More...

Button class

Properties of the Button class:

PropertyExplanation

checked

This property returns the state of the button, where by default, it is set to False. When this property is set to True, the button appears as though it is pressed.

enabled

This property returns the availability of the button, where by default, it is set to True. When this property is set to False, the button is disabled and unavailable. This property allows you to write logic to test the state of the desktop application in order to disable or enable the button. For example, you might have a button that requires a data layer to be loaded in ArcMap before execution is possible.

Functions of the Button class:

FunctionExplanation

__init__(self)

This is a Python built-in function referred to as the constructor where some initial variables can be defined. By default, the checked and enabled properties of the button are initially set for you.

onClick(self)

This function is called and executes your business logic when the button is clicked.

Related Topics

  • ...Button
Feedback on this topic?

ArcGIS for Desktop

  • Home
  • Documentation
  • Pricing
  • Support

ArcGIS Platform

  • ArcGIS Online
  • ArcGIS for Desktop
  • ArcGIS for Server
  • ArcGIS for Developers
  • ArcGIS Solutions
  • ArcGIS Marketplace

About Esri

  • About Us
  • Careers
  • Insiders Blog
  • User Conference
  • Developer Summit
Esri
© Copyright 2016 Environmental Systems Research Institute, Inc. | Privacy | Legal