Finding what data has been selected in QComboBox [duplicate]
.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty{ height:90px;width:728px;box-sizing:border-box;
}
This question already has an answer here:
PyQT5 QComboBox - get value of combobox
1 answer
How do you get the current text contents of a QComboBox?
4 answers
I would like to know what function is needed to find the value that has been selected within the Drop down menu. The data must be updated live within the application for the function to be worthwhile.
The code I have written to create the QComboBox is as follows:
dropDown = QComboBox(self)
dropDown.addItem('Nvidia')
dropDown.addItem('AMD')
dropDown.setObjectName('GPU brand')
dropDown.setGeometry(250, 350, 90, 25)
Essentially I would like to write a function which will look at which of the two items has been selected. Then use that data to run another two functions, separate from each other for either AMD or Nvidia.
python pyqt5
marked as duplicate by eyllanesc
StackExchange.ready(function() {
if (StackExchange.options.isMobile) return;
$('.dupe-hammer-message-hover:not(.hover-bound)').each(function() {
var $hover = $(this).addClass('hover-bound'),
$msg = $hover.siblings('.dupe-hammer-message');
$hover.hover(
function() {
$hover.showInfoMessage('', {
messageElement: $msg.clone().show(),
transient: false,
position: { my: 'bottom left', at: 'top center', offsetTop: -7 },
dismissable: false,
relativeToBody: true
});
},
function() {
StackExchange.helpers.removeMessages();
}
);
});
});
Jan 3 at 16:35
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
add a comment |
This question already has an answer here:
PyQT5 QComboBox - get value of combobox
1 answer
How do you get the current text contents of a QComboBox?
4 answers
I would like to know what function is needed to find the value that has been selected within the Drop down menu. The data must be updated live within the application for the function to be worthwhile.
The code I have written to create the QComboBox is as follows:
dropDown = QComboBox(self)
dropDown.addItem('Nvidia')
dropDown.addItem('AMD')
dropDown.setObjectName('GPU brand')
dropDown.setGeometry(250, 350, 90, 25)
Essentially I would like to write a function which will look at which of the two items has been selected. Then use that data to run another two functions, separate from each other for either AMD or Nvidia.
python pyqt5
marked as duplicate by eyllanesc
StackExchange.ready(function() {
if (StackExchange.options.isMobile) return;
$('.dupe-hammer-message-hover:not(.hover-bound)').each(function() {
var $hover = $(this).addClass('hover-bound'),
$msg = $hover.siblings('.dupe-hammer-message');
$hover.hover(
function() {
$hover.showInfoMessage('', {
messageElement: $msg.clone().show(),
transient: false,
position: { my: 'bottom left', at: 'top center', offsetTop: -7 },
dismissable: false,
relativeToBody: true
});
},
function() {
StackExchange.helpers.removeMessages();
}
);
});
});
Jan 3 at 16:35
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
The QComboBox description explains everything.
– ekhumoro
Jan 3 at 16:27
Use dropDown.currentText() or the signalcurrentTextChanged
– eyllanesc
Jan 3 at 16:34
add a comment |
This question already has an answer here:
PyQT5 QComboBox - get value of combobox
1 answer
How do you get the current text contents of a QComboBox?
4 answers
I would like to know what function is needed to find the value that has been selected within the Drop down menu. The data must be updated live within the application for the function to be worthwhile.
The code I have written to create the QComboBox is as follows:
dropDown = QComboBox(self)
dropDown.addItem('Nvidia')
dropDown.addItem('AMD')
dropDown.setObjectName('GPU brand')
dropDown.setGeometry(250, 350, 90, 25)
Essentially I would like to write a function which will look at which of the two items has been selected. Then use that data to run another two functions, separate from each other for either AMD or Nvidia.
python pyqt5
This question already has an answer here:
PyQT5 QComboBox - get value of combobox
1 answer
How do you get the current text contents of a QComboBox?
4 answers
I would like to know what function is needed to find the value that has been selected within the Drop down menu. The data must be updated live within the application for the function to be worthwhile.
The code I have written to create the QComboBox is as follows:
dropDown = QComboBox(self)
dropDown.addItem('Nvidia')
dropDown.addItem('AMD')
dropDown.setObjectName('GPU brand')
dropDown.setGeometry(250, 350, 90, 25)
Essentially I would like to write a function which will look at which of the two items has been selected. Then use that data to run another two functions, separate from each other for either AMD or Nvidia.
This question already has an answer here:
PyQT5 QComboBox - get value of combobox
1 answer
How do you get the current text contents of a QComboBox?
4 answers
python pyqt5
python pyqt5
edited Mar 3 at 10:02
Sebastian Dixon
asked Jan 3 at 16:02
Sebastian DixonSebastian Dixon
5511
5511
marked as duplicate by eyllanesc
StackExchange.ready(function() {
if (StackExchange.options.isMobile) return;
$('.dupe-hammer-message-hover:not(.hover-bound)').each(function() {
var $hover = $(this).addClass('hover-bound'),
$msg = $hover.siblings('.dupe-hammer-message');
$hover.hover(
function() {
$hover.showInfoMessage('', {
messageElement: $msg.clone().show(),
transient: false,
position: { my: 'bottom left', at: 'top center', offsetTop: -7 },
dismissable: false,
relativeToBody: true
});
},
function() {
StackExchange.helpers.removeMessages();
}
);
});
});
Jan 3 at 16:35
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
marked as duplicate by eyllanesc
StackExchange.ready(function() {
if (StackExchange.options.isMobile) return;
$('.dupe-hammer-message-hover:not(.hover-bound)').each(function() {
var $hover = $(this).addClass('hover-bound'),
$msg = $hover.siblings('.dupe-hammer-message');
$hover.hover(
function() {
$hover.showInfoMessage('', {
messageElement: $msg.clone().show(),
transient: false,
position: { my: 'bottom left', at: 'top center', offsetTop: -7 },
dismissable: false,
relativeToBody: true
});
},
function() {
StackExchange.helpers.removeMessages();
}
);
});
});
Jan 3 at 16:35
This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.
The QComboBox description explains everything.
– ekhumoro
Jan 3 at 16:27
Use dropDown.currentText() or the signalcurrentTextChanged
– eyllanesc
Jan 3 at 16:34
add a comment |
The QComboBox description explains everything.
– ekhumoro
Jan 3 at 16:27
Use dropDown.currentText() or the signalcurrentTextChanged
– eyllanesc
Jan 3 at 16:34
The QComboBox description explains everything.
– ekhumoro
Jan 3 at 16:27
The QComboBox description explains everything.
– ekhumoro
Jan 3 at 16:27
Use dropDown.currentText() or the signal
currentTextChanged
– eyllanesc
Jan 3 at 16:34
Use dropDown.currentText() or the signal
currentTextChanged
– eyllanesc
Jan 3 at 16:34
add a comment |
0
active
oldest
votes
0
active
oldest
votes
0
active
oldest
votes
active
oldest
votes
active
oldest
votes
The QComboBox description explains everything.
– ekhumoro
Jan 3 at 16:27
Use dropDown.currentText() or the signal
currentTextChanged
– eyllanesc
Jan 3 at 16:34