ComfyUI > Nodes > ComfyUI-RvTools_v2 > String Switch

ComfyUI Node: String Switch

Class Name

String Switch [RvTools]

Category
🫦 RvTools II/ Switches
Author
r-vage (Account age: 317days)
Extension
ComfyUI-RvTools_v2
Latest Updated
2026-03-27
Github Stars
0.02K

How to Install ComfyUI-RvTools_v2

Install this extension via the ComfyUI Manager by searching for ComfyUI-RvTools_v2
  • 1. Click the Manager button in the main menu
  • 2. Select Custom Nodes Manager button
  • 3. Enter ComfyUI-RvTools_v2 in the search bar
After installation, click the Restart button to restart ComfyUI. Then, manually refresh your browser to clear the cache and access the updated list of nodes.

Visit ComfyUI Online for ready-to-use ComfyUI environment

  • Free trial available
  • 16GB VRAM to 80GB VRAM GPU machines
  • 400+ preloaded models/nodes
  • Freedom to upload custom models/nodes
  • 200+ ready-to-run workflows
  • 100% private workspace with up to 200GB storage
  • Dedicated Support

Run ComfyUI Online

String Switch Description

The String Switch node enables dynamic selection between two strings based on a condition.

String Switch [RvTools]:

The String Switch [RvTools] node is designed to facilitate the selection between two string inputs based on a specified condition. This node is particularly useful when you need to dynamically choose between different string values during the execution of a workflow. By providing a simple mechanism to switch between two options, it enhances the flexibility and adaptability of your workflow, allowing for more dynamic and responsive designs. The primary goal of this node is to streamline decision-making processes within your projects, making it easier to manage and manipulate string data based on predefined conditions.

String Switch [RvTools] Input Parameters:

Input

The Input parameter is an integer that determines which of the two string inputs will be selected and returned by the node. It accepts values of either 1 or 2, with a default value of 1. When set to 1, the node will return the first string input (input1), and when set to 2, it will return the second string input (input2). This parameter is crucial for directing the flow of data within your workflow, allowing you to control which string is utilized based on your specific requirements.

input1

The input1 parameter is an optional string input that serves as one of the potential outputs of the node. It is required to be provided if you intend to use it as a selectable option. This parameter allows you to specify the first string value that can be chosen based on the Input parameter's value.

input2

The input2 parameter is another optional string input that acts as the alternative output of the node. Similar to input1, it must be provided if you wish to use it as a selectable option. This parameter enables you to define the second string value that can be selected depending on the Input parameter's setting.

String Switch [RvTools] Output Parameters:

string

The string output parameter is the result of the node's execution, returning the selected string based on the Input parameter's value. This output is crucial as it provides the dynamically chosen string that can be used in subsequent nodes or processes within your workflow. The ability to switch between different string outputs based on conditions enhances the versatility and functionality of your projects.

String Switch [RvTools] Usage Tips:

  • Ensure that both input1 and input2 are provided if you want the flexibility to switch between two different strings. This will allow you to fully utilize the node's capabilities.
  • Use the Input parameter to dynamically control which string is selected, enabling you to create more adaptive and responsive workflows that can adjust to varying conditions or inputs.

String Switch [RvTools] Common Errors and Solutions:

Missing Input: Multi String Switch has no active Input

  • Explanation: This error occurs when neither input1 nor input2 is provided, leaving the node without a valid string to return.
  • Solution: Ensure that at least one of the optional string inputs (input1 or input2) is provided to avoid this error and allow the node to function correctly.

String Switch Related Nodes

Go back to the extension to check out more related nodes.
ComfyUI-RvTools_v2
RunComfy
Copyright 2025 RunComfy. All Rights Reserved.

RunComfy is the premier ComfyUI platform, offering ComfyUI online environment and services, along with ComfyUI workflows featuring stunning visuals. RunComfy also provides AI Models, enabling artists to harness the latest AI tools to create incredible art.

String Switch