Forum Migration Notice
Update (2026-01-21): The user forums are now in read-only mode pending the data migration.
Update (2026-01-12): The user forums will be put into read-only mode on the 21st of January, 00:00 CET, to prepare for the data migration.
We're transitioning to a more modern community platform by beginning of next year. Learn about the upcoming changes and what to expect.
Update (2026-01-12): The user forums will be put into read-only mode on the 21st of January, 00:00 CET, to prepare for the data migration.
We're transitioning to a more modern community platform by beginning of next year. Learn about the upcoming changes and what to expect.
How to create a default value for inputs in a function
kentz
✭
in RobotStudio
I want to achieve something like proc main(a, b, c, d), where input c and d get hardly changed. Is there a default value that i can set to c and d when i can just go main a,b; ?
and when i do want to change c and d value i'll go main a, b, c,d;
Regards
Kent
0
Best Answer
-
Yes, they'd be optional arguments.
See how the wobj argument is checked for presence, then only used if present in Example 1:
http://developercenter.robotstudio.com/BlobProxy/manuals/RapidIFDTechRefManual/doc369.html
5
Answers
-
Thank you soup, that's exactly all i need. And you've just pointed me to a awesome place for programming references.soup said:Yes, they'd be optional arguments.
See how the wobj argument is checked for presence, then only used if present in Example 1:
http://developercenter.robotstudio.com/BlobProxy/manuals/RapidIFDTechRefManual/doc369.html0
Categories
- All Categories
- 5.7K RobotStudio
- 402 UpFeed
- 21 Tutorials
- 16 RobotApps
- 307 PowerPacs
- 407 RobotStudio S4
- 1.8K Developer Tools
- 251 ScreenMaker
- 2.9K Robot Controller
- 368 IRC5
- 92 OmniCore
- 8 RCS (Realistic Controller Simulation)
- 859 RAPID Programming
- 43 AppStudio
- 4 RobotStudio AR Viewer
- 19 Wizard Easy Programming
- 111 Collaborative Robots
- 5 Job listings
