Importing name of selected patient
-
- Posts: 39
- Joined: Mon Jun 16, 2014 7:33 am
Importing name of selected patient
Hi,
I want to import the selected patient full name on new customized form. How can i do this?
All let me know the code to make it trail version limit of 30 patient( Code and where to put it?)
Thanks
I want to import the selected patient full name on new customized form. How can i do this?
All let me know the code to make it trail version limit of 30 patient( Code and where to put it?)
Thanks
Re: Importing name of selected patient
What exactly do you mean by "new customized form"? Are you referring to a sheet (commonly referred to as patient form / forms within OD)? If so, I think you are interested in importing sheets:ujjwal singh wrote:I want to import the selected patient full name on new customized form. How can i do this?
http://www.opendental.com/manual/patien ... mport.html
You shouldn't need to add any additional code. In order to get your compiler ready to make a trial version, set the Conditional Compilation Symbols of the OpenDental project to TRIALONLY.ujjwal singh wrote:All let me know the code to make it trail version limit of 30 patient( Code and where to put it?)
The 30 patient limit will automatically take affect once TRIALONLY is set. See FormPatientSelect.butAddPt_Click() for details on the 30 patient limit.
The best thing about a boolean is even if you are wrong, you are only off by a bit.
Jason Salmon
Open Dental Software
http://www.opendental.com
Jason Salmon
Open Dental Software
http://www.opendental.com
-
- Posts: 39
- Joined: Mon Jun 16, 2014 7:33 am
Re: Importing name of selected patient
I mean, i just had made a new form for prescription on code side. Now i want that in a label the selected patient name and age should automatically appers. what code i have to implement ?
Re: Importing name of selected patient
If I'm understanding correctly you want to do something like this in your Form_Load:ujjwal singh wrote:I mean, i just had made a new form for prescription on code side. Now i want that in a label the selected patient name and age should automatically appers. what code i have to implement ?
Code: Select all
Label myLabel=new Label();//The label that is on your form.
myLabel.Text="Name: "+selectedPatient.GetNameFL()+" - Age: "+selectedPatient.Age;
The best thing about a boolean is even if you are wrong, you are only off by a bit.
Jason Salmon
Open Dental Software
http://www.opendental.com
Jason Salmon
Open Dental Software
http://www.opendental.com
-
- Posts: 39
- Joined: Mon Jun 16, 2014 7:33 am
Re: Importing name of selected patient
Error: Error 45 The name 'selectedPatient' does not exist in the current context D:\od12.2.44\OpenDental\Forms\FormRxS.cs 35 13 OpenDental
Does i m missing any directive assembly or any other reference?
Does i m missing any directive assembly or any other reference?
Re: Importing name of selected patient
Sorry, I didn't specify that the variable "selectedPatient" needs to be your Patient object. So just use the patient object that you used when you created your prescription. Most likely you passed in the currently selected patient from a plugin hook? If not, you can probably just use FormOpenDental.PatNumCur to get your patient object OR if you came from a module you can just use its Patient object that they often keep around. E.g. ContrChart.PatCur
The best thing about a boolean is even if you are wrong, you are only off by a bit.
Jason Salmon
Open Dental Software
http://www.opendental.com
Jason Salmon
Open Dental Software
http://www.opendental.com
-
- Posts: 39
- Joined: Mon Jun 16, 2014 7:33 am
Re: Importing name of selected patient
Soory Jasalmon,
This is not working, i m unable to get the selected patient name. I m stating my problem again hoping the fruitful result.
I had made a new form and under the forms module, I have taken some text boxes on it, Now i m trying to get the selected patient name in one of the text box should appear automatically on form load.
This is not working, i m unable to get the selected patient name. I m stating my problem again hoping the fruitful result.
I had made a new form and under the forms module, I have taken some text boxes on it, Now i m trying to get the selected patient name in one of the text box should appear automatically on form load.
Re: Importing name of selected patient
As Jason mentioned, you will either need to have a patient object set outside of the form, or you can use the patnum in Jason's other examples and call patients.GetPat(INSERT PATNUM HERE);. The patient object that function returns will contain the patient's name. I hope this helps, however any additional help is most likely beyond our scope, as we are venturing into C# and general programming concepts, and not issues directly related to OpenDental.