Python Forum
Search Results
Post Author Forum Replies Views Posted [asc]
    Thread: automatically get absolute paths
Post: automatically get absolute paths

Hello, I want to automatically convert relative paths to absolute paths. dirname = os.path.dirname(__file__) os.path.join(dirname, r'relative/path/file.txt') This worked fine but I used this in sev...
oclmedyb General Coding Help 1 2,133 Mar-09-2021, 08:34 PM
    Thread: Variable Scopes Decorators
Post: RE: Variable Scopes Decorators

Yes this could be useful. Thank you very much!
oclmedyb General Coding Help 6 2,780 Jan-15-2021, 02:13 PM
    Thread: Variable Scopes Decorators
Post: RE: Variable Scopes Decorators

Hey, I just wanted to reply that it is working like this. And it also makes sense to me if I think about it. **think** But lets assume it is not only dict1 but 10 variables I need to pass in, is the...
oclmedyb General Coding Help 6 2,780 Jan-15-2021, 01:02 PM
    Thread: Variable Scopes Decorators
Post: RE: Variable Scopes Decorators

I can try this earliest tomorrow, but are you sure that this will work? From my understanding this should result in the same error since dict1 will be defined after def get_value(dict1, item, value):
oclmedyb General Coding Help 6 2,780 Jan-14-2021, 04:01 PM
    Thread: Variable Scopes Decorators
Post: Variable Scopes Decorators

Hello, I try to write some Excel functions with xlwings and openpyxl. For example one function will get details about an item from another Excel file. Everytime a function is run, it has to open that...
oclmedyb General Coding Help 6 2,780 Jan-14-2021, 03:26 PM
    Thread: Properly import from sub/parent folders?
Post: Properly import from sub/parent folders?

Hello, I want to organize my project in different folders. Currently everything is in one folder but this is getting messy really fast. This is what I want: -- Project/ ---- Python/ ------ main.py ...
oclmedyb General Coding Help 2 2,074 Dec-13-2020, 05:23 PM
    Thread: Class inheritance
Post: RE: Class inheritance

@deanhystad Thank you! **kwargs and __repr__ was exactly what I was looking for. Couldn't imagine a better answer. **wink** I already intended to use named arguments. I haven't noticed that I actua...
oclmedyb General Coding Help 3 2,281 Dec-09-2020, 04:13 PM
    Thread: Class inheritance
Post: Class inheritance

Hello, I am just learning programming with Python as my first language. I want to build a small application to manage electronic parts. All parts share some global attributes: ipn, mpn, dpn, manufact...
oclmedyb General Coding Help 3 2,281 Dec-06-2020, 05:00 PM

User Panel Messages

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