dhazard's Profile
Reputation: 12
Tradesman
- Group:
- Contributors
- Active Posts:
- 67 (0.03 per day)
- Joined:
- 06-September 06
- Profile Views:
- 1,836
- Last Active:
Nov 07 2012 02:05 PM- Currently:
- Offline
Previous Fields
- Country:
- US
- OS Preference:
- Windows
- Favorite Browser:
- Chrome
- Favorite Processor:
- AMD
- Favorite Gaming Platform:
- PC
- Your Car:
- Ford
- Dream Kudos:
- 50
Latest Visitors
-
act147 
01 Nov 2012 - 12:08 -
m0h1t 
01 Nov 2012 - 11:10 -
owllight 
31 Oct 2012 - 16:16 -
modi123_1 
20 Oct 2012 - 21:24 -
chris.whitley 
20 Oct 2012 - 21:00
Posts I've Made
-
In Topic: System.Data.SqlClient.SqlException was unhandled
Posted 6 Nov 2012
You could use Microsoft® SQL Server® 2008 Management Studio Express to configure. -
In Topic: Displaying check box Text
Posted 6 Nov 2012
What does ResetChecked(); do? And why are we not using a CheckBoxList Control versus just a bunch of CheckBoxes? -
In Topic: Reading a Number in C#
Posted 1 Nov 2012
You seem to already have most of the work done. I would look into this tutorial C# Tutorial it would be pointless for me to actually post the code for you since the solution is only a few google searches away. -
In Topic: Import excel file to C# using OLEDB
Posted 1 Nov 2012
I believe the right connection string would be the following:
private void button1_Click(object sender, EventArgs e) { string fileName = @"C:\test.xlsx"; string connectionString = "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=" + fileName + ";Extended Properties=\"Excel 12.0;HDR=YES;\""; OleDbConnection con = new System.Data.OleDb.OleDbConnection(connectionString); con.Open(); OleDbDataAdapter cmd = new System.Data.OleDb.OleDbDataAdapter("select * from [SHEET1$]", con); DataSet excelDataSet = new DataSet(); cmd.Fill(excelDataSet); xl.DataSource = excelDataSet.Tables[0]; con.Close(); }
For sanity check I added the (@) to the string. -
In Topic: Searching through a string array, returning index of another array
Posted 1 Nov 2012
public static int FindStudentPosition(string name, string[] array) { [b]string target = 0;[/b] int result; target = Console.ReadLine(); Array.FindAll(arrayName, s => s.Equals(target)); return result; }
Cant Convert String to Ints. Either do a cast or change the type from string to int. Your method doesnt even return anything at all either.
foreach( KeyValuePair<string, string> kvp in openWith ) { Console.WriteLine("Key = {0}, Value = {1}", kvp.Key, kvp.Value); }
I agree with everyone above about using Objects. I do think you need to get the basics down when it comes to arrays as well. I would opt for a KeyValuePair the key being the student name and the pair being the test score. You can read more about it on MSDN.
MSDN - KeyValuePair<TKey, TValue> Structure
My Information
- Member Title:
- D.I.C Head
- Age:
- 25 years old
- Birthday:
- March 26, 1988
- Gender:
-
- Years Programming:
- 4
- Programming Languages:
- PHP, SQL, C#, Javascript, ColdFusion, MySQL, ACCESS, MsSQL
Contact Information
- E-mail:
- Click here to e-mail me
Friends
dhazard hasn't added any friends yet.
|
|


Find Topics
Find Posts
View Reputation Given
|
Comments
dhazard has no profile comments yet. Why not say hello?