This program is suppose to only display one name and number after the buttom is pressed. But the problem is it only displays the first name and number after the button is pressed. It won't display any other names or numbers but the first line. The program is not reading each line one at a time per button press. Only continue to display the first line in the file after the button is pressed. All help will be graceful!
[code=perl tk]...
User Profile
Collapse
-
Foreach looping an array in perl tk.
-
What I mean is how to display one name at a time when the button is pressed instead of showing the whole list all at one time. -
Thanks RonB for the insight but how to get it to display each name after I press the button?Leave a comment:
-
The problem is using this coding for perl tk. Im having difficulties with this event-driven part. The problem is this program is only displaying the last line in the file. Need it to display each name, and after the buttom is pressed display the next name. All help will be considered an honor.
[code=perl tk]
require Tk;
use Tk ':eventtypes';
use Tk;
my $mw = MainWindow->new();
...Leave a comment:
-
I forgot to mention the array works fine in perl with is text-based. But the problem is using this coding for perl tk. Im having difficulties with this event-driven part. All help will be considered an honor.Leave a comment:
-
-
I should had tried to put my data set in a hash from the beginning. Hashes are good for handling large data sets.
Thank you to everyone that responded and I will get back to you to tell you how it goes.Leave a comment:
-
How to read every line of file into array
This program display a names. If the name you type match the one asked to type, the program tells you the phone number of the name. The problem is it only list the last name in the file. How to get the program to start at the first name in the file, and after you type it correct, show name number and move to the next name? All help would be graceful!!
...Code:open (FILE, "profile.txt") || die "Can't open File.txt: $!\n";
No activity results to display
Show More
Leave a comment: