AddLabel text Alt Codes For ThinkOrSwim

AndrewPnF

New member
After much research and experiments, just thought I'd share something I invented.

On my labels I'm always trying to find ways to limit the number of characters displayed, if I can. I tend to get too wordy at times just to be clear to myself, but..... I'd fill the screen if not held in check.

On label text where I used to put "Up" or "Down", I'm trying to substitute something shorter. I stumbled upon a resource somewhere that talked about using Alt Codes and found that it worked. There are only a couple that I use. The Up Arrow and Down Arrow are nice but a little timid. The Up triangle and Down triangle appear more convincing on the label. Those are Alt+30 for the Up and Alt+31 for the Down Alt+24 and Alt+25 are the Up and Down Arrows. To add an Alt code, you hold down Alt and type 30 and release Alt and you should have an Up triangle in your text part of the label.

OK, I didn't invent it. That was hyperbole.... but hopefully you find it to be of use perhaps.

Code:
addlabel(labelW,
if Periods > 0 and Periods[1] < 0 then "TrendW ▲ " + round((close + high[1])/2,1) else if Periods > 0 and Periods[1] > 0 and Periods[2] < 0 then "TrendW1 ▲ "  + round((close[1] + high[2])/2,1) else if Periods > 0 and Periods[1] > 0 and Periods[2] > 0 and Periods[3] < 0 then "TrendW2 ▲ "  + round((close[2] + high[3])/2,1) else "",color.blue,location.BOTTOM_LEFT, fontSize.MEDIUM);
 
Last edited by a moderator:
does this actually work for people?
all i see in the label are rectangles, not shapes
i see the shapes in the code. i replaced the shapes by typing the alt codes. nothing


you posted partial code, with undefined variables.
here is a simpler version. doesn't work for me.

Code:
AddLabel(1,
  " TrendW ▲ " + Round((close + high[1]) / 2, 1) +
  " TrendW1 ▲ " + Round((close[1] + high[2]) / 2, 1) +
  " TrendW2 ▼ " + Round((close[2] + high[3]) / 2, 1)
, color.yellow);
 

Attachments

  • img2.JPG
    img2.JPG
    8.2 KB · Views: 23
does this actually work for people?
all i see in the label are rectangles, not shapes
i see the shapes in the code. i replaced the shapes by typing the alt codes. nothing


you posted partial code, with undefined variables.
here is a simpler version. doesn't work for me.

Code:
AddLabel(1,
  " TrendW ▲ " + Round((close + high[1]) / 2, 1) +
  " TrendW1 ▲ " + Round((close[1] + high[2]) / 2, 1) +
  " TrendW2 ▼ " + Round((close[2] + high[3]) / 2, 1)
, color.yellow);
Sorry, I should have put complete INSTRUCTIONS in the text.

This works only with the Number Pad, not with the numbers at the top of the keypad.

Hold down Alt and type in the number on the number pad. Release the Alt and you should have a symbol appear in the thinkscript editor.
 

Join useThinkScript to post your question to a community of 21,000+ developers and traders.

Similar threads

Not the exact question you're looking for?

Start a new thread and receive assistance from our community.

87k+ Posts
371 Online
Create Post

Similar threads

Similar threads

The Market Trading Game Changer

Join 2,500+ subscribers inside the useThinkScript VIP Membership Club
  • Exclusive indicators
  • Proven strategies & setups
  • Private Discord community
  • ‘Buy The Dip’ signal alerts
  • Exclusive members-only content
  • Add-ons and resources
  • 1 full year of unlimited support

Frequently Asked Questions

What is useThinkScript?

useThinkScript is the #1 community of stock market investors using indicators and other tools to power their trading strategies. Traders of all skill levels use our forums to learn about scripting and indicators, help each other, and discover new ways to gain an edge in the markets.

How do I get started?

We get it. Our forum can be intimidating, if not overwhelming. With thousands of topics, tens of thousands of posts, our community has created an incredibly deep knowledge base for stock traders. No one can ever exhaust every resource provided on our site.

If you are new, or just looking for guidance, here are some helpful links to get you started.

What are the benefits of VIP Membership?
VIP members get exclusive access to these proven and tested premium indicators: Buy the Dip, Advanced Market Moves 2.0, Take Profit, and Volatility Trading Range. In addition, VIP members get access to over 50 VIP-only custom indicators, add-ons, and strategies, private VIP-only forums, private Discord channel to discuss trades and strategies in real-time, customer support, trade alerts, and much more. Learn all about VIP membership here.
How can I access the premium indicators?
To access the premium indicators, which are plug and play ready, sign up for VIP membership here.
Back
Top