No, there are no direct train connections from Amsterdam to Barcelona. To travel by train from Amsterdam to Barcelona you must change trains at least once. This is done in Paris.