官术网_书友最值得收藏!

Developer console exercises

We'll be using the developer console throughout this book, so it is necessary that you become familiar with it. The following are some exercises to help you familiarize with the consoles development features:

  • Create a class: Using the developer console, create a new class and give it the name DevConsoleExample. Ensure that the class compiles without errors.
  • Run a SOQL query: Run a SOQL query from the query editor, that finds all the opportunities that are on the closed/won stage.
  • Execute anonymous: Run the following code block in execute anonymous window:
    System.assert(1, (1/0), 'should throw an assertion error');
  • Log viewing: Having run that snippet of Apex in the developer console, navigate to the Logs tab and open the raw log option of its execution. Does the code throw assertion exception or division by 0 exception?
主站蜘蛛池模板: 永昌县| 泸定县| 木兰县| 宁德市| 邯郸县| 吴堡县| 辽阳市| 梧州市| 栾城县| 湖口县| 宜良县| 临泉县| 荥经县| 峨山| 秭归县| 淮滨县| 祁阳县| 漯河市| 永城市| 武宣县| 龙口市| 延寿县| 华蓥市| 西乡县| 黄冈市| 滨州市| 浦江县| 汽车| 山丹县| 永川市| 东乡县| 台南市| 佛山市| 福建省| 徐水县| 会理县| 沂南县| 吉林市| 高雄县| 平利县| 襄垣县|