473,383 Members | 1,880 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,383 software developers and data experts.

Is this way of handling a module correct?

1
I made a module to manage the menus of an lcd display.

The number of options is quite large so I plan to use this file as a module to import into a file that integrates other issues.

And my question goes this way. For example, when I select to log in to a page in the menu, what I do in the menu is put a variable that when entering that option becomes true.

So in the main file I have something like:

Expand|Select|Wrap|Line Numbers
  1. import menus
  2.  
  3. ShowMenu = menus.displayMenu(initial_menu)
  4. ShowMenu.start()
  5.  
  6. while 1:
  7.     if ShowMenu.login == True:
  8.         makesomething
  9.         ShowMenu.login = False
  10.     if.... etc.
This is well? I mean, interact in this way with the other module? have a variable in the menus module that help me organize the main flow?
Sep 4 '22 #1
0 8538

Sign in to post your reply or Sign up for a free account.

Similar topics

7
by: N.K | last post by:
Hi , Python's existing cookie module doesnt supports new cookie headers SetCookie2 , How to submit a patch for that ? I tried emailing person who owns that module.But no response. Thanks,...
9
by: Hans-Joachim Widmaier | last post by:
Hi all. Handling files is an extremely frequent task in programming, so most programming languages have an abstraction of the basic files offered by the underlying operating system. This is...
0
by: Dave Cole | last post by:
WHAT IS IT: The Sybase module provides a Python interface to the Sybase relational database system. It supports all of the Python Database API, version 2.0 with extensions. NOTES: This...
7
by: Spacen Jasset | last post by:
The main two desirable things I feel error handling should provide are these: 1) Debugging and diagnostic aid 2) User feedback One method that is used a fair amount it to 'say' that all...
3
by: Phillip Ian | last post by:
Just a quick architecture question. I'm just looking for discussion, not a flame war, please. In the past, I've tended to use a public module for my data layer functions. Something like: ...
2
by: ===Steve L.=== | last post by:
does anyone know any site or ariticle provides exmaple for building a Global Error Handling Module in VB.Net? the module should be able to 1. prouduce friendly generic error msg for the users and...
14
by: ccdetail | last post by:
http://www.tiobe.com/index.htm?tiobe_index Python is the 7th most commonly used language, up from 8th. The only one gaining ground besides VB in the top 10. We're glad, our app is written in...
0
by: Lysander | last post by:
Thought I would give something back with a few articles. This article is a bit of code to add error handling. When I have time, I want to write articles on multilingual databases, and Access...
40
by: rjcarr | last post by:
Sorry if this is a completely newbie question ... I was trying to get information about the logging.handlers module, so I imported logging, and tried dir(logging.handlers), but got: ...
0
by: Cramer | last post by:
Using ASP.NET 3.5: Can a custom HTTP Module be used to register for the Application_Start event? Or _must_ I use Global.asax to work with Application.Start? I understand that I can use a custom...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
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:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
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...

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.