Python Forum
[PyQt] Help Iterating through to read comboBox Selections
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
[PyQt] Help Iterating through to read comboBox Selections
#3
So I managed to get it to print in the terminal (for testing) the way I want it to:
Output:
14/2 BX 12/2 Romex (White) 14/3 BX - - - - - - - - - - - - - - - - - - - #(These are the blank/default placeholder values) None #(This is the SQL Results from the last ComboBox) None #(This is the SQL Results from the last ComboBox)
But I don't know how to grab the Categories, and Length, & Price from those items printed in the terminal (14/2, 12/2, & 14/3).

I would like it to be like this:
Output:
14/2 BX ('Wire', 100, 0.15) #->(Category,Length,Price) for 14/2 BX 12/2 Romex (White) ('Wire', 25, 0.15) 14/3 BX ('Wire', 200, 0.15) - - - - - - - - - - - - - - - - - - -
So is there a way to iterate through that and just grab/store the Category, Length, Price for each item Name (14/2 BX, 12/2 Romex (White), 14/3 BX)
and ignore '-'?

Attached Files

Thumbnail(s)
   
Reply


Messages In This Thread
RE: Help Iterating through to read comboBox Selections - by Extra - Aug-01-2022, 05:35 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  [PyQt] How can I sync Combobox index to other combobox index? nickzsche 2 2,498 Jan-03-2022, 12:29 PM
Last Post: Axel_Erfurt
  [Tkinter] eport selections to dic mintsilver 0 2,431 Jan-16-2017, 01:06 PM
Last Post: mintsilver

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020