Difference between revisions of "Disk.getLabel"

From ComputerCraft Wiki
Jump to: navigation, search
(anh con may voi nhau xem nha)
m (Use type template)
 
(5 intermediate revisions by 5 users not shown)
Line 1: Line 1:
Hello my friend heres my new gig easy as it looks Ill send u a total of 5350++ backlinks to your website in 2 tiers. This gig its for 1 website and up to 5 keywords. First tier to your main website 350 page rank 1-5 and the the second tier of 5000 profile backlinks pointing to your first tier.Ill send u a report in a txt file in less than 48 hours.Any question just send me a private message
+
{{lowercase}}
 +
{{Function
 +
|name=disk.getLabel
 +
|args={{Type|string}} side
 +
|api=disk
 +
|returns={{Type|string}} disk label, or [[nil]] if the item in the drive is neither a floppy disk nor a music record or if it is a floppy disk with no label
 +
|addon=ComputerCraft
 +
|desc=Reads the label from the disk in the drive. This is the label that shows up in the item tooltip (for both [[Floppy Disk|floppy disks]] and music records). For floppy disks, the label can be set with [[disk.setLabel]].
 +
|examples=
 +
{{Example
 +
|desc=Checks for data saved on the disk in the bottom drive
 +
|code=print(disk.getLabel("bottom"))
 +
|output=Floppy --'''Output changes according to the disk label'''
 +
}}
 +
}}
 +
 
 +
[[Category:API_Functions]]

Latest revision as of 19:12, 22 April 2013


Grid Redstone.png  Function disk.getLabel
Reads the label from the disk in the drive. This is the label that shows up in the item tooltip (for both floppy disks and music records). For floppy disks, the label can be set with disk.setLabel.
Syntax disk.getLabel(string side)
Returns string disk label, or nil if the item in the drive is neither a floppy disk nor a music record or if it is a floppy disk with no label
Part of ComputerCraft
API disk

Examples

Grid paper.png  Example
Checks for data saved on the disk in the bottom drive
Code
print(disk.getLabel("bottom"))
Output Floppy --Output changes according to the disk label