you'll remember my fight with the "Kunden" window in my _kv project i sent you some time ago. The form failed to display, while a stddatawindow, which VO uses in "File-Open", works.
Digging around, i now built a new dtaWindow from designer, using "my" basewindow class and added only two sles for kdno and name. And, i assigned directly "my" db, inherited from my baseserverclass. Then modified the shellmenu to call this form - and this works.
Now, i added a mle to the form for the free-text field of my db- and the exception is back. Remove the mle, all ok.
The point is, could it be, that there's a problem with the fieldname? The free-text field is named "Memo" (don't ask me why, did that a very long time ago)...
I ask this, as in another app, which uses the same form and serverbases, i don't see such a problem, but there the memo-field uses another name.
i changed the name of my DBFCDX memofield to "MEMO" and there are no problems. When i open my DtaDlg window i see the content of each memo in my MLE. When i change in XIDE the dtaDlg layout and restart, there are still no problems.
unfortunately, it's not so easy...
1) There is no problem viewing/manipulating the table via StdDatawindow, as Vo etc. use, when i open with File-Open from the StandardMdi-Sample.
2) There is no problem, if i open it with the generic Datawindow in my app, which uses my customized serverclass, but displays with a enhanced StdDatawindow based on my dtaWinbase class.
3) There is no problem, if i show a dtaWinbase using the custom server, as long as this window has no control which references the memo field.
4) There is a crash, when i open using my enhanced "dtaKunden" window based on the same dtaWinbase, using the same custom server.
So, it seems there should be a problem with dtaKunden, but that does not give an explanation for #3, nor does dtaKunden contain any "special" things. It was autogenerated x-years ago, arranged, and got a bunch of buttons to start some actions, that's all.
FTR, i use only datawindows, no dtadialogs...
One week of holiday is left, will continue hunting...
further into the "Kunden" issue: With the new build i see now on opening the window the exeption pointing to the access of my field "Straße".
Went to dbServereditor in Xide und hit export, and get "Field STRAßE has invalid values" (casing of fieldname as shown, the lowercase character is the german "sharp s", replacing "ss").
Could that create the problem? In similar apps i always named "STRASSE" and have no problem...
Replaced the definitions, fieldspecs etc, no go ;-(
Beschreibung : Der Index lag außerhalb des Bereichs. Er darf nicht negativ und kleiner als die Sammlung sein.
Subsystem : BASE
Generischer Code : EG_EXCEPTION Exception ausgelöst durch CLR oder exteren Code
FuncSym : OOPHELPERS:IVARGET
Schwere : ES_ERROR
Kann Default : False
Kann erneut versuchen : False
Kann ersetzen : False
bei System.ThrowHelper.ThrowArgumentOutOfRangeException(ExceptionArgument argument, ExceptionResource resource)
bei XSharp.__Array.__GetElement(Int32 index)
bei XSharp.__Array.get_Item(Int32 index)
bei dbBufferedServer.FIELDGET(__Usual Xs$Args) in C:\XIDE\Projects\kv4\Applications\MSG_dbServerLib\Prg\dbBufferedServer.prg:Zeile 156.
bei pdb_Kunden.get_STRASSE() in C:\XIDE\Projects\kv4\Applications\DB_Dict_KV\Prg\pdb_Kunden.prg:Zeile 308.
ACCESS STRASSE AS STRING PASCAL
RETURN SELF:FieldGet(#STRASSE) // this is line 308
If i open the table with the generic FileOpen from the app, it displays & skips fine, all values and memo values are in place.
If i open the table with my generic FileOpen, which uses "my" DBServer for this table, it fails, but here accessing the memo field.
Next steps: i'll zap the table - this should take care of any table corruption, no?
If that helps, i'll do what you suggested long ago, rewrite the table by hand
If it does not, i'm finally at a loss, i think.
Please create a new app, add in it the code of "your" DBServer that causes the problem in your original app and load in it the same dbf file the same way as you do in your main app. If the error happens again, please zip the project and send it to me (let's try .7z format) to have a look. If it doesn't, it means that something else in the main app isa causing the problem.