OD 16.4.22: InsBenBWCodes is an invalid pref name

For complex topics that regular users would not be interested in. For power users and database administrators.
Post Reply
User avatar
wjstarck
Posts: 935
Joined: Tue Jul 31, 2007 7:18 am
Location: Keller, TX
Contact:

OD 16.4.22: InsBenBWCodes is an invalid pref name

Post by wjstarck » Wed Feb 15, 2017 6:55 am

I'm getting the following exception 'InsBenBWCodes is an invalid pref name' when I try to enter procedure codes (OD 16.4.22):

Code: Select all

************** Exception Text **************
System.Exception: InsBenBWCodes is an invalid pref name.
   at OpenDentBusiness.PrefC.GetString(PrefName prefName, Dictionary`2 dictPrefs)
   at OpenDentBusiness.ProcedureCodeC.get_ListBWCodeNums()
   at OpenDentBusiness.Procedures.ComputeForOrdinal(Int32 ordinal, List`1 claimProcs, Procedure proc, List`1 planList, Boolean isInitialEntry, Double& paidOtherInsEstTotal, Double& paidOtherInsBaseEst, Double& writeOffEstOtherIns, List`1 patPlans, List`1 benefitList, List`1 histList, List`1 loopList, Boolean saveToDb, Int32 patientAge)
   at OpenDentBusiness.Procedures.ComputeEstimates(Procedure proc, Int64 patNum, List`1& claimProcs, Boolean isInitialEntry, List`1 planList, List`1 patPlans, List`1 benefitList, List`1 histList, List`1 loopList, Boolean saveToDb, Int32 patientAge, List`1 subList, Boolean isForOrtho)
   at OpenDentBusiness.Procedures.ComputeEstimates(Procedure proc, Int64 patNum, List`1 claimProcs, Boolean isInitialEntry, List`1 planList, List`1 patPlans, List`1 benefitList, Int32 patientAge, List`1 subList, Boolean isForOrtho)
   at OpenDental.FormApptEdit.listQuickAdd_MouseDown(Object sender, MouseEventArgs e)
   at System.Windows.Forms.Control.OnMouseDown(MouseEventArgs e)
   at System.Windows.Forms.Control.WmMouseDown(Message& m, MouseButtons button, Int32 clicks)
   at System.Windows.Forms.Control.WndProc(Message& m)
   at System.Windows.Forms.ListBox.WndProc(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.OnMessage(Message& m)
   at System.Windows.Forms.Control.ControlNativeWindow.WndProc(Message& m)
   at System.Windows.Forms.NativeWindow.Callback(IntPtr hWnd, Int32 msg, IntPtr wparam, IntPtr lparam)


************** Loaded Assemblies **************
mscorlib
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/Windows/Microsoft.NET/Framework/v4.0.30319/mscorlib.dll
----------------------------------------
OpenDental
    Assembly Version: 16.4.22.0
    Win32 Version: 16.4.22.0
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/OpenDental.exe
----------------------------------------
System.Windows.Forms
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Windows.Forms/v4.0_4.0.0.0__b77a5c561934e089/System.Windows.Forms.dll
----------------------------------------
System
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System/v4.0_4.0.0.0__b77a5c561934e089/System.dll
----------------------------------------
System.Drawing
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Drawing/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Drawing.dll
----------------------------------------
OpenDentBusiness
    Assembly Version: 16.4.22.0
    Win32 Version: 16.4.22.0
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/OpenDentBusiness.DLL
----------------------------------------
CodeBase
    Assembly Version: 16.3.1.0
    Win32 Version: 16.3.1.0
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/CodeBase.DLL
----------------------------------------
System.Configuration
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Configuration/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Configuration.dll
----------------------------------------
System.Core
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Core/v4.0_4.0.0.0__b77a5c561934e089/System.Core.dll
----------------------------------------
System.Xml
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Xml/v4.0_4.0.0.0__b77a5c561934e089/System.Xml.dll
----------------------------------------
NHunspell
    Assembly Version: 0.9.6.0
    Win32 Version: 0.9.6.0
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/NHunspell.DLL
----------------------------------------
System.Data
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1636.0 built by: NETFXREL3STAGE
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_32/System.Data/v4.0_4.0.0.0__b77a5c561934e089/System.Data.dll
----------------------------------------
MySql.Data
    Assembly Version: 6.9.9.0
    Win32 Version: 6.9.9.0
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/MySql.Data.DLL
----------------------------------------
System.Transactions
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_32/System.Transactions/v4.0_4.0.0.0__b77a5c561934e089/System.Transactions.dll
----------------------------------------
Oracle.DataAccess
    Assembly Version: 2.112.3.0
    Win32 Version: 2.112.3.0
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/Oracle.DataAccess.DLL
----------------------------------------
System.EnterpriseServices
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_32/System.EnterpriseServices/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.EnterpriseServices.dll
----------------------------------------
SparksToothChart
    Assembly Version: 4.7.1.0
    Win32 Version: 4.7.1.0
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/SparksToothChart.DLL
----------------------------------------
Microsoft.DirectX.Direct3D
    Assembly Version: 1.0.2902.0
    Win32 Version: 9.05.132.0000
    CodeBase: file:///C:/WINDOWS/assembly/GAC/Microsoft.DirectX.Direct3D/1.0.2902.0__31bf3856ad364e35/Microsoft.DirectX.Direct3D.dll
----------------------------------------
xImageDeviceManager
    Assembly Version: 1.0.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/xImageDeviceManager.DLL
----------------------------------------
SigPlusNET
    Assembly Version: 1.1.4050.24928
    Win32 Version: 
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/SigPlusNET.DLL
----------------------------------------
msvcm90
    Assembly Version: 9.0.30729.9247
    Win32 Version: 9.00.30729.9247
    CodeBase: file:///C:/WINDOWS/WinSxS/x86_microsoft.vc90.crt_1fc8b3b9a1e18e3b_9.0.30729.9247_none_5090cb78bcba4a35/msvcm90.dll
----------------------------------------
System.Web.Services
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Web.Services/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Web.Services.dll
----------------------------------------
OpenDental.XmlSerializers
    Assembly Version: 16.4.22.0
    Win32 Version: 16.4.22.0
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/OpenDental.XmlSerializers.DLL
----------------------------------------
AxInterop.AcroPDFLib
    Assembly Version: 1.0.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/AxInterop.AcroPDFLib.DLL
----------------------------------------
CDT
    Assembly Version: 16.4.7.0
    Win32 Version: 16.4.7.0
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/CDT.DLL
----------------------------------------
System.Numerics
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.Numerics/v4.0_4.0.0.0__b77a5c561934e089/System.Numerics.dll
----------------------------------------
System.Web
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_32/System.Web/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.Web.dll
----------------------------------------
Anesthesia16.4
    Assembly Version: 16.4.6254.30916
    Win32 Version: 16.4.6254.30916
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/Anesthesia.dll
----------------------------------------
System.ServiceProcess
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/System.ServiceProcess/v4.0_4.0.0.0__b03f5f7f11d50a3a/System.ServiceProcess.dll
----------------------------------------
Microsoft.DirectX
    Assembly Version: 1.0.2902.0
    Win32 Version: 5.04.00.2904
    CodeBase: file:///C:/WINDOWS/assembly/GAC/Microsoft.DirectX/1.0.2902.0__31bf3856ad364e35/Microsoft.DirectX.dll
----------------------------------------
Microsoft.DirectX.Direct3DX
    Assembly Version: 1.0.2911.0
    Win32 Version: 9.12.589.0000
    CodeBase: file:///C:/WINDOWS/assembly/GAC/Microsoft.DirectX.Direct3DX/1.0.2911.0__31bf3856ad364e35/Microsoft.DirectX.Direct3DX.dll
----------------------------------------
Microsoft.VisualC
    Assembly Version: 10.0.0.0
    Win32 Version: 12.00.52512.0 built by: VSWINSERVICING
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/Microsoft.VisualC/v4.0_10.0.0.0__b03f5f7f11d50a3a/Microsoft.VisualC.dll
----------------------------------------
Accessibility
    Assembly Version: 4.0.0.0
    Win32 Version: 4.6.1586.0 built by: NETFXREL2
    CodeBase: file:///C:/WINDOWS/Microsoft.Net/assembly/GAC_MSIL/Accessibility/v4.0_4.0.0.0__b03f5f7f11d50a3a/Accessibility.dll
----------------------------------------
OpenDentalHelp
    Assembly Version: 15.2.0.0
    Win32 Version: 1.0.0.0
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/OpenDentalHelp.DLL
----------------------------------------
Health.Direct.Common
    Assembly Version: 1.2.0.8
    Win32 Version: 1.2.0.8
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/Health.Direct.Common.DLL
----------------------------------------
AutomaticUpdater
    Assembly Version: 2.6.18.4
    Win32 Version: 2.6.18.4
    CodeBase: file:///C:/Program%20Files%20(x86)/Open%20Dental/AutomaticUpdater16.4.dll
----------------------------------------
SkinSoft.VisualStyler
    Assembly Version: 2.4.0.0
    Win32 Version: 2.4.59444.6
    CodeBase: file:///C:/WINDOWS/assembly/GAC_MSIL/SkinSoft.VisualStyler/2.4.0.0__0fda9f423e1d9830/SkinSoft.VisualStyler.dll
----------------------------------------

************** JIT Debugging **************
To enable just-in-time (JIT) debugging, the .config file for this
application or computer (machine.config) must have the
jitDebugging value set in the system.windows.forms section.
The application must also be compiled with debugging
enabled.

For example:

<configuration>
    <system.windows.forms jitDebugging="true" />
</configuration>

When JIT debugging is enabled, any unhandled exception
will be sent to the JIT debugger registered on the computer
rather than be handled by this dialog box.


Cheers,

Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA

User avatar
cmcgehee
Posts: 711
Joined: Tue Aug 25, 2015 5:06 pm
Location: Salem, Oregon

Re: OD 16.4.22: InsBenBWCodes is an invalid pref name

Post by cmcgehee » Wed Feb 15, 2017 8:06 am

Did you miss running the convert script on your database? That preference was added to the database when upgrading to 16.4.19. I'm curious as to what this query returns on the database you are using:
SELECT ValueString FROM preference WHERE PrefName LIKE 'DatabaseVersion';
Chris McGehee
Open Dental Software
http://www.opendental.com

User avatar
wjstarck
Posts: 935
Joined: Tue Jul 31, 2007 7:18 am
Location: Keller, TX
Contact:

Re: OD 16.4.22: InsBenBWCodes is an invalid pref name

Post by wjstarck » Wed Feb 15, 2017 9:36 am

16.4.19
Cheers,

Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA

allends
Posts: 235
Joined: Fri Aug 23, 2013 11:29 am

Re: OD 16.4.22: InsBenBWCodes is an invalid pref name

Post by allends » Wed Feb 15, 2017 9:50 am

Are you building and running through visual studio in debug mode?
If so, you most likely have a WebServiceServerName set.

Code: Select all

SELECT * FROM preference WHERE PrefName LIKE '%WebServiceServerName%';
If that query returns a value then you need to attempt to update the db from that computer first.
Allen
Open Dental Software
http://www.opendental.com

User avatar
wjstarck
Posts: 935
Joined: Tue Jul 31, 2007 7:18 am
Location: Keller, TX
Contact:

Re: OD 16.4.22: InsBenBWCodes is an invalid pref name

Post by wjstarck » Wed Feb 15, 2017 10:41 am

Yes, but only to build my plugin.

OD is the released beta version.

That query returns no value in ValueString column
Cheers,

Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA

User avatar
wjstarck
Posts: 935
Joined: Tue Jul 31, 2007 7:18 am
Location: Keller, TX
Contact:

Re: OD 16.4.22: InsBenBWCodes is an invalid pref name

Post by wjstarck » Wed Feb 15, 2017 11:00 am

I was able to put the code at the bottom of ConvertDatabases4 in a custom script and run it on a backup of my database. This seems to have fixed the problem.

I'll pay better attention to whether the ConvertDatabases script runs when I update in the future.

Thanks.
Cheers,

Bill Starck, DDS
Big Idea Software, LLC
Developer, EASy(Electronic Anesthesia System) for Open Dental
817-807-1709
TX, USA

User avatar
jsalmon
Posts: 1551
Joined: Tue Nov 30, 2010 12:33 pm
Contact:

Re: OD 16.4.22: InsBenBWCodes is an invalid pref name

Post by jsalmon » Wed Feb 15, 2017 1:55 pm

You probably just updated your local repository and ran your code against your database before we publicly released that version thus you only got part of the update script for that specific version. Then some time later we must have added to that convert script method which your database thought it never needed to run again. I guess that's the danger of using code prior to the official release of the version. You probably never had this problem in the past because we rarely backport bug fixes or enhancements to the code that require a convert script change.

This problem will happen again if you updated right now (we just created a 16.4.23 method in the script) and then if we haven't publicly released 16.4.23 within lets say a week and have the need to add something else to the script, you will not get the new addition to the method if you've already updated to v16.4.23 via updating your repo prior to the public release of that specific version.
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

Post Reply