i am getting an error when uploading

i am getting this error message: avrdude: ser_open(): can't set com-state for "\.\COM5"
i tried uploading the same code on an other laptop and it works but i need it to work on my own one.
i am using windows 10


i hope some one can help me

That error usually means that you have not set the Port correctly in IDE/Tools/Port i.e. your Arduino is not actually on COM5.