Petrel - Ocean - Get well name and type

244 Views Asked by At

I'm getting all boreholes (Borehole Collection) from my Petrel project using the following code:

WellRoot wr = WellRoot.Get(PetrelProject.PrimaryProject);   
BoreholeCollection bhc = wr.BoreholeCollection;  

I can get the borehole name (bellow code), but I'm struggling to find the type of this borehole (producer or injector) and what simulation case this borehole is comming from (I have two simulation cases in my Petrel project).

foreach (Borehole bh in bhc)
  PetrelLogger.InfoOutputWindow("Borehole name " + bh.Name); 

Anyone could help me?

Thanks in advance!

1

There are 1 best solutions below

1
ThomasG On

This touches the display/UI domain; the access is decoupled via

Borehole borehole; // this is the object you have
IBoreholeSettingsFactory factory = CoreSystem.GetService<IBoreholeSettingsFactory>();
IBoreholeSettings settings = factory.GetBoreholeSettings(borehole);
WellSymbolDescription symbolDescription = settings.WellSymbol;