i would like to ask for some help here. im not sure on how i could do this but here it what im trying to do.
I am trying to make a program that looks for a string in the program and tells me if its there or not.
if you have ever used Process Hacker you can right click on the program you are looking for then right click and click properties. and filter then look for the line you are looking for. well i am trying to make a program that dose it for you so i don't have to keep going threw that all the mess in process hacker.
if someone could tell me what path i need to go or help me out here please do. if you need anymore info about this please let me know and ill be glad to explain more.
have a good one.
You could do:
def textSearcher(string, wantedText):
for x in string(or whatever has the text):
if x == wantedText:
return x
And you are talking about the control f function, right?
Related
Sorry for bad title, I dont know how to say it in my language ( so especially in english ).
Lets say I am working for a code, I make a grammer mistake, forget "" or other stuff, how to remove all the help from pycharm?
I am studying for a final test in my university for Python and I wont want pycharm helping me, I want to realize my mistakes myself, not pycharm helping me.
Please help, atleast tell me what to write at google so I know how to remove it.
EDIT: can anyone help? Inspection and such will not work. I am still in this problem.
i want to use python3 to make a "chat bot", but, i don't want it to be complex, i just want it to say something when someone enters the chat room imvu. Any ideas where to get some docs to read or something? Would be nice. Thank you all.
I recommend watching the YouTube channel called The Coding Train because he has done a few things with chat-bots and twitter-bots. If that's not what you're looking for do a few quick google searches on the subject "how to make a chat-bot" or something like that. there's a lot of material out there.
I'm totally new to programming, maybe my problem is newbie, but I know a little bit of python. I'm trying to build robot kind of machine to do some specific work, but I want him also to answer my "hi", so I mean machines will go through code step by step and do as it say (work I going to give him) so do I need to specify after like every two line
if input_voice == "hi":
print hi
Basically I want to know how can we detect voices and reply and middle of the work, the code to do specific work,
Sorry if you don't understand, I'm very bad at explaining
I have never used Python before, most of my programming has been in MATLAB and Unix. However, recently I have been given a new assignment that involves fixing an old PyEPL program written by a former employee (I've tried contacting him directly but he won't respond to my e-mails). I know essentially nothing about Python, and though I am picking it up, I thought I'd just quickly ask for some advice here.
Anyway, there are two issues at hand here, really. The first is this segment of the code:
exp = Experiment()
exp.setBreak()
vt = VideoTrack("video")
at = AudioTrack("audio")
kt = KeyTrack("key")
log = LogTrack("session")
clk = PresentationClock()
I understand what this is doing; it is creating a series of tracking files in the directory after the program is run. However, I have searched a bunch of online tutorials and can't find a reference to any of these commands in them. Maybe I'm not searching the right places or something, but I cannot find ANYTHING about this.
What I need to do is modify the
log = LogTrack("session")
segment of the code, so that all of the session.log files go into a new directory, separate from the other log files. But I also need to find a way to not only concatenate them into a single session.log file, but add a new column to that file that will add the subject number (the program is meant to be run by multiple subjects to collect data).
I am not asking anyone to do my work for me, but if anyone could give me some pointers, or any sort of advice, I would greatly appreciate it.
Thanks
I would first check if there is a line in the code
from some_module_name import *
This could easily explain why you can call these functions (classes?). It will also tell you what file to look in to modify the code for LogTrack.
Edit:
So, a little digging seems to find that LogTrack is part of PyEPL's textlog module. These other classes are from other modules. Somewhere in this person's code should be a line something like:
from PyEPL.display import VideoTrack
from PyEPL.sound import AudioTrack
from PyEPL.textlog import LogTrack
...
This means that these are classes specific to PyEPL. There are a few ways you could go about modifying how they work. You can modify the source of the LogTrack class so that it operates differently. Perhaps easier would be to simply subclass LogTrack and change some of its methods.
Either of these will require a fairly thorough understanding of how this class operates.
In any case, I would download the source from here, open up the code/textlog.py file, and start reading how LogTrack works.
This question may sounds dumb, but I can't manage to find a correct answer on my own.
I am trying to use the SVG DOM interface in my python script. I would like to use getComputedTextLength but I can't find how even if I firstly thought it would be available thanks to modules or a packages like python-svg or something like that.
I am sure there is something I miss, but I can't find what.
Any help would be appreciated.
Thank you.
EDIT: I forgot to talk about what my script actually does. It's a Python script used to generate a SVG file from data grabbed on the Internet. My script needs to write texts and repeat them all along a path. Also, as I know the exact length (in pixels) of the path I need to know the length of the text in order to repeat it only what I need to. That's why a method like getComputedTextLength would be helpful.
Try this: http://www.gnu.org/software/pythonwebkit/
I don't think this is possible. DOM is one thing and calling browser's function is other thing. I only saw Python module which help you to create tree structures like HTML or SVG but they don't provide any other additional functionality. (Btw., last time I look even browsers had problems correctly computing getComputedTextLength but that was some time ago...)
You could try better luck with fonttools.