When searching for an arduino library to control X9Cxxx family digital potentiometers, found some old 2011 forum post that just does the job. Unfortunately this library was not available under arduino IDE's library manager. So I decided to put it in there.
The original forum post: click here
The original website: click here
Datasheet: click here
Hope it helps! Have a good day.