473,396 Members | 1,693 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,396 software developers and data experts.

Entry widget -- how to prevent change

let's say I already have some content. How do I set the widget so user
cannot change it/?

Nov 22 '05 #1
2 1643
On 2005-11-22, wanwan <er*******@yahoo.com> wrote:
let's say I already have some content. How do I set the widget so user
cannot change it/?


Most widgets have some sort of "read-only" or "edit enable"
attribute you can set. Look at the documentation for the
widget in question. Since you don't specify what toolkit you're
using, that about as specific an answer as you're going to get...

--
Grant Edwards grante Yow! I've read SEVEN
at MILLION books!!
visi.com
Nov 22 '05 #2
"wanwan" <er*******@yahoo.com> wrote:
let's say I already have some content. How do I set the widget so user
cannot change it/?


assuming that you're talking about the Tkinter Entry widget, setting
the state option to "readonly" should do the trick:

e = Entry(...)
e.config(state="readonly")

also see

http://effbot.org/tkinterbook/entry.....config-method

</F>

Nov 22 '05 #3

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

Similar topics

0
by: Mickel Grönroos | last post by:
Hi, I'm trying to put an Tkinter.Entry of fixed size onto a specific location on a canvas using the place manager. The idea is that one can double-click a rectangle object on a canvas to get an...
3
by: Phil Schmidt | last post by:
I'm trying to make a custom entry widget, as in the code that follows. There are two problems I'm trying to fix: 1) I would like the widget to behave as myEntry.Escape() does now, except that it...
4
by: Clara | last post by:
Hi, can somebody help me,..I have an assignment due next week but now I'm stuck with this problem.... I tried to get values from entry widget using the widgetcontrolvariable.get(),..but it seems...
7
by: Michael Onfrek | last post by:
Hi! I'm playing with entry again and trying to restrict length of entry widget to certain number of character, so users cannot enter more character into it. Any ideas? Reg. Michael Onfrek
2
by: Dustan | last post by:
How do I limit what the user can enter in an Entry Widget? I know I can set it to display '*' to hide a password, but what I want to do is limit the contents to numeric characters. What is the...
0
by: Marek S. | last post by:
Hi, I am new in Python and I have no experience in object-oriented programming. I want to make an easy GUI for my application. What is my problem? I have the data-file like this (file...
4
by: Dustan | last post by:
Back in this post, I attempted to make a label look like a button:...
2
Strider1066
by: Strider1066 | last post by:
Is it a bug or a feature? I'm trying to sub-class an Entry widget that displays a template (i.e. '____-__-__') for users and does keystroke validation. It is starting to work but with one problem....
2
by: lee.walczak | last post by:
Hi, I am using Tkinter & the Kevin Walzer's TableList Wrapper for python implemented GUI: http://tkinter.unpythonic.net/wiki/TableListWrapper The TableList has been extremely useful in...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
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...
0
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
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,...

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.