473,503 Members | 1,655 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

WxListBox

I'm wanting to put a listbox in the place of a textctrl I'm using in my
application because I'm running out of space in my textctrl. The online
documentation is down at wxpython.org so I have no idea how to construct this
control or anything. Can someone help me out. Here's what I'm doing with the
WxTextCtrl:

self.text_ctrl_4 = wx.TextCtrl(self, -1, "", style=wx.TE_MULTILINE)
sizer_1.Add(self.text_ctrl_4, 6, wx.LEFT|wx.RIGHT|wx.EXPAND, 80)
self.text_ctrl_4.AppendText(str(count) + '\t\t' + str(address) + '\t\t'
+ str(pageNumber) + '\t\t' + str(pageArray[pageNumber, 1]) +'\r\n')

I'm wanting to implement something similar with a listbox, any thoughts?
Jul 18 '05 #1
1 2116
LutherRevisited wrote:
I'm wanting to put a listbox in the place of a textctrl I'm using in my
application because I'm running out of space in my textctrl. The online
documentation is down at wxpython.org so I have no idea how to construct this
control or anything. Can someone help me out. Here's what I'm doing with the
WxTextCtrl:

self.text_ctrl_4 = wx.TextCtrl(self, -1, "", style=wx.TE_MULTILINE)
sizer_1.Add(self.text_ctrl_4, 6, wx.LEFT|wx.RIGHT|wx.EXPAND, 80)
self.text_ctrl_4.AppendText(str(count) + '\t\t' + str(address) + '\t\t'
+ str(pageNumber) + '\t\t' + str(pageArray[pageNumber, 1]) +'\r\n')

I'm wanting to implement something similar with a listbox, any thoughts?


Well, my *first* thought was "Isn't a listbox supposed to allow choice
between alternative? How can that substitute for what looks like a very
complex text input?"

My second thought was "It's not very helpful to use a name like
'text_ctrl_4' in the code".

I'm also not really sure what the double-tabs are supposed to do.

Perhaps you could explain exactly what you'd like your program to do
here, as at present it's not even clear whether this code is intended to
act as input as well as output? What's wrong with what happens now, and
how would you like to change it?

regards
Steve
--
Steve Holden http://www.holdenweb.com/
Python Web Programming http://pydish.holdenweb.com/
Holden Web LLC +1 703 861 4237 +1 800 494 3119
Jul 18 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

5
4181
by: Daniel Ehrenberg | last post by:
I'm trying to learn wxPython, but I can't seem to find much documentation. The wxPython website says that all advanced (and even some basic) documentation for wxPython is only available in C++...
5
10592
by: Andrew | last post by:
Hi I just started learning wxPython I wanted to know how I could do this in wxPython self.listbox.delete(0, END) for item in self.results: self.listbox.insert(END, item)
4
1810
by: Eric | last post by:
How does one use wxDirDialog to select and get a computer name from the network? Or which widget should i use to accomplish this? Eric
0
2155
by: Piet | last post by:
Hello wxPythoneers. I have a problem with a dialog box derived from wxFrame which has a wxComboBox as main element. Depending on the entry selected from the ComboBox, the dialog box will be...
2
2294
by: Emiliano Molina | last post by:
This has been driving me crazy for a couple of days and I have finally narrowed it down to the following code. If the commented section is uncommented the drag and drop handler is never called. I...
0
435
by: LutherRevisited | last post by:
wxpython.org's onlinedocs are down right now so bear with me. Here's my problem, currently I'm using a wxtextctrl to enter output in, I'm running out of rows with the wxtextctrl so I thought to...
0
1002
by: LutherRevisited | last post by:
I think I did a double post on WxListBox, my apologies, I wasn't seeing it show up and I didn't take into account the holidays...sorry.
2
1257
by: ishtar | last post by:
Hi I have strange problem... Background: I created some application using Linux which was intended to run on Mac OS X. There were few differences between Linux and Mac behavior of wxWidgets...
1
2417
by: papafreebird | last post by:
I would like to save the contents of a wxListBox to a text file. Using borland c++ builder I am able to accomplish this by using the following code ListBox1->Items->GetText(); ...
0
7074
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
7273
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
7322
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
6982
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
7451
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
0
5572
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing,...
0
4667
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
3150
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
0
374
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.