System.GetUrl(ClientType, Text, ObjectType, Integer, RecordRef [, Boolean]) Method
Version: Available or changed with runtime version 1.0.
Generates a URL for the specified client target that is based on the configuration of the server instance. If the code runs in a multitenant deployment architecture, the generated URL will automatically apply to the tenant ID of the current user.
Syntax
String := System.GetUrl(ClientType: ClientType, Company: Text, ObjectType: ObjectType, ObjectId: Integer, RecordRef: RecordRef [, UseFilters: Boolean])
Note
This method can be invoked without specifying the data type name.
Parameters
ClientType
Type: ClientType
Specifies the client that you want to generate the URL for. This parameter is required. If you want to generate a URL that depends on the client that the user is accessing the URL from, choose Current. The following table describes the options.> A runtime error occurs if the ClientType is set to SOAP or OData but the specified object type and ID has not been published as a web service.
Company
Type: Text
Specifies the company that the URL must contain. If you do not specify a company, the URL will run in the user’s current company.
ObjectType
Type: ObjectType
Value: Table, Page, Report, Codeunit, Query, or XmlPort. Specifies the object type that the URL must open. If you specify an object type, you must also specify an object ID in the ObjectId parameter. Otherwise, the user will see a runtime error. If you set the ObjectType parameter to Page, you can also specify a record variable in the Record parameter.
ObjectId
Type: Integer
Specifies the ID of the specified object type that the URL must open.
RecordRef
Type: RecordRef
Specifies the RecordRef variable that specifies which record to open.
[Optional] UseFilters
Type: Boolean
Specifies whether to include filters that are defined on the object as a text string in the URL.
Return Value
String
Type: Text
See Also
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for