Click here to Skip to main content
15,904,926 members
Home / Discussions / C#
   

C#

 
GeneralPrinting a blank page Pin
Shaun Becker15-Mar-04 2:47
Shaun Becker15-Mar-04 2:47 
GeneralRe: Printing a blank page Pin
John Fisher15-Mar-04 4:13
John Fisher15-Mar-04 4:13 
GeneralRe: Printing a blank page Pin
Shaun Becker15-Mar-04 4:36
Shaun Becker15-Mar-04 4:36 
GeneralRe: Printing a blank page Pin
John Fisher15-Mar-04 6:09
John Fisher15-Mar-04 6:09 
GeneralRe: Printing a blank page Pin
Shaun Becker15-Mar-04 8:21
Shaun Becker15-Mar-04 8:21 
GeneralRe: Printing a blank page Pin
Shaun Becker15-Mar-04 9:25
Shaun Becker15-Mar-04 9:25 
GeneralRe: Printing a blank page Pin
John Fisher15-Mar-04 16:55
John Fisher15-Mar-04 16:55 
GeneralCheckbox in Subitem of ListView Pin
katetsai15-Mar-04 2:44
katetsai15-Mar-04 2:44 
GeneralRe: Checkbox in Subitem of ListView Pin
Heath Stewart15-Mar-04 5:11
protectorHeath Stewart15-Mar-04 5:11 
GeneralRe: Checkbox in Subitem of ListView Pin
katetsai15-Mar-04 5:58
katetsai15-Mar-04 5:58 
GeneralRe: Checkbox in Subitem of ListView Pin
Heath Stewart15-Mar-04 6:14
protectorHeath Stewart15-Mar-04 6:14 
GeneralRe: Checkbox in Subitem of ListView Pin
John Fisher15-Mar-04 6:15
John Fisher15-Mar-04 6:15 
GeneralRe: Checkbox in Subitem of ListView Pin
Heath Stewart15-Mar-04 6:31
protectorHeath Stewart15-Mar-04 6:31 
GeneralLocalizing standard types in PropertyGrid Pin
i_blazhko15-Mar-04 1:49
i_blazhko15-Mar-04 1:49 
GeneralRe: Localizing standard types in PropertyGrid Pin
Heath Stewart15-Mar-04 5:10
protectorHeath Stewart15-Mar-04 5:10 
GeneralRe: Localizing standard types in PropertyGrid Pin
i_blazhko15-Mar-04 22:42
i_blazhko15-Mar-04 22:42 
GeneralRe: Localizing standard types in PropertyGrid Pin
Heath Stewart16-Mar-04 2:48
protectorHeath Stewart16-Mar-04 2:48 
GeneralRe: Localizing standard types in PropertyGrid Pin
i_blazhko16-Mar-04 3:04
i_blazhko16-Mar-04 3:04 
GeneralGet the true icons of a file Pin
Jonathan Slenders15-Mar-04 0:29
Jonathan Slenders15-Mar-04 0:29 
GeneralRe: Get the true icons of a file Pin
SimonS15-Mar-04 0:56
SimonS15-Mar-04 0:56 
GeneralRe: Get the true icons of a file Pin
Heath Stewart15-Mar-04 5:09
protectorHeath Stewart15-Mar-04 5:09 
Questionhow to visible remove and add data on ListView Pin
yu-yu15-Mar-04 0:10
yu-yu15-Mar-04 0:10 
General.NET Remoting and internal errors. Pin
SimonS14-Mar-04 21:58
SimonS14-Mar-04 21:58 
GeneralRe: .NET Remoting and internal errors. Pin
Heath Stewart15-Mar-04 4:06
protectorHeath Stewart15-Mar-04 4:06 
Generalprevious record problem Pin
ASGill14-Mar-04 16:50
ASGill14-Mar-04 16:50 
<br />
private void btnPrevious_Click(object sender, System.EventArgs e)<br />
		{<br />
			txtAcctID.Clear();<br />
<br />
			if (Row == 0)<br />
			{<br />
				MessageBox.Show("You are at the first patient on the Queue","Beginning Of Queue");<br />
				Row = 0;<br />
				<br />
			}<br />
			else<br />
			{	<br />
				Row = Row --;<br />
				txtAcctID.Text= dsPatDia.Tables["PatDia"].Rows[lastrecord]["Acct ID"].ToString(); <-- ERROR! <br />
				//FillForm();<br />
			}<br />
<br />
			if( Row == 0)<br />
			{<br />
				try<br />
				{<br />
					oleDbConnection1.Open();<br />
<br />
					oleDbDataAdapter1.SelectCommand.CommandText = "SELECT Results, Tests, Symptom FROM Dianosis WHERE [Acct ID]= '"+txtAcctID.Text+"'";<br />
<br />
					oleDbDataAdapter1.SelectCommand.ExecuteNonQuery();<br />
<br />
					oleDbDataAdapter1.Fill(dsDiag2);<br />
<br />
					Display(dsDiag2);<br />
				}<br />
				catch (Exception ConnError)<br />
				{<br />
					MessageBox.Show(ConnError.ToString());<br />
				}<br />
				<br />
			}<br />
	<br />
		}<br />
		<br />
		private void Display(System.Data.DataSet dsDiag2)<br />
		{<br />
			oleDbConnection1.Close();<br />
			try<br />
			{<br />
				System.Data.DataTable PrevDiag = dsDiag2.Tables[0];<br />
<br />
				if(PrevDiag.Rows.Count != 0)<br />
				{					<br />
					txtResults.Text = (string) PrevDiag.Rows[0][3];<br />
					txtTests.Text = (string) PrevDiag.Rows[0][4];<br />
					txtSymp.Text = (string) PrevDiag.Rows[0][5];<br />
				}<br />
				else<br />
				{<br />
					MessageBox.Show("The Patient Record does not exist","Information");<br />
					dsDiag2.Clear();<br />
				}<br />
			}<br />
			catch(Exception Error10)<br />
			{<br />
				MessageBox.Show(Error10.ToString());<br />
			}<br />
		}<br />


An unhandled exception of type 'System.NullReferenceException' occurred in CLINICINFORMATIONSYSTEM.exe

Additional information: Object reference not set to an instance of an object.

how do i rectify this prblem..i want the textbox to display the id of the record before the current one.?


CODER

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.