getting the rotation of another object

so i want to get the rotation (as vector3) of another object. with every option i have tried i got 0, 0, 0 as outcome. can anyone please help?

From the documentation, for a given gameobject: transform.eulerAngles

That gives you the rotation as a vector3 in world coordinates.

Show us your code!

public Transform box;
private Vector3 boxrot;

boxrot = new Vector3(box.rotation.eulerAngles.x,box.rotation.eulerAngles.y,
box.rotation.eulerAngles.z);

this is what i have in the void start, in the void update i have a debug log of “boxrot”