It is currently March 29th, 2024, 8:58 am

Computer Serial number

Get help with installing and using Rainmeter.
kuku1223
Posts: 3
Joined: April 6th, 2017, 12:30 pm

Computer Serial number

Post by kuku1223 »

Hi Everyone,

can someone please advice me how to add computer S/N to Rainmeter information ? Being stuck with this over a week.

Huge thank you in advance ! :welcome:
User avatar
FreeRaider
Posts: 826
Joined: November 20th, 2012, 11:58 pm

Re: Computer Serial number

Post by FreeRaider »

Have a look at this page

Code: Select all

[Rainmeter]
Update=1000
DynamicWindowSize=1
AccurateText=1
[MeasureRun]
Measure=Plugin
Plugin=RunCommand
Parameter=wmic bios get serialnumber
State=Hide
OutputType=ANSI
OutputFile=#CURRENTPATH#SerialNumber.txt
RegExpSubstitute=1
Substitute="SerialNumber.*#CRLF#":"","#CRLF#":""
[MeterRun]
Meter=String
FontSize=11
FontColor=255,255,255,255
SolidColor=47,47,47,255
Padding=5,5,5,5
AntiAlias=1
Text=Click to Run
LeftMouseUpAction=[!CommandMeasure MeasureRun "Run"]
[MeterResult]
Meter=String
MeasureName=MeasureRun
Y=10R
FontSize=14
FontColor=255,255,255,255
AntiAlias=1
kuku1223
Posts: 3
Joined: April 6th, 2017, 12:30 pm

Re: Computer Serial number

Post by kuku1223 »

Awesome !!

Thank you for fast reply and
One more question is it possible to do it without that button. So it runs command automatically when Rainmeter starts?
User avatar
kyriakos876
Posts: 919
Joined: January 30th, 2017, 2:01 am
Location: Greece

Re: Computer Serial number

Post by kyriakos876 »

kuku1223 wrote:Awesome !!

Thank you for fast reply and
One more question is it possible to do it without that button. So it runs command automatically when Rainmeter starts?
Sure,

Code: Select all

[Rainmeter]
Update=1000
OnRefreshAction=[!CommandMeasure MeasureRun "Run"]

[MeasureRun]
Measure=Plugin
Plugin=RunCommand
Parameter=wmic bios get serialnumber
State=Hide
OutputType=ANSI
OutputFile=#CURRENTPATH#SerialNumber.txt
RegExpSubstitute=1
Substitute="SerialNumber.*#CRLF#":"","#CRLF#":""
This will run the command once the skin is loaded.
kuku1223
Posts: 3
Joined: April 6th, 2017, 12:30 pm

Re: Computer Serial number

Post by kuku1223 »

Perfect, Thank you for that help final code that I used is

Code: Select all

[Rainmeter]
Update=1000
OnRefreshAction=[!CommandMeasure MeasureRun "Run"]
DynamicWindowSize=1
AccurateText=1

[MeasureRun]
Measure=Plugin
Plugin=RunCommand
Parameter=wmic bios get serialnumber
State=Hide
OutputType=ANSI
OutputFile=#CURRENTPATH#SerialNumber.txt
RegExpSubstitute=1
Substitute="SerialNumber.*#CRLF#":"","#CRLF#":""

[TextServiceTag]
Meter=String
X=2
Y=480
FontSize=15
FontFace=NewMedia
FontColor=0,0,0,200
StringAlign=Left
AntiAlias=1
Text=SERVICE TAG:


[MeterRun]
Meter=String
MeasureName=MeasureRun
X=190
Y=480
FontSize=15
FontFace=NewMedia
FontColor=0,0,0,200
AntiAlias=1

--------------------------------------------------------------------------------]
Last edited by fonpaolo on April 11th, 2017, 11:32 am, edited 1 time in total.
Reason: Please use the [code] tags
User avatar
FreeRaider
Posts: 826
Joined: November 20th, 2012, 11:58 pm

Re: Computer Serial number

Post by FreeRaider »

kuku1223 wrote:Perfect, Thank you for that help final code that I used is ...
Glad to help.