I would need to manage dimensions on a customer defined table, but I can’t manage to insert a record with a 50000…99999 Table ID into table 352. Or so it seems.
I have tried many different workarounds - change SaveDefaultDim in codeunit 408, comment all the code in “Table ID” field in table 352, and such - but without succeeding. I keep getting a “There is insufficent memory (stack)…” error.
What am I missing? Is what I’m trying to achieve impossible? [^o)]
First thing, the stack out warning means that the code has entered an infinite loop.
How are you saving the default dims? Is there a Menu Item off the “Card” for your bespoke table?
What error do you get adding 50000-99999 into the Database ID?
I have just done some work around dimensions for some bespoke tables, so hopefully I can help.
Okay, I’m going to jump ahead slightly here, you might have tried this already.
Modifying Codeunit 408
You need to go to the locals in here and extend the TableIDArray Dimensions by how any tables you want to add to the Default Dimensions.
SetupObjectNoList(VAR TempObject : TEMPORARY Record Object)
NumberOfObjects := 23; ← Increase here are well. By the number of tables you want to add
TableIDArray := DATABASE::“Salesperson/Purchaser”;
TableIDArray := DATABASE::“G/L Account”;
TableIDArray := DATABASE::Customer;
TableIDArray := DATABASE::Vendor;
TableIDArray := DATABASE::Item;
TableIDArray := DATABASE::“Resource Group”;
TableIDArray := DATABASE::Resource;
TableIDArray := DATABASE::Job;
TableIDArray := DATABASE::“Bank Account”;
TableIDArray := DATABASE::Campaign;
TableIDArray := DATABASE::Employee;
TableIDArray := DATABASE::“Fixed Asset”;
TableIDArray := DATABASE::Insurance;
TableIDArray := DATABASE::“Responsibility Center”;
TableIDArray := DATABASE::“Item Charge”;
TableIDArray := DATABASE::“Work Center”;
TableIDArray := DATABASE::“Service Contract Header”;
TableIDArray := DATABASE::“Customer Template”;
TableIDArray := DATABASE::“Service Contract Template”;
TableIDArray := DATABASE::“IC Partner”;
TableIDArray := DATABASE::“Service Order Type”;
TableIDArray := DATABASE::“Service Item Group”;
TableIDArray := DATABASE::“Service Item”;
TableIDArray := DATABASE::"";
FOR Index := 1 TO NumberOfObjects DO BEGIN
IF Object.FINDFIRST THEN BEGIN
TempObject := Object;
That should allow you to add your tables into the Default Dimension Table.
I might be a bit ahead of myself, but thought I would try.
Let me know
Here’s the story of my life! I’ve been a computer programmer for more than 30 years by now! Not even a bad one, I’m told, but now and then I bump into something that doesn’t work… I bang my head on it for more than would be acceptable until I surrender to seek help. The very moment that my plea is out, I finally see the light - usually in the form of a very stupid mistake that was lying under my eyes all the time! [:@]
I had inverted the variable names in the validation code… they were maddly calling each other!
Thank you for being willing to help, forgive me for the waste of you time. [:$]
Always happens that way. You get sucked in and can’t figure the problem out, then it suddenly hits you.
Glad its all worked out