Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Use this event to

Excerpt

Customize default values for Device Language Codes to be used at the Mobile Language page.

...

Using this event, you may override these default values, or implement new default values for other languages ie. if you created a new custom device language pack for your language.Image Removed



Template

    [EventSubscriber(ObjectType::CodeunitCodeunit::"MOB WMS Language", 'OnConvertLanguageCodeToDeviceLanguageCode''', true, true)]
    local procedure OnConvertLanguageCodeToDeviceLanguageCode(_LanguageCode: Code[10]; var _DeviceLanguageCode: Code[20]; var _IsHandled: Boolean)
    begin
    end;

Example

    // [Example] : Suggest device language code 'EN' for Malaysian, and a new custom device language 'FR' for any french language

    [EventSubscriber(ObjectType::CodeunitCodeunit::"MOB WMS Language", 'OnConvertLanguageCodeToDeviceLanguageCode''', true, true)]
    local procedure MyOnConvertLanguageCodeToDeviceLanguageCode(_LanguageCode: Code[10]; var _DeviceLanguageCode: Code[20]; var _IsHandled: Boolean)
    begin
        // Malaysian
        if _LanguageCode = 'MSL' then begin
            _DeviceLanguageCode := 'EN';    // Use english language pack
            _IsHandled := true;
        end;

        // Any french language
        if CopyStr(_LanguageCode, 12'FR' then begin
            _DeviceLanguageCode := 'FR';    // Use some french language pack (not in standard mobile wms, could be developed by a partner)
            _IsHandled := true;
        end;
    end;

Image Added


See also:

Filter by label (Content by label)
showLabelsfalse
showSpacefalse
excerptTypesimple
cqllabel = "bc" and label = "onconvertlanguagecodetodevicelanguagecode"

...