Questions tagged as 'python-2.7'

0
answers

How to create borderless window in PySide?

I have the following code in PySide in Maya: import maya.cmds as cmds from PySide import QtCore, QtGui import maya.OpenMayaUI as mui import shiboken def getMayaWindow(): pointer = mui.MQtUtil.mainWindow() return shiboken.wrapInstance(...
asked by 27.06.2017 / 14:49
1
answer

Python: How to execute a function on an X number of files (.XML)?

I need to run a Python function on a large number of .XML files. I need the parsing function to run on all the files that end in .XML. This is a fragment of the code to parse the .XML file: import os import xml.etree.ElementTree as ET d...
asked by 02.06.2017 / 13:12
0
answers

How to use the admin Widget to add items

I am a beginner in this, the query is how I can add in my form the image of "Edit" and "Add" in a choice field and I opened in a pop-up the form of that model to add it. As Django admin does but I would like to do it from my form. Thank you....
asked by 23.05.2017 / 18:14
1
answer

How to set a very long text by default in a field in Odoo8?

Good morning, I am working with the selection and recruitment module of odoo8 ... the problem is that I have a text that is too long (one page or so) and the bosses hate to be copying / pasting that text every time they make a new record ......
asked by 12.05.2017 / 16:58
1
answer

USB events in Python

Someone knows how to listen to events on USB ports in Python, for example to know if a USB memory was connected.     
asked by 04.04.2017 / 23:00
0
answers

how to open a csv file with python?

hello everyone I have a code in python that I used to send text messages, this code was passed by the same manufacturer of the product but I do not understand a lot of python, could you tell me how to open the csv file here please I pass the cod...
asked by 02.04.2017 / 16:52
1
answer

I have problems with urllib2 in Python 2.71

I have this request: import urllib2 f = urllib2.urlopen('http://www.python.org/') print f.read(100) but when I run it in Python 2.7.1, I get the following error:    AttributeError: 'module' object has not attribute 'urlopen'     
asked by 06.03.2017 / 22:41
1
answer

After installing PostgreSQL I try to access the localhost and I get a message that the page does not exist

I am starting a web page project which I will do with Django , to make it more complete I will use PostgreSQL to manage the database. I already have installed the python with which I also have a good experience and I also have installed...
asked by 06.03.2017 / 18:00
0
answers

Problems with tkinter and sockets in python

I come for your help. I happen to be doing a game in python a "Battleship". Create the interface with tkinter and to make it online I started using sockets. The problem is that when I want to perform an "attack", everything is pasted. The connec...
asked by 26.11.2016 / 18:18
1
answer

How to convert a for from C to python, "It has to be programmed in c"

I'm totally new to C and I need to send it to call a .txt and identify where a For is found, once that is identified for converting it into a python language example: My txt will have the following: #include <stdio.h> int main() {...
asked by 02.12.2017 / 20:54