Click here to Skip to main content
14,664,203 members
Home » Discussions » .NET (Core and Framework)
   

.NET (Core and Framework)

 
GeneralRe: Column length change using Entity Framework Code First Pin
simpledeveloper18-Mar-20 3:14
Membersimpledeveloper18-Mar-20 3:14 
GeneralRe: Column length change using Entity Framework Code First Pin
Richard Deeming18-Mar-20 3:55
mveRichard Deeming18-Mar-20 3:55 
GeneralRe: Column length change using Entity Framework Code First Pin
simpledeveloper18-Mar-20 8:43
Membersimpledeveloper18-Mar-20 8:43 
GeneralRe: Column length change using Entity Framework Code First Pin
Richard Deeming18-Mar-20 8:48
mveRichard Deeming18-Mar-20 8:48 
GeneralRe: Column length change using Entity Framework Code First Pin
simpledeveloper19-Mar-20 5:54
Membersimpledeveloper19-Mar-20 5:54 
Questionc# forms (holy crap i'm not ready for this) Pin
Uranium-23513-Mar-20 23:51
MemberUranium-23513-Mar-20 23:51 
AnswerRe: c# forms (holy crap i'm not ready for this) Pin
Richard MacCutchan14-Mar-20 1:07
mveRichard MacCutchan14-Mar-20 1:07 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Uranium-23514-Mar-20 4:37
MemberUranium-23514-Mar-20 4:37 
my main.cs

using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Data.SQLite;
using System.IO;

namespace TechTracker
{
          
    
    public partial class Main : Form
    {
        public Main()
        {
            InitializeComponent();
        }


        private void Main_Load(object sender, EventArgs e)
        {
            if(!File.Exists(Directory.GetCurrentDirectory() + "\\Tracker.db"))
            {
                //yeah none of these worked
                //((CreateDB)this.Owner).Show();
                //Form CreateDBForm = CreateDB.FindForm();
                //TechTracker.CreateDB.ActiveForm.Visible = true;
                //System.Windows.Forms.Control.Invoke;
                 

            }
        }
    }
}


createDB.cs
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;

namespace TechTracker
{
    public partial class CreateDB : Form
    {
        public CreateDB()
        {
            InitializeComponent();
            
        }
    }
}


both were made as windows forms designer. createDB is not visible by default. As you can see, if the file is not there, they choose to create it as an sqlLite (I know I still have to define it in using in createdb) database. createDB is topmost enabled and won't let the main form be accessible when it's up. That logic shouldn't be hard, i've done it with vb before. I'll later get a better method of detecting the database file (store filepath in registry, or local file). Probably even allow switching DB files in a settings dropdown. For now, this just basic code to get some of the basic functionality out of this way.

I learned VB.net from scratch using only google on trial and error. Got fairly good at it too. It's just these individual methods of c# I need to get out of the way

oh and yes, it's me from the previous post. I decided to go with sqllite instead of mysql or transactional HTTP transfer. I'm making this mainly for me for the time being, and I can just use google drive or something to sync the sqllite db file for housecall (on my laptop) or home use

thank you
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Dave Kreskowiak14-Mar-20 4:58
mveDave Kreskowiak14-Mar-20 4:58 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Uranium-23514-Mar-20 5:35
MemberUranium-23514-Mar-20 5:35 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Dave Kreskowiak14-Mar-20 6:30
mveDave Kreskowiak14-Mar-20 6:30 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Richard MacCutchan14-Mar-20 6:11
mveRichard MacCutchan14-Mar-20 6:11 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Uranium-23514-Mar-20 6:51
MemberUranium-23514-Mar-20 6:51 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Richard MacCutchan14-Mar-20 7:02
mveRichard MacCutchan14-Mar-20 7:02 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Uranium-23514-Mar-20 20:42
MemberUranium-23514-Mar-20 20:42 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Uranium-23514-Mar-20 20:25
MemberUranium-23514-Mar-20 20:25 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Richard MacCutchan14-Mar-20 22:10
mveRichard MacCutchan14-Mar-20 22:10 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Uranium-23515-Mar-20 4:41
MemberUranium-23515-Mar-20 4:41 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Richard MacCutchan15-Mar-20 4:44
mveRichard MacCutchan15-Mar-20 4:44 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Uranium-23515-Mar-20 7:40
MemberUranium-23515-Mar-20 7:40 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Richard MacCutchan15-Mar-20 8:00
mveRichard MacCutchan15-Mar-20 8:00 
AnswerRe: c# forms (holy crap i'm not ready for this) Pin
Uranium-2359-Apr-20 23:01
MemberUranium-2359-Apr-20 23:01 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Uranium-23510-Apr-20 10:12
MemberUranium-23510-Apr-20 10:12 
GeneralRe: c# forms (holy crap i'm not ready for this) Pin
Uranium-23511-Apr-20 16:33
MemberUranium-23511-Apr-20 16:33 
QuestionEntity Framework Code First is generating an extra column - need some help please Pin
simpledeveloper9-Mar-20 9:44
Membersimpledeveloper9-Mar-20 9:44 

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.