Author Topic: Product Code to Report  (Read 2383 times)

0 Members and 1 Guest are viewing this topic.

Offline ayoung8901Topic starter

  • Full Member
  • ***
  • Posts: 55
  • Country: us
  • Gender: Male
Product Code to Report
« on: Jul 11, 2019, 20:29:33 PM »
Does anyone know how to make the "Product ID" show up on a report?

Thanks!

Offline craigjonnson

  • Full Member
  • ***
  • Posts: 248
  • Country: au
  • Gender: Male
Re: Product Code to Report
« Reply #1 on: Jul 11, 2019, 23:16:25 PM »
Select Database ID Code on your report builder.

Offline ayoung8901Topic starter

  • Full Member
  • ***
  • Posts: 55
  • Country: us
  • Gender: Male
Re: Product Code to Report
« Reply #2 on: Jul 12, 2019, 12:41:45 PM »
I had found that in the report builder, and it unfortunately does not show the Product Code, or anything for that matter. Is there another 'connection' of that ID that needs to be somewhere else in the database to make it show up?

Thanks

Offline bknapton

  • Premier Member
  • *****
  • Posts: 968
  • Country: us
  • Gender: Male
    • Mared Mechanical
Re: Product Code to Report
« Reply #3 on: Jul 12, 2019, 13:00:54 PM »
You want the product code for material you setup in a specification?
Fabrication 2019

Offline ayoung8901Topic starter

  • Full Member
  • ***
  • Posts: 55
  • Country: us
  • Gender: Male
Re: Product Code to Report
« Reply #4 on: Jul 12, 2019, 13:54:52 PM »
Yes. What we are looking for is a way to show what Coil is being used on each of the items, so when our inventory control manager enters this into our system they can easily reference the Product Code to match their inventory number. This eventually will go alot further with liner and what not. So for this i was hoping to show the Product Code on my Decoil shop tickets.

Hope this makes sense.


Offline bobcat09

  • Senior Member
  • ****
  • Posts: 490
  • Country: us
  • Gender: Male
Re: Product Code to Report
« Reply #5 on: Jul 12, 2019, 14:07:04 PM »
I was digging into this a while back, similar to what you are wanting to do, report out the material by code. What I found, that code is only accessible through Nest Reports and after nesting, using the Sheet Product Code print object. Doesn't really work with anything decoiled since it's not nesting.
Lyle Janda
TDIndustries
Windows 10- AutoCAD - CADmep - ESTmep - CAMduct - Revit - Navisworks

Offline ayoung8901Topic starter

  • Full Member
  • ***
  • Posts: 55
  • Country: us
  • Gender: Male
Re: Product Code to Report
« Reply #6 on: Jul 12, 2019, 19:16:31 PM »
Thanks for this information, this will atleast help me with our Plasma/Waterjet nests.

It would be nice if there was a better way to extract information from the decoiler besides a dummy txt file.

Offline aleschper

  • Full Member
  • ***
  • Posts: 73
  • Country: us
  • Gender: Male
Re: Product Code to Report
« Reply #7 on: Jan 26, 2022, 20:48:04 PM »
I was digging into this a while back, similar to what you are wanting to do, report out the material by code. What I found, that code is only accessible through Nest Reports and after nesting, using the Sheet Product Code print object. Doesn't really work with anything decoiled since it's not nesting.
This information needs to be available in the Item reports as well. It not being there is, well, stupid. Or maybe shortsighted is a better description.
Andrew Leschper
2019/20 Version
Jack of All Trades

Offline ThermaNorCal

  • Active Member
  • **
  • Posts: 1
  • Country: us
  • Gender: Male
Re: Product Code to Report
« Reply #8 on: Jun 07, 2022, 20:38:06 PM »
I was digging into this a while back, similar to what you are wanting to do, report out the material by code. What I found, that code is only accessible through Nest Reports and after nesting, using the Sheet Product Code print object. Doesn't really work with anything decoiled since it's not nesting.
This information needs to be available in the Item reports as well. It not being there is, well, stupid. Or maybe shortsighted is a better description.

We are implementing ERP software and this is my only hang-up, reporting coil used and associating it with a Product ID.  This seems like a no-brainer, we can associate sheet with a Product ID through Nest Reports but nothing in Item Reports.

Offline bobcat09

  • Senior Member
  • ****
  • Posts: 490
  • Country: us
  • Gender: Male
Re: Product Code to Report
« Reply #9 on: Jun 07, 2022, 20:43:38 PM »
As stated before, since the decoil process is not nesting, there's nothing the report can pull. I don't see any print objects for decoil material usage via a code. And good luck getting AD to add it.
Lyle Janda
TDIndustries
Windows 10- AutoCAD - CADmep - ESTmep - CAMduct - Revit - Navisworks

Offline dopefish

  • Senior Member
  • ****
  • Posts: 414
  • Country: us
  • Gender: Male
Re: Product Code to Report
« Reply #10 on: Jun 10, 2022, 15:13:35 PM »
Has anyone sifted through the API to see if this is accessible? IF not I'm going to start.
"And the wood header is still 4  3/4" on top of the top of the double top plate." . . . Random VDC Coodinator

I love coordination

Offline DotNet

  • Senior Member
  • ****
  • Posts: 302
  • Country: us
  • Gender: Male
    • MICLOGIC
Re: Product Code to Report
« Reply #11 on: Jun 10, 2022, 15:50:50 PM »
Has anyone sifted through the API to see if this is accessible? IF not I'm going to start.

PrintObjects in the API are broken up into 4 groups. Ancillary, Item, Job, and Part. The "Part" print object looks interesting here but I have never used this one.

Code: [Select]
CombinedItemNo_PartNo_Devs 917 
 DevelopmentBlankSize 430 
 DevelopmentFillerPartFlag 5331 
 DevelopmentHeight 431 
 DevelopmentPartIndex 5189 
 DevelopmentRotaryDiameter 915 
 DevelopmentWidth 432 
 PartBendingInformation 360 
 PartDevelopmentName 114 
 PartInsulationFlag 186 
 PartMaterialAbrv 182 
 PartMaterialDenity 255 
 PartMaterialGauge 183 
 PartMaterialStandard 5138 
 PartNameIndex 5177 
 PartNoInItem 21 
 PartQty 208 
 PartSkinFlag 5048 
 PartUserDefinedField 5464 
 DevelopmentMaterialGauge 909 
 DevelopmentMaterial 910 
 DevelopmentWeight 907 
 DevelopmentArea 902 
 DevelopmentBaseQty 903 
 DevelopmentNestedQty 904 
 DevelopmentGauge 911 
 DevelopmentInsulationFlag 908 
 DevelopmentDefaultSheetSize 913 
 DevelopmentExportFilename 912 
 DevelopmentPartBendingInformation 918

Offline dopefish

  • Senior Member
  • ****
  • Posts: 414
  • Country: us
  • Gender: Male
Re: Product Code to Report
« Reply #12 on: Jun 12, 2022, 02:30:36 AM »
Code: [Select]
public void GetMaterialProdID()
        {
            Document doc = Autodesk.AutoCAD.ApplicationServices.Application.DocumentManager.MdiActiveDocument;
            Autodesk.AutoCAD.DatabaseServices.Database curDB = doc.Database;
            Editor ed = doc.Editor;
            using (Transaction trans = curDB.TransactionManager.StartTransaction())
            {
                PromptSelectionResult acSSPrompt = ed.GetSelection();

                if (acSSPrompt.Status == PromptStatus.OK)
                {
                    SelectionSet acSSet = acSSPrompt.Value;

                    foreach (SelectedObject acSSObj in acSSet)
                    {
                        if (acSSObj != null)
                        {
                            Entity acEnt = trans.GetObject(acSSObj.ObjectId,
                                                            OpenMode.ForRead) as Entity;

                            if (acEnt != null)
                            {
                                Item myItem = Job.GetFabricationItemFromACADHandle(acEnt.Handle.ToString());

                                if (myItem != null)
                                {
                                    ed.WriteMessage("This if then is working!!!");
                                    string materialCode = myItem.Material.Id.ToString();
                                    ed.WriteMessage(myItem.Material.ToString());
                                    ed.WriteMessage(myItem.Material.Gauges.ToString());
                                    ed.WriteMessage(myItem.Ancillaries.ToString());
                                    ed.WriteMessage(myItem.Material.Source.ToString());
                                    ed.WriteMessage(myItem.Material.Name.ToString());

                                }
                            }

                           
                        }
                    }

                    trans.Commit();
                }
            }
        }

so here is where i am just trying to debug a few things into the command line.
Material.ID doesn't seem to want to print. I have a sneaking suspicion that is what we are trying to access here. I am going to keep digging.
"And the wood header is still 4  3/4" on top of the top of the double top plate." . . . Random VDC Coodinator

I love coordination