ModelService.FromName Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Locates the ModelItem in the given scope with the given name.
Overloads
FromName(ModelItem, String) |
Locates the ModelItem in the given scope with the given name. |
FromName(ModelItem, String, StringComparison) |
Locates the ModelItem in the given scope with the given name. |
Remarks
Returns null
if the model item could not be located.
FromName(ModelItem, String)
Locates the ModelItem in the given scope with the given name.
public:
System::Activities::Presentation::Model::ModelItem ^ FromName(System::Activities::Presentation::Model::ModelItem ^ scope, System::String ^ name);
public System.Activities.Presentation.Model.ModelItem FromName (System.Activities.Presentation.Model.ModelItem scope, string name);
member this.FromName : System.Activities.Presentation.Model.ModelItem * string -> System.Activities.Presentation.Model.ModelItem
Public Function FromName (scope As ModelItem, name As String) As ModelItem
Parameters
- scope
- ModelItem
An optional scope to provide. If the scope is not provided, Root will be used as a scope. If the scope is provided, the nearest INameScope in the hierarchy will be used to locate the item.
- name
- String
The name to locate.
Returns
A ModelItem whose name matches name
, or null
if no match was found.
Exceptions
name
is null
.
Applies to
FromName(ModelItem, String, StringComparison)
Locates the ModelItem in the given scope with the given name.
public:
abstract System::Activities::Presentation::Model::ModelItem ^ FromName(System::Activities::Presentation::Model::ModelItem ^ scope, System::String ^ name, StringComparison comparison);
public abstract System.Activities.Presentation.Model.ModelItem FromName (System.Activities.Presentation.Model.ModelItem scope, string name, StringComparison comparison);
abstract member FromName : System.Activities.Presentation.Model.ModelItem * string * StringComparison -> System.Activities.Presentation.Model.ModelItem
Public MustOverride Function FromName (scope As ModelItem, name As String, comparison As StringComparison) As ModelItem
Parameters
- scope
- ModelItem
An optional scope to provide. If the scope is not provided, Root will be used as a scope. If the scope is provided, the nearest INameScope in the hierarchy will be used to locate the item.
- name
- String
The name to locate.
- comparison
- StringComparison
Determines how the name should be compared. The default is to compare against ordinal.
Returns
A ModelItem whose name matches name
, or null
if no match was found.
Exceptions
name
is null
.
Applies to
.NET
フィードバック
https://aka.ms/ContentUserFeedback」を参照してください。
以下は間もなく提供いたします。2024 年を通じて、コンテンツのフィードバック メカニズムとして GitHub の issue を段階的に廃止し、新しいフィードバック システムに置き換えます。 詳細については、「フィードバックの送信と表示