Search Results
|
Post |
Author |
Forum |
Replies |
Views |
Posted
[asc]
|
|
|
Thread: Python debuggers
Post: RE: Python debuggers
Thanks @snippsat **smile** |
|
jehoshua |
General Coding Help |
8 |
1,340 |
Jul-20-2023, 07:48 AM |
|
|
Thread: Using Python to connect to an XML ?
Post: RE: Using Python to connect to an XML ?
(Jul-08-2023, 02:40 AM)deanhystad Wrote: I cannot disagree much more. I find pysimplegui anything but simple.
@deanhystad - What GUI do you recommend please ? |
|
jehoshua |
General Coding Help |
12 |
1,989 |
Jul-11-2023, 12:34 AM |
|
|
Thread: Python debuggers
Post: RE: Python debuggers
Visual Studio Code is certainly very powerful, thanks for recommending it. There certainly are deeper layers of variables, both locals and globals, and then variables within variables. One can easily ... |
|
jehoshua |
General Coding Help |
8 |
1,340 |
Jul-10-2023, 10:57 PM |
|
|
Thread: Using Python to connect to an XML ?
Post: RE: Using Python to connect to an XML ?
(Jul-08-2023, 02:40 AM)deanhystad Wrote: I find pysimplegui anything but simple.
Oh well, 'horses for courses' as they say. **biggrin** |
|
jehoshua |
General Coding Help |
12 |
1,989 |
Jul-08-2023, 03:39 AM |
|
|
Thread: Using Python to connect to an XML ?
Post: RE: Using Python to connect to an XML ?
Now needing to display the data from the XML to a GUI, the example at https://github.com/PySimpleGUI/PySimpleG...1624781486 will be of a great help. Of all the GUI's for Python, PySimpleGUI is by far ... |
|
jehoshua |
General Coding Help |
12 |
1,989 |
Jul-08-2023, 01:24 AM |
|
|
Thread: Python debuggers
Post: RE: Python debuggers
(Jul-07-2023, 03:37 AM)deanhystad Wrote: Visual Studio Code and Visual Studio are different things. Your link is to Visual Studio Code, or VSCode. Both Visual Studio and VSCode can do Python, but ... |
|
jehoshua |
General Coding Help |
8 |
1,340 |
Jul-07-2023, 04:38 AM |
|
|
Thread: Using Python to connect to an XML ?
Post: RE: Using Python to connect to an XML ?
I needed to specify 'parent'. On a find_all() it wouldn't work, but on a find() it worked
#!/usr/bin/python
from bs4 import BeautifulSoup
with open('testxml.xml', 'r') as f:
file = f.read()
so... |
|
jehoshua |
General Coding Help |
12 |
1,989 |
Jul-07-2023, 01:21 AM |
|
|
Thread: Python debuggers
Post: RE: Python debuggers
Thanks @snippsat . I had to lookup what REPL meant and found it to be "Read-Eval-Print Loop".
I installed ptpython and IPythonIPython . The first seemed only an editor that wasn't even checking synta... |
|
jehoshua |
General Coding Help |
8 |
1,340 |
Jul-07-2023, 12:40 AM |
|
|
Thread: Using Python to connect to an XML ?
Post: RE: Using Python to connect to an XML ?
The data is of the format
>> <PAYEE matchingenabled="0" email="" name="Transfers - inter account" reference="" id="P000001">
<ADDRESS street="" telephone="" state="" city="" postco... |
|
jehoshua |
General Coding Help |
12 |
1,989 |
Jul-06-2023, 12:40 AM |
|
|
Thread: Python debuggers
Post: Python debuggers
What do you use ? There is the command line pdb at https://docs.python.org/3/library/pdb.html
Then three GUI ones mentioned at https://stackoverflow.com/posts/4929267/revisions , PyDev , Wing Python... |
|
jehoshua |
General Coding Help |
8 |
1,340 |
Jul-04-2023, 10:51 PM |
|
|
Thread: Using Python to connect to an XML ?
Post: RE: Using Python to connect to an XML ?
Thanks, I had to install BeautifulSoup4 even though I had BeautifulSoup installed. That works fine
from bs4 import BeautifulSoup
with open('testxml.xml', 'r') as f:
file = f.read()
soup = Beaut... |
|
jehoshua |
General Coding Help |
12 |
1,989 |
Jul-04-2023, 10:25 PM |
|
|
Thread: Using Python to connect to an XML ?
Post: RE: Using Python to connect to an XML ?
Now changed to
from bs4 import BeautifulSoup
with open('testxml.xml', 'r') as f:
file = f.read()
# 'xml' is the parser used. For html files, which BeautifulSoup is typically used for, it would be ... |
|
jehoshua |
General Coding Help |
12 |
1,989 |
Jul-04-2023, 05:03 AM |
|
|
Thread: Using Python to connect to an XML ?
Post: RE: Using Python to connect to an XML ?
I followed the guide at https://stackabuse.com/parsing-xml-with-...in-python/ , some test code
from bs4 import BeautifulSoup
with open('xmlfile', 'r') as f:
file = f.read()
# 'xml' is the parser u... |
|
jehoshua |
General Coding Help |
12 |
1,989 |
Jul-04-2023, 04:18 AM |
|
|
Thread: Using Python to connect to an XML ?
Post: RE: Using Python to connect to an XML ?
(Jun-27-2023, 07:25 AM)Gribouillis Wrote: I understand that KMyMoney can save its data in a SQLite 3 database. You could then export the database tables to spreadsheets by various means, this is a ... |
|
jehoshua |
General Coding Help |
12 |
1,989 |
Jun-27-2023, 09:15 AM |
|
|
Thread: Using Python to connect to an XML ?
Post: Using Python to connect to an XML ?
Can I use Python to connect to an XML, and then based on the data and certain rules, create a spreadsheet similar to OpenOffice calc ? Or it doesn't have to specifically be a spreadsheet, but simply ... |
|
jehoshua |
General Coding Help |
12 |
1,989 |
Jun-27-2023, 04:12 AM |
|
|
Thread: Modifying a date format
Post: RE: Modifying a date format
(Oct-28-2022, 11:23 PM)jehoshua Wrote: Yes, I'll create some test data. Thanks
Some test data at https://pastebin.com/raw/FnueXARj |
|
jehoshua |
General Coding Help |
17 |
3,006 |
Oct-29-2022, 08:44 PM |
|
|
Thread: Modifying a date format
Post: RE: Modifying a date format
(Oct-29-2022, 03:10 PM)DeaD_EyE Wrote: This should work
Thanks, yes it works fine now as:
import datetime
input_format = "D%m/%d'%Y"
output_format = "D%m/%d/%Y"
f = open("ANCU.qif","r")
lines = f... |
|
jehoshua |
General Coding Help |
17 |
3,006 |
Oct-29-2022, 08:27 PM |
|
|
Thread: Modifying a date format
Post: RE: Modifying a date format
(Oct-28-2022, 10:59 PM)rob101 Wrote: I'm guessing that the list object contains more than that.
Yes, I'll create some test data. Thanks |
|
jehoshua |
General Coding Help |
17 |
3,006 |
Oct-28-2022, 11:23 PM |
|
|
Thread: Modifying a date format
Post: RE: Modifying a date format
(Oct-28-2022, 12:53 PM)DeaD_EyE Wrote: import datetime
input_format = "D%d/%m'%Y"
output_format = "%d/%m/%Y"
datetime.datetime.strptime("D4/7'2004", input_format).strftime(output_format)
Thank you... |
|
jehoshua |
General Coding Help |
17 |
3,006 |
Oct-28-2022, 11:20 PM |
|
|
Thread: Modifying a date format
Post: RE: Modifying a date format
(Oct-28-2022, 10:23 AM)rob101 Wrote: As I had 10 mins spare, I've come up with a possible solution:
Thanks, I added a loop to read the file, code now ..
def format_date(date):
for index, item i... |
|
jehoshua |
General Coding Help |
17 |
3,006 |
Oct-28-2022, 10:34 PM |