Phidget.WriteText
-----------------

Writes text to a LCD screen.

| Component | Version | macOS | Windows | Linux | Server | iOS SDK |
|---|---|---|---|---|---|---|
| [Phidget](component_Phidget.md) | [13.4](newinversion134.md) | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ❌ No |

MBS( "Phidget.WriteText"; PhidgetRef; Font; xPosition; yPosition; Text ) 

**MBS**( **"Phidget.WriteText";** /\* Writes text to a LCD screen. \*/  
**$PhidgetRef**; /\* The reference number for the phidget.e.g. $phidget \*/   
**$Font**; /\* The font of the text.  
Pass 3 for 6x10 font, 4 for 5x8 font and 5 for 6x12 font.e.g. 5 \*/   
**$xPosition**; /\* The X position of the start of the text string.e.g. 0 \*/   
**$yPosition**; /\* The Y position of the start of the text string.e.g. 0 \*/   
**$Text**) /\* The text to be written.e.g. "Hello" \*/ 

### Parameters

| Parameter | Description | Example |
|---|---|---|
| PhidgetRef | The reference number for the phidget. | $phidget |
| Font | The font of the text.   Pass 3 for 6x10 font, 4 for 5x8 font and 5 for 6x12 font. | 5 |
| xPosition | The X position of the start of the text string. | 0 |
| yPosition | The Y position of the start of the text string. | 0 |
| Text | The text to be written. | "Hello" |

### Result

Returns OK or error.

### Description

Writes text to a LCD screen.  
This function writes text to the current frame buffer at the specified location.  
Changes made to the frame buffer must be flushed to the LCD screen using [Phidget.Flush](PhidgetFlush.md).  
### Examples

Output some text to LCD:

 Set Variable \[ $r ; Value: MBS ( "[Phidget.Clear](PhidgetClear.md)"; $$phidget ) \]   
\# write some text   
Set Variable \[ $r ; Value: MBS ( "Phidget.WriteText"; $$phidget ; 4; 0; 0; "Hello" ) \]   
\# and send all now   
Set Variable \[ $r ; Value: MBS ( "[Phidget.Flush](PhidgetFlush.md)"; $$phidget ) \]  
### See also

- [Phidget.Clear](PhidgetClear.md)
- [Phidget.Flush](PhidgetFlush.md)
- [Phidget.WriteRFID](PhidgetWriteRFID.md)

### Example Databases

- [Phidgets/Phidget LCD](https://www.mbsplugins.eu/MBS-FileMaker-Plugin-Examples/Phidgets/Phidget%20LCD.shtml#8ScriptAnchor_)

Created 16th August 2023 , last changed 17th August 2023

  
[Phidget.WriteRFID](PhidgetWriteRFID.md) - [PhotoPicker.Available](PhotoPickerAvailable.md)

[HTML Version](PhidgetWriteText.shtml)