Click here to Skip to main content
15,437,521 members
Home / Discussions / ASP.NET
   

ASP.NET

 
QuestionUse Active Directory for authentication Pin
Joseline Riker2-Dec-21 5:50
MemberJoseline Riker2-Dec-21 5:50 
QuestionIs this data annotation correct for date and time? Pin
Alex Dunlop25-Nov-21 22:26
MemberAlex Dunlop25-Nov-21 22:26 
AnswerRe: Is this data annotation correct for date and time? Pin
Richard MacCutchan26-Nov-21 0:02
mveRichard MacCutchan26-Nov-21 0:02 
GeneralRe: Is this data annotation correct for date and time? Pin
Alex Dunlop26-Nov-21 0:28
MemberAlex Dunlop26-Nov-21 0:28 
GeneralRe: Is this data annotation correct for date and time? Pin
Richard MacCutchan26-Nov-21 0:39
mveRichard MacCutchan26-Nov-21 0:39 
GeneralRe: Is this data annotation correct for date and time? Pin
Alex Dunlop26-Nov-21 0:45
MemberAlex Dunlop26-Nov-21 0:45 
GeneralRe: Is this data annotation correct for date and time? Pin
Richard MacCutchan26-Nov-21 0:56
mveRichard MacCutchan26-Nov-21 0:56 
AnswerRe: Is this data annotation correct for date and time? Pin
jkirkerx28-Nov-21 9:12
professionaljkirkerx28-Nov-21 9:12 
I get what you want to do here, which is to create models to match your database perhaps, so each table has a matching model. But your over thinking this, and don't need that much detail. Keep it simple and flexible at first, and only add detail when needed. For some reason Microsoft likes to capitalize the first letter, and will nag you later about the first letter being lower case.

This is an example model in c# to match a DB table or collection. Your example is a like a model used to present data in the view. Even when presenting data in the view, I would keep that simple as well. You want to craft models as simple as possible, and try to make them as reusable as possible to keep models down in count.
public class PORTFOLIOS
    {
        // standard BsonId generated by MongoDb 

        public string Id { get; set; }
        public DateTime TimeStamp { get; set; }        
        public string Name { get; set; }
        public string Description { get; set; }
        public string CreatedBy { get; set; }
        public string UpdatedBy { get; set; }
        public DateTime UpdateDate { get; set; }
        public string HTML { get; set; }
        public string AvatarB64 { get; set; }
        public string AvatarName { get; set; }
        public string AvatarType { get; set; }
        public string AvatarUrl { get; set; }
        public int AvatarX { get; set; }
        public int AvatarY { get; set; }        
    }
If it ain't broke don't fix it
Discover my world at jkirkerx.com

QuestionCannot establish local connection to SQL SERVER Pin
Alex Dunlop24-Nov-21 23:15
MemberAlex Dunlop24-Nov-21 23:15 
QuestionRe: Cannot establish local connection to SQL SERVER Pin
Richard MacCutchan25-Nov-21 0:37
mveRichard MacCutchan25-Nov-21 0:37 
AnswerRe: Cannot establish local connection to SQL SERVER Pin
Richard Deeming25-Nov-21 1:15
mveRichard Deeming25-Nov-21 1:15 
GeneralRe: Cannot establish local connection to SQL SERVER Pin
Richard MacCutchan25-Nov-21 1:18
mveRichard MacCutchan25-Nov-21 1:18 
AnswerRe: Cannot establish local connection to SQL SERVER Pin
Richard Deeming25-Nov-21 1:19
mveRichard Deeming25-Nov-21 1:19 
AnswerRe: Cannot establish local connection to SQL SERVER Pin
jsc4225-Nov-21 2:56
professionaljsc4225-Nov-21 2:56 
GeneralRe: Cannot establish local connection to SQL SERVER Pin
Richard Deeming25-Nov-21 3:33
mveRichard Deeming25-Nov-21 3:33 
AnswerRe: Cannot establish local connection to SQL SERVER Pin
Alex Dunlop25-Nov-21 9:02
MemberAlex Dunlop25-Nov-21 9:02 
Questioncall a server side Powershell script? Pin
Joseline Riker19-Nov-21 6:44
MemberJoseline Riker19-Nov-21 6:44 
AnswerRe: call a server side Powershell script? Pin
Richard Deeming21-Nov-21 22:52
mveRichard Deeming21-Nov-21 22:52 
GeneralRe: call a server side Powershell script? Pin
Joseline Riker3-Dec-21 7:34
MemberJoseline Riker3-Dec-21 7:34 
GeneralRe: call a server side Powershell script? Pin
Richard Deeming5-Dec-21 21:43
mveRichard Deeming5-Dec-21 21:43 
QuestionIs it possible to use SQLite instead of MSSQL SERVER in ASP.NET projects? Pin
Alex Dunlop17-Nov-21 21:29
MemberAlex Dunlop17-Nov-21 21:29 
AnswerRe: Is it possible to use SQLight instead of MSSQL SERVER in ASP.NET projects? Pin
Richard Deeming17-Nov-21 21:45
mveRichard Deeming17-Nov-21 21:45 
Questioncheckbox inserting null value in a custom templatefield (vb.net) Pin
Oliver Freeman27-Oct-21 2:56
MemberOliver Freeman27-Oct-21 2:56 
QuestionCan shell32.dll be used in IIS environment? Pin
Member 35932620-Oct-21 10:11
MemberMember 35932620-Oct-21 10:11 
AnswerRe: Can shell32.dll be used in IIS environment? Pin
Richard Deeming20-Oct-21 22:17
mveRichard Deeming20-Oct-21 22:17 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.