I haven't spent a huge amount of time on it, but each time I try I have given up so far....Jordan,
yes, the example posted does help a little, but I just can't quite figure out how to graphically place things easily in the designer, do I have to manually figure out the coordinates by first modifying the existing form and then transferring that whole object (eg panel) over to a new form? ...kind of like the example? It just seems like a lot of figuring, etc...
Also, if you could give another example of a hook and modification of display on an existing form like most of my modifications that would help. The other problem (which is good overall, but not for the example) you actually have the included example of the drop down ins info in the account in the program now, so it is hard to tell what is already there and what is changed. Not a new form, but display changes to existing forms.
Thanks.
Help with Plugins
Help with Plugins
- jordansparks
- Site Admin
- Posts: 5770
- Joined: Sun Jun 17, 2007 3:59 pm
- Location: Salem, Oregon
- Contact:
Re: Help with Plugins
Give me one example with one change that you feel represents a typical change. I will add that change to the posted sample.
Jordan Sparks, DMD
http://www.opendental.com
http://www.opendental.com
Re: Help with Plugins
How about adding "Referral To" list to the Patient Info section of the Chart instead of just Referred From?
- jordansparks
- Site Admin
- Posts: 5770
- Joined: Sun Jun 17, 2007 3:59 pm
- Location: Salem, Oregon
- Contact:
Re: Help with Plugins
OK, I'll add that to the plugin example as well as make sure the plugin example isn't broken.
Jordan Sparks, DMD
http://www.opendental.com
http://www.opendental.com
- jordansparks
- Site Admin
- Posts: 5770
- Joined: Sun Jun 17, 2007 3:59 pm
- Location: Salem, Oregon
- Contact:
Re: Help with Plugins
Done. Please note that to get it to work, you would have had to ask us for one method hook for ContrChart.FillPtInfo. And then, after you realized that ContrChart.TreatmentNoteChanged needed to be made public, you would have needed to ask for that, too. I have not tested to see that the treatment note part of it works. So after thorough testing, there might be some other quirk.
Jordan Sparks, DMD
http://www.opendental.com
http://www.opendental.com
Re: Help with Plugins
great...i will try it out as soon as I can and look it over.
Re: Help with Plugins
I can't seem to find the plugin page...the link on the developers page is wrong http://www.opendental.com/manual/programmers.html --> it goes to http://www.opendental.com/manual/developers.html
- jordansparks
- Site Admin
- Posts: 5770
- Joined: Sun Jun 17, 2007 3:59 pm
- Location: Salem, Oregon
- Contact:
- jordansparks
- Site Admin
- Posts: 5770
- Joined: Sun Jun 17, 2007 3:59 pm
- Location: Salem, Oregon
- Contact:
Re: Help with Plugins
The above statement is wrong. I now know that ContrChart.TreatmentNoteChanged could have wrapped up and passed in as an object in the parameter list. Since it's a value type, there's a little more work involved; it can't be passed directly in. So I'll be adding to the example at some point to show how to pass in a value type to simulate by ref. In summary, it did not need to be made public in the main program.jordansparks wrote:Done. Please note that to get it to work, you would have had to ask us for one method hook for ContrChart.FillPtInfo. And then, after you realized that ContrChart.TreatmentNoteChanged needed to be made public, you would have needed to ask for that, too. I have not tested to see that the treatment note part of it works. So after thorough testing, there might be some other quirk.
Jordan Sparks, DMD
http://www.opendental.com
http://www.opendental.com
Re: Help with Plugins
so, I can't get it to compile now w/o commenting out
sender.TreatmentNoteChanged=false;
not quite figuring out what I need to do...is it not public now?
sender.TreatmentNoteChanged=false;
not quite figuring out what I need to do...is it not public now?
Re: Help with Plugins
every time I try to test out my plugin, it says "Version of plug-in may not be newer than version of Open Dental."...which I know is coming from the convertplugindatabase.cs file, but don't know what I am doing wrong!
I am trying to run it on the head alpha version and beta versions but they both give me the same error, what am I doing wrong?
I am trying to run it on the head alpha version and beta versions but they both give me the same error, what am I doing wrong?
Re: Help with Plugins
ok, nevermind...i had to change the version in the assembly info....loads now...
Last edited by drtech on Wed Mar 31, 2010 8:38 am, edited 2 times in total.
Re: Help with Plugins
can you add the plugin project to your normal open dental solution and include it to debug? I tried, it but it doesn't seem to build the dll when I do that...Otherwise I cannot figure out how to debug my plugin with the program.
Re: Help with Plugins
when i have the dll enabled, I am getting an error after login
Value cannot be null.
Parameter name:type
but I can't debug when the dll is already built and running...how do I figure this out?
Value cannot be null.
Parameter name:type
but I can't debug when the dll is already built and running...how do I figure this out?
- jordansparks
- Site Admin
- Posts: 5770
- Joined: Sun Jun 17, 2007 3:59 pm
- Location: Salem, Oregon
- Contact:
Re: Help with Plugins
I listed it out in 9 steps. I guess what I didn't list was how to copy the solution folder to a new location so that you can start making it different than the example.
1. Copy and paste the example solution to a new location.
2. Fix the references, by dropping and readding projects, readding references, etc. Already explained on that page in the manual.
You can see in step 8 that the OD project is already part of the solution. That's how you run it.
1. Copy and paste the example solution to a new location.
2. Fix the references, by dropping and readding projects, readding references, etc. Already explained on that page in the manual.
You can see in step 8 that the OD project is already part of the solution. That's how you run it.
Jordan Sparks, DMD
http://www.opendental.com
http://www.opendental.com
Re: Help with Plugins
k...didn't know if it was a simple as that...thanks
duh..i completely missed: 8. Set the Open Dental project to be the startup project (right click).
what about
"sender.TreatmentNoteChanged=false;" I still can't seem to build it w/o commenting out because this is not accessible..
duh..i completely missed: 8. Set the Open Dental project to be the startup project (right click).
what about
"sender.TreatmentNoteChanged=false;" I still can't seem to build it w/o commenting out because this is not accessible..
Last edited by drtech on Wed Mar 31, 2010 1:01 pm, edited 1 time in total.
Re: Help with Plugins
yes! i got the statement change it to work with my 1st plugin! (using your example of changing the statement!)
- jordansparks
- Site Admin
- Posts: 5770
- Joined: Sun Jun 17, 2007 3:59 pm
- Location: Salem, Oregon
- Contact:
Re: Help with Plugins
I just committed making TreatmentNoteChanged public. But I have this nagging feeling that there was a reason I didn't do it earlier. So if it works with 7.1, but still not with 7.0 for some reason, then let me know. I'll try to put in better documentation about the version number for other people getting started.
Jordan Sparks, DMD
http://www.opendental.com
http://www.opendental.com
Re: Help with Plugins
Now, I need the data I want.
How can I get the total balance left for a payment plan (not what is due)?
if (tableMisc.Rows[m]["descript"].ToString() == "Balance")
{
pplanTotal += PIn.Double(tableMisc.Rows[m]["value"].ToString());
//payPlanDue;//PatGuar.PayPlanDue;
}
does not seem to work...
where is the definition for the rows in the tablePP and tableMisc in formRPStatement?
It seems that "CompletedAmt" from the database in the payplan table may be what I want, but I can't seem to figure out where it is stored in those arrays...
How can I get the total balance left for a payment plan (not what is due)?
if (tableMisc.Rows[m]["descript"].ToString() == "Balance")
{
pplanTotal += PIn.Double(tableMisc.Rows[m]["value"].ToString());
//payPlanDue;//PatGuar.PayPlanDue;
}
does not seem to work...
where is the definition for the rows in the tablePP and tableMisc in formRPStatement?
It seems that "CompletedAmt" from the database in the payplan table may be what I want, but I can't seem to figure out where it is stored in those arrays...
Last edited by drtech on Wed Mar 31, 2010 1:36 pm, edited 1 time in total.
Re: Help with Plugins
Here is what I am trying to do on the statements for a floating balance on my plugin:
Total: $1000 (includes all financed payment plans)
-Amt Financed: $500 (what is left on the balance of all the payment plans)
-In Est. : $100
Owed Now :$400
Code:
double pplanTotal = 0;
//double balanceTotal = PatGuar.BalTotal;
for (int m = 0; m < tableMisc.Rows.Count; m++)
{
if (tableMisc.Rows[m]["descript"].ToString() == "Balance")
{
pplanTotal += PIn.Double(tableMisc.Rows[m]["value"].ToString());
//payPlanDue;//PatGuar.PayPlanDue;
}
}
double pplanDue = 0;
for (int m = 0; m < tableMisc.Rows.Count; m++)
{
if (tableMisc.Rows[m]["descript"].ToString() == "payPlanDue")
{
pplanDue += PIn.Double(tableMisc.Rows[m]["value"].ToString());
//payPlanDue;//PatGuar.PayPlanDue;
}
}
double amtFinanced = pplanTotal - pplanDue;
if (tablePP.Rows.Count > 0) //Show different info if payment plans involved.
{
text = (PatGuar.BalTotal + pplanTotal).ToString("c"); //orig: PatGuar.BalTotal.ToString("c");
par.AddFormattedText(text, font);
par.AddLineBreak();
text = amtFinanced.ToString("c");
par.AddFormattedText(text, font);
par.AddLineBreak();
text = PatGuar.InsEst.ToString("c");
par.AddFormattedText(text, font);
par.AddLineBreak();
text = (PatGuar.BalTotal + pplanDue - PatGuar.InsEst).ToString("c");
par.AddFormattedText(text, fontBold);
par.AddLineBreak();
Total: $1000 (includes all financed payment plans)
-Amt Financed: $500 (what is left on the balance of all the payment plans)
-In Est. : $100
Owed Now :$400
Code:
double pplanTotal = 0;
//double balanceTotal = PatGuar.BalTotal;
for (int m = 0; m < tableMisc.Rows.Count; m++)
{
if (tableMisc.Rows[m]["descript"].ToString() == "Balance")
{
pplanTotal += PIn.Double(tableMisc.Rows[m]["value"].ToString());
//payPlanDue;//PatGuar.PayPlanDue;
}
}
double pplanDue = 0;
for (int m = 0; m < tableMisc.Rows.Count; m++)
{
if (tableMisc.Rows[m]["descript"].ToString() == "payPlanDue")
{
pplanDue += PIn.Double(tableMisc.Rows[m]["value"].ToString());
//payPlanDue;//PatGuar.PayPlanDue;
}
}
double amtFinanced = pplanTotal - pplanDue;
if (tablePP.Rows.Count > 0) //Show different info if payment plans involved.
{
text = (PatGuar.BalTotal + pplanTotal).ToString("c"); //orig: PatGuar.BalTotal.ToString("c");
par.AddFormattedText(text, font);
par.AddLineBreak();
text = amtFinanced.ToString("c");
par.AddFormattedText(text, font);
par.AddLineBreak();
text = PatGuar.InsEst.ToString("c");
par.AddFormattedText(text, font);
par.AddLineBreak();
text = (PatGuar.BalTotal + pplanDue - PatGuar.InsEst).ToString("c");
par.AddFormattedText(text, fontBold);
par.AddLineBreak();
- jordansparks
- Site Admin
- Posts: 5770
- Joined: Sun Jun 17, 2007 3:59 pm
- Location: Salem, Oregon
- Contact:
Re: Help with Plugins
You'll have to figure out a query that does it. You won't be getting your data from the middle tier.
Jordan Sparks, DMD
http://www.opendental.com
http://www.opendental.com
Re: Help with Plugins
ok...was hoping it was already there...
Re: Help with Plugins
I am also getting an error when debuging
DLL 'C:\Windows\assembly\GAC\Microsoft.DirectX\1.0.2902.0__31bf3856ad364e35\Microsoft.DirectX.dll' is attempting managed execution inside OS Loader lock. Do not attempt to run managed code inside a DllMain or image initialization function since doing so can cause the application to hang.
you can just continue and it works fine, but keeps breaking twice to announce this on Initialize Graphics in ToothChartDirectX.cs
I am not doing anything with graphics, so not sure what that is all about. debugging with beta 7.0.14
DLL 'C:\Windows\assembly\GAC\Microsoft.DirectX\1.0.2902.0__31bf3856ad364e35\Microsoft.DirectX.dll' is attempting managed execution inside OS Loader lock. Do not attempt to run managed code inside a DllMain or image initialization function since doing so can cause the application to hang.
you can just continue and it works fine, but keeps breaking twice to announce this on Initialize Graphics in ToothChartDirectX.cs
I am not doing anything with graphics, so not sure what that is all about. debugging with beta 7.0.14
- jordansparks
- Site Admin
- Posts: 5770
- Joined: Sun Jun 17, 2007 3:59 pm
- Location: Salem, Oregon
- Contact:
Re: Help with Plugins
Loader lock is discussed here in the fifth paragraph:
http://www.opendental.com/manual/developers.html
http://www.opendental.com/manual/developers.html
Jordan Sparks, DMD
http://www.opendental.com
http://www.opendental.com
Re: Help with Plugins
thanks...