Hi @nivyus. Do you mean like this (see code below)? This gets the list of PartsListStyle names, then shows that to you so you can select the one you want, then applies the chosen style to the parts list. This is just a simple example to show you how to do that, if that is what you wanted. I also included some commented out lines of code for exporting the parts list to Excel, but those settings would likely all have to be changed to suit your needs.
oDDoc = ThisDrawing.Document
oSheet = oDDoc.ActiveSheet
If oSheet.PartsLists.Count = 0 Then Exit Sub
Dim oPList As PartsList = oSheet.PartsLists.Item(1)
oPListStyles = oDDoc.StylesManager.PartsListStyles
Dim oPListStyleNames As New List(Of String)
For Each oPLStyle As PartsListStyle In oPListStyles
oPListStyleNames.Add(oPLStyle.Name)
Next
oPLStyleName = InputListBox("Choose PartsList Style.", oPListStyleNames, oPListStyleNames.Item(1), "PartsList Styles")
If String.IsNullOrEmpty(oPLStyleName) Then Exit Sub
oStyle = oPListStyles.Item(oPLStyleName)
oPList.Style = oStyle
'oOptions = ThisApplication.TransientObjects.CreateNameValueMap
'oOptions.Add("TableName", oPList.Title)
''oOptions.Add("ExportedColumns", "ColumnTitle1 ; ColumnTitle2")
'oOptions.Add("IncludeTitle", True)
'oOptions.Add("StartingCell", "A1")
'oOptions.Add("Template", "C:\Temp\PartsList Export Template.xls")
'oOptions.Add("AutoFitColumnWidth", True)
'oPList.Export("C:\Temp\PartsList 1.xls", PartsListFileFormatEnum.kMicrosoftExcel, oOptions)
If this solved your problem, or answered your question, please click ACCEPT SOLUTION.
Or, if this helped you, please click (LIKE or KUDOS) 👍.
If you want and have time, I would appreciate your Vote(s) for My IDEAS 💡 or you can Explore My CONTRIBUTIONS
Wesley Crihfield

(Not an Autodesk Employee)