微信公众号搜"智元新知"关注
微信扫一扫可直接关注哦!

C#MVC视图获取modle实体类中的参数

<p style="line-height:21px;font-family:Verdana,Geneva,Arial,Helvetica,sans-serif;font-size:14px;">
在Modle 创建专辑类 Album,它有两个属性:Title 和 Genre .


<div class="cnblogs_code" style="border:1px solid rgb(204,204,204);overflow:auto;font-family:'Courier New' !important;background-color:rgb(245,245,245);">
<pre style="font-family:'Courier New' !important;"><span style="color:rgb(0,255);line-height:1.5 !important;">public <span style="color:rgb(0,255);line-height:1.5 !important;">class Album
{
<span style="color:rgb(0,255);line-height:1.5 !important;">string Title { <span style="color:rgb(0,255);line-height:1.5 !important;">get; <span style="color:rgb(0,255);line-height:1.5 !important;">set; }
<span style="color:rgb(0,255);line-height:1.5 !important;">public Genre Genre { <span style="color:rgb(0,255);line-height:1.5 !important;">set; }
}

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。

相关推荐