05-13-2009 11:39 AM
When I compiled code from CVI Labwindows 7.1.1 with CVI LabWindows 9.0, I get the error "Library function Error(return value == -42)" while debugging.
I am using Easytab and accessing a control on a different tab on the same panel. It works under CVI LabWindows 7.1.1?
05-13-2009 01:25 PM
05-13-2009 02:00 PM
my_tab = (G_TAB_SET_REC *)(gcurrent_win->tab_set_ptr);
tab_idx_LOTR = get_tab_rec_idx(my_tab,LOTR_TAB);
ResetTextBox (my_tab[tab_idx_LOTR].handle,LOTR_TAB_LOT_TABLE, '\0');
I did a side by side debug one computer running CVI 7.1.1 and another computer running CVI 9.0. the values of the handle and control are the same going into the ResetTextBox function. When the CVI 9.0 code tries to execute the ResetTextBox it returns the function error, but the CVI 7.1.1 computer works fine. If I run the CVI 9.0 compiled code on the CVI 7.1.1 computer it works fine.
Any help would be appreciated
Thanks,
Jeff
05-14-2009 04:26 AM
I have noticed that some CVI controls are unhappy in receiving a NULL pointer in place of an empty string. It is possible that this behaviour has changed for the ResetTextBox() function between V.7 and V.9. Instead of:
ResetTextBox (my_tab[tab_idx_LOTR].handle,LOTR_TAB_LOT_TABLE, '\0') ;
where the final NUL character is interpreted as a NULL pointer, try using:
ResetTextBox (my_tab[tab_idx_LOTR].handle,LOTR_TAB_LOT_TABLE, "") ;
where it is a conventional empty string.
JR