Share screen dialogue pops up after sharing a window directly using "hDirectShareAppWnd"

Thanks for sharing that information @vidattdataanalytics. Please see this post which offers a suggested workflow for programmatically sharing a window: