View Single Post
  #2   Spotlight this post!  
Unread 21-03-2016, 18:58
jreneew2's Avatar
jreneew2 jreneew2 is offline
Alumni of Team 2053 Tigertronics
AKA: Drew Williams
FRC #2053 (TigerTronics)
Team Role: Programmer
 
Join Date: Jan 2014
Rookie Year: 2013
Location: Vestal, NY
Posts: 192
jreneew2 has a spectacular aura aboutjreneew2 has a spectacular aura aboutjreneew2 has a spectacular aura about
Re: NetworkTables compile issues

All you have to do is use the same function with different parameters. Instead of:

table->GetNumber("x");

do this instead

table->GetNumber("x", 0.0);

This just sets a default value for that value in the table in case the robot is not connected to the driver station yet. If it didn't it would throw an exception, like it says in the error.