jhony Posted May 15, 2017 Report Share Posted May 15, 2017 Hi I am new to labview .i am using tab control consisiting of four pages. if i click next button it should goto page 2.if i click previous button it should go to page 1.can any one help me please Quote Link to comment
LogMAN Posted May 15, 2017 Report Share Posted May 15, 2017 You can use tabs like regular numbers. Increment to get to the next page, decrement to get to the previous one. This is an example: Of course you need to add additional checks to prevent the "Previous" button to skip from page 1 to page 5 and things like that. Quote Link to comment
eberaud Posted May 15, 2017 Report Share Posted May 15, 2017 In a slightly more advanced way, you can use a property node to get the array of pages (references). The number of elements in that array is the number of pages, so you can use this number instead of the constant for the comparison LogMAN is using to stop the loop. 1 Quote Link to comment
hooovahh Posted May 15, 2017 Report Share Posted May 15, 2017 Or even better there is an OpenG function that given an enum will return all the unique values of an enum, and it works just the same on a tab (since a tab uses an enum for its value). This function is under the LabVIEW Data package named Get Strings from Enum. Then there is no need for reference or property nodes. Quote Link to comment
infinitenothing Posted May 15, 2017 Report Share Posted May 15, 2017 You can also use this NI function to get a list of enums strings from an enum: http://zone.ni.com/reference/en-XX/help/371361M-01/glang/get_numeric_information/ 2 Quote Link to comment
hooovahh Posted May 15, 2017 Report Share Posted May 15, 2017 Native support? Even better. I knew those Variant functions were on the palette but for some reason didn't realize that was one of them. Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.