Skip to main content
1-Visitor
January 17, 2026
Question

ProXsecCompXhatchStyleSet&Hatch

  • January 17, 2026
  • 3 replies
  • 489 views

I'm a student and I have a question. Could you please explain how to use the method "ProXsecCompXhatchStyleSet"? I want to change the pattern of the section lines in the perspective view, but I'm not sure how to use this API or how to use other related APIs. Can someone help me?

3 replies

24-Ruby III
January 17, 2026
Community Manager
January 23, 2026

Hello @ML_14468763,

 

It looks like you have a response from a community expert. If it helped you solve your question please mark the reply as the Accepted Solution. 
Of course, if you have more to share on your issue, please let the Community know so other community members can continue to help you.

Thanks,
Vivek N.
Community Moderation Team.

5-Regular Member
February 26, 2026
ProXsec p_xsec; 
ProError status;
ProColor warning_color;
ProXsecNewXhatchStyle p_xhatch_style{};
warning_color.method = PRO_COLOR_METHOD_TYPE;
warning_color.value.type = PRO_COLOR_WARNING;
 
status = ProXsecNewXhatchStyleCreateFromName(L"Wood", warning_color, PRO_XHATCH, &p_xhatch_style);
if (status != PRO_TK_NO_ERROR)
return;
 
ProXSectionItem* xsec_item_arr;
ProXsecMdlname p_xsecmdlname;
status = ProXsecMdlnameAlloc(xsecMdl, p_xsec.xsec_name, &p_xsecmdlname);
if (status != PRO_TK_NO_ERROR)
return;
status = ProXSectionItemsCollect(p_xsecmdlname, NULL, &xsec_item_arr);
if (status != PRO_TK_NO_ERROR)
return;
 
int n_xsec_items = 0;
status = ProArraySizeGet((ProArray)xsec_item_arr, &n_xsec_items);
 
for (int ii = 0; ii < n_xsec_items; ii++)
{
status = ProXSectionItemXhatchStyleSet(xsec_item_arr[ii], item.view, L"Wood", &p_xhatch_style);
}
status = ProXSectionItemsArrFree((ProXSectionItem**)&xsec_item_arr);
ProXsecRegenerate(&p_xsec);
10-Marble
March 3, 2026

@XC_14458268  Thank you so much, I was stuck into this finally got it right.

 

 

 

 

5-Regular Member
March 5, 2026

You're welcome! I happened to be looking into this as well. Glad you got it sorted!