You are on page 1of 22

Customization Tools:

User-Defined Values
SAP Business One
Version 10.0

PUBLIC
Objectives

Objectives:
 Add user-defined values to fields in forms and documents to
assist and expedite data entry by end users:
 Add a list of values as user-defined values
 Use a query as user-defined values

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 2


Business Scenario

 The company wants to have the delivery date automatically calculated in sales orders,
so that the salesperson does not have to manually enter the date. In the business
process, the delivery date is not significant since orders are dispatched immediately.
 The salesperson needs the ability to instantly view a customer’s account balance when
processing a new sales order over the phone.

Solution: These requirements can be implemented using user-defined values.

Incoming
Sales Order Delivery A\R Invoice
Payment

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 3


User-Defined Values
Sales Order

 User-defined values (UDVs) can


be added to any editable field in
a document or form
 UDVs added at the row level
apply to each row
 UDVs can be in the form of:
 List of values
 User query

UDVs
UDVs can
can bebe added
added toto any
any
editable
editable field
field at
at the
the header
header or
or
row
row level,
level, and
and toto user-defined
user-defined
fields
fields

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 4


Indicator for User-Defined Values

View  Pickers Display  User-Defined Values

 Magnifying glass icon indicates that user-defined values have been added to field

 Toggle on and off from View  Pickers Display  User-Defined Values

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 5


Adding User-Defined Values

 To add user-defined values to a


field, select the field in the
document or form and:
Alt+Shift+F2  Press Alt+Shift+F2, or
 Choose Tools >
Customization Tools >
User-Defined Values -
Setup
 General authorization required –
“User-Defined Values – Setup”

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 6


Removing User-Defined Values

To remove user-defined values from


field:
 Select the field and press
Alt+Shift+F2
Alt+Shift+F2
 In the setup window, choose
Without Search in User-Defined
Values

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 7


List of Values

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 8


Adding a List of Values

Choose the option Search in Existing User-Defined Values

 Make
Make sure
sure the
the
value
value entered
entered
does
does not
not exceed
exceed
the
the field
field length
length
Alt+Shift+F2

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 9


Adding a List of Values (cont.)

 To
To open
open the
the list
list of
of values,
values,
the
the user
user can
can select
select the
the
magnifying
magnifying glass
glass in in the
the
field,
field, or
or can
can select
select thethe field
field
and
and press
press Shift+F2
Shift+F2

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 10


Marketing Documents and UDVs

 User-defined values are not inherited by other document types, therefore you need to
add them to each document type as required
 The value entered into a field with user-defined values is transferred to target
document using Copy To/Copy
Sales Order From

User-Defined Values - Setup

Value
Value entered
entered in
in field
field using
using UDVs
UDVs
is
is transferred
transferred to
to target
target document
document
using
using Copy
Copy to/Copy
to/Copy From
From

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 11


Attaching a User Query

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 12


Adding a Query to a Field

Choose the option Search in Existing User-Defined Values According to Saved Query

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 13


Adding a Query to a Field (cont.)

Choose the option Search in Existing User-Defined Values According to Saved Query

Saved
Saved user
user query
query
Example:
Example:
SELECT
SELECT ADD_DAYS
ADD_DAYS (($[ORDR."DocDate".DATE]),
(($[ORDR."DocDate".DATE]),
7)
7) FROM
FROM DUMMY
DUMMY

 When
When the
the query
query runs
runs
the
the result
result is
is
populated
populated in in the
the field
field

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 14


Adding a Query to a Field (cont.)

You can decide how the query will be triggered to run:


 If you do not select Auto Refresh When Field Changes,
the user must select the magnifying glass icon or select
the fields and press Shift+F2
 If you select Auto Refresh When Field Changes, the
query will run automatically with no user involvement

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 15


Auto Refresh

 To have the query run automatically you select a


depended fields
 Select up to 5 dependent fields to trigger the
query to run
 When the depended field is selected or changed,
Delivery Date the query runs
 In marketing documents, the customer or vendor
code is often selected as the dependent field
 In this example we also select Posting Date.

Select
Select dependent
dependent field
field

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 16


Auto Refresh – Refresh Frequency

 Auto Refresh When Field Changes  Display


Display Saved
Saved User-Defined
User-Defined Values
Values (default)
(default) ––
query
query runs
runs once
once then
then retains
retains the
the result
result in
in the
the field
field
 Refresh
Refresh Regularly
Regularly –– query
query runs
runs each
each time
time the
the
dependent
dependent field
field changes
changes oror is
is selected
selected inin aa
document
document

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 17


Auto Refresh - Example

Sales Order
 Query
Query is
is added
added to
to user-
user-
defined
defined field
field Account
Account
Balance
Balance
 Customer
Customer code
code isis set
set as
as the
the
dependent
dependent field
field
 Auto
Auto Refresh
Refresh is
is selected
selected
with
with Refresh
Refresh Regularly
Regularly
Result:
Result:
 Query
Query will
will run
run when
when user
user
selects
selects aa business
business partner
partner
code
code in
in aa new
new sales
sales order
order
 Query
Query will
will also
also run
run ifif user
user
browses
browses through
through old
old
documents
documents
© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 18
Auto Refresh on Row-level Fields
 For a query added to a header field, you can
only select another header field as a
dependent field

 For a query added to a row-level field, you


can select either a header field or a row-level
field as a dependent field:
 Choose When Field Changes if you want
to use a header field as the dependent
field
 Choose When Exiting Altered Column or
When Column Value Changes if you want
to use another row field as the dependent
field
 If you need the query to run when item is
selected, always use one of the
dependent field to be item No. Or
Description
© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 19
Auto Refresh on Row-level Fields Options

 For a query added to a row-level field,


dependent on other row fields, select
between the two options:

 Choose When Exiting Altered Column to


trigger the UDV to run based on editable
fields
 Choose When Column Value Changes to
trigger the UDV to run based on all
availble fields in the row, including non-
editable fields such as tax amount, gross
profit amount and more. 

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 20


User-Defined Values: Key Points

Key points from this topic:


 User-defined values can assist users with data entry by using a list of values or a query to
populate a field value
 You can add UDVs to editable header and row-level fields, and to user-defined fields. To
add UDVs, select the field and press Alt+Shift+F2
 Magnifying glass indicator shows if UDVs exist for a field – View > Pickers Display
 User can open list of values or run query manually by selecting the indicator or pressing
Shift+F2 in the field
 To set a query to run automatically, use auto refresh and select dependent fields. Then
select either:
 Refresh Regularly – query will run each time the dependent field changes or is
selected
 Display Saved User-Defined Values – query runs once then retains the result in the
field
 Queries should be written to reference the active window

© 2020 SAP SE or an SAP affiliate company. All rights reserved. ǀ PUBLIC 21


Follow us

www.sap.com/contactsap

© 2020 SAP SE or an SAP affiliate company. All rights reserved.


No part of this publication may be reproduced or transmitted in any form or for any purpose without the express permission of
SAP SE or an SAP affiliate company.
The information contained herein may be changed without prior notice. Some software products marketed by SAP SE and its
distributors contain proprietary software components of other software vendors. National product specifications may vary.
These materials are provided by SAP SE or an SAP affiliate company for informational purposes only, without representation or
warranty of any kind, and SAP or its affiliated companies shall not be liable for errors or omissions with respect to the materials.
The only warranties for SAP or SAP affiliate company products and services are those that are set forth in the express warranty
statements accompanying such products and services, if any. Nothing herein should be construed as constituting an additional
warranty.
In particular, SAP SE or its affiliated companies have no obligation to pursue any course of business outlined in this document or
any related presentation, or to develop or release any functionality mentioned therein. This document, or any related presentation,
and SAP SE’s or its affiliated companies’ strategy and possible future developments, products, and/or platforms, directions, and
functionality are all subject to change and may be changed by SAP SE or its affiliated companies at any time for any reason
without notice. The information in this document is not a commitment, promise, or legal obligation to deliver any material, code, or
functionality. All forward-looking statements are subject to various risks and uncertainties that could cause actual results to differ
materially from expectations. Readers are cautioned not to place undue reliance on these forward-looking statements, and they
should not be relied upon in making purchasing decisions.
SAP and other SAP products and services mentioned herein as well as their respective logos are trademarks or registered
trademarks of SAP SE (or an SAP affiliate company) in Germany and other countries. All other product and service names
mentioned are the trademarks of their respective companies.
See www.sap.com/copyright for additional trademark information and notices.

You might also like