CoreStrings.EntityRequiresKey(Object) 方法
定義
重要
部分資訊涉及發行前產品,在發行之前可能會有大幅修改。 Microsoft 對此處提供的資訊,不做任何明確或隱含的瑕疵擔保。
實體類型 '{entityType}' 需要定義一個主鍵。 如果你打算使用無鍵實體類型,請在「OnModelCreating」中呼叫「HasNoKey」。 欲了解更多無鑰匙實體類型的資訊,請參見 https://go.microsoft.com/fwlink/?linkid=2141943。
public static string EntityRequiresKey(object? entityType);
public static string EntityRequiresKey(object entityType);
static member EntityRequiresKey : obj -> string
Public Shared Function EntityRequiresKey (entityType As Object) As String
參數
- entityType
- Object