Book Image

Oracle APEX Cookbook : Second Edition

Book Image

Oracle APEX Cookbook : Second Edition

Overview of this book

Table of Contents (21 chapters)
Oracle APEX Cookbook Second Edition
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
Index

Setting default item settings with apex_ui_default_update


When you create a form or a report, most of the time this is done with the help of a wizard. It is very easy for the most common things, but if you want a different width of a text item, other than the default width, you have to do this afterwards. When you have a lot of items on your screen this could be very cumbersome. In this recipe, we will show you how to set the default width of columns with the APEX_UI_DEFAULT_UPDATE.UPD_ITEM_DISPLAY_WIDTH procedure. We will set the default width of column EVENT in table APP_EVENTS to 200.

Getting ready

Before you can use this function, the table needs to be included in the APEX dictionary. The view APEX_UI_DEFAULTS_COLUMNS holds the columns and their default width. You can add your table to this dictionary view by doing the following:

  1. In APEX, go to SQL workshop.

  2. Click on Utilities.

  3. Click on User interface defaults.

  4. Click on the Manage table dictionary button.

  5. Click on the Synchronize button on...