This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// this is the order of the fields for a book stored in a file | |
ISBN = 0; | |
AUTHORS_LAST_NAME = 1; | |
AUTHORS_FIRST_NAME = 2; | |
TITLE = 3; | |
PUBLICATION_YEAR = 4; | |
INDEX_PRICE = 5; | |
string recordIn; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private void removeButton_Click(object sender, EventArgs e) | |
{ | |
if (removeIsbnRadioButton.Checked) | |
{ | |
foreach (Book book in books) | |
{ | |
if (book.Isbn.Normalize().Equals(searchBookTextBox.Text.Normalize())) | |
{ | |
books.Remove(book); | |
break; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void SavingFile() | |
{ | |
StreamWriter writer = new StreamWriter("books.txt"); | |
foreach (Book book in books) | |
{ | |
writer.WriteLine(book.ToString()); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public void SavingFile() | |
{ | |
StreamWriter writer = new StreamWriter("books.txt"); | |
foreach (Book book in books) | |
{ | |
writer.WriteLine(book.ToString()); | |
} | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
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.IO; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//Nicole Buck | |
//Prog 109 Project 3 | |
var bet = 0; | |
var credits = 100; | |
var count = 0; | |
var slotImages = new Array("lemon.png", "plum.png", "bell.png", "diamond.png", "clover.jpg"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static void Roll() | |
{ | |
Random r = new Random(); | |
Random r2 = new Random(); | |
int roll = r.Next(1, 7); | |
int roll2 = r2.Next(1, 7); | |
} | |
//label1.Text = roll.ToString(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
CLASS | |
namespace DiceGame | |
{ | |
class TwoDice | |
{ | |
private static string filepath = @"C:\Users\Talia\Desktop\PROG 120\DiceGame\dice\"; | |
private int value; | |
private Image image1; | |
private Image image2; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private void searchButton_Click(object sender, EventArgs e) | |
{ | |
try | |
{ | |
DataSet dataSet = new DataSet(); | |
dataSet = BusinessEntities.PermitData.GetApplications(firstNameTextBox.Text, lastNameTextBox.Text); | |
searchJobsByNameDataGridView.DataSource = dataSet.Tables[0]; | |
} | |
catch (Exception ex) | |
{ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public int CompareTo(object obj) | |
{ | |
if (obj is Book) | |
{ | |
Book otherBook = (Book)obj; | |
if (this.Title != otherBook.Title) | |
{ | |
return this.Title.CompareTo(otherBook.Title); | |
} | |
} |
OlderNewer