Error handling on form responses

Hello,

I am currently creating an app that allows users to do algorithmic trading. In designing the front end, users are able to select which stocks they want to trade by their NASDAQ stock symbol, [NYSE stock symbol (http://eoddata.com/stocklist/NYSE/S.htm), or otherwise in a form view.

Given that listing out every possible stock symbol in an enum is rather difficult, I give users the option to enter their own symbols. However, I donโ€™t want users entering symbols that are invalid, i.e. donโ€™t belong to any particular company. For example AAPL is fine but something like AAPLXDT is not.

Is there a way to generate an error for invalid values โ€œon the flyโ€, that is, as a user is entering a value into a form, it automatically checks against an established stock API using a REST call (or something along these lines) if the symbol is valid or not before the form is submitted?

Thanks!

0 1 163
1 REPLY 1

Steve
Platinum 4
Platinum 4

Nope. All valid values must be known to the app in advance if you want to give the user immediate(-ish) feedback.

Top Labels in this Space