Skip to content

Instantly share code, notes, and snippets.

@pmrozik
Created January 14, 2015 23:20
Show Gist options
  • Save pmrozik/dc8c6a80839bf92f4909 to your computer and use it in GitHub Desktop.
Save pmrozik/dc8c6a80839bf92f4909 to your computer and use it in GitHub Desktop.
public static void insertWord(string word)
{
OperationDataContext odContext = new OperationDataContext();
english_dictionary dictionary = new english_dictionary();
dictionary.word = word;
dictionary.wordID = wordID++;
odContext.english_dictionaries.InsertOnSubmit(dictionary);
odContext.SubmitChanges();
Console.WriteLine("{0} added to database.", word);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment