PersonSession.InsertAtDB C# (CSharp) Méthode

InsertAtDB() public méthode

public InsertAtDB ( bool dbconOpened, string tableName ) : int
dbconOpened bool
tableName string
Résultat int
    public int InsertAtDB(bool dbconOpened, string tableName)
    {
        int myID = SqlitePersonSession.Insert(dbconOpened,
                uniqueID.ToString(),
                personID, sessionID, height, weight,
                sportID, speciallityID,
                practice, comments);
        return myID;
    }

Usage Example

 public int UploadPersonSessionIfNeeded(PersonSession ps)
 {
     if (!SqlitePersonSession.PersonSelectExistsInSession(ps.PersonID, ps.SessionID))
     {
         Console.WriteLine("personSession needed");
         Console.WriteLine(ps.ToString());
         ps.InsertAtDB(false, Constants.PersonSessionTable);
         Console.WriteLine("done");
         return(1);            //unused
     }
     else
     {
         Console.WriteLine("personSession NOT needed");
     }
     return(0);        //unused
 }
All Usage Examples Of PersonSession::InsertAtDB