Handle is an abstraction of a resource or a reference to an entity. It can have different implementations: a pointer, an index in a table etc.
Questions tagged [handle]
1348 questions
15
votes
3 answers
what is a file handle and where it is useful for a programmer?
I am learning assembly language along with C. this new chapter I started talks about 'file handles', file handles for screen display and file handles for keyboard input etc. I don't know what is a file handle? I am referring to IBM PC ASSEMBLY…

KawaiKx
- 9,558
- 19
- 72
- 111
15
votes
4 answers
`return None` in python not recommended. How to bypass?
I have a function which connects to a url by httplib using lxml. It checks by xpathfor a certain pattern and if the check is positive it returns a string. But if the check was negative it returns nothing.
Now the situation is, that my function…

Aufwind
- 25,310
- 38
- 109
- 154
15
votes
2 answers
How can I tell how much memory a handle object uses in matlab
If I declare an object to be a subclass of handle
classdef obj < handle
my object is now essentially a "pointer" to some memory somewhere. How do I find out how much memory my object is using up?
For example, say I have a class foo with a field…

Marc
- 5,315
- 5
- 30
- 36
15
votes
3 answers
What is the difference between a Pointer and a Handle
I cannot say I have a strong C++ background so I hear Handle very often these days. I know what a Pointer is (which stores address of the memory location like reference) but I am not really sure what Handle is and what the differences are between…

Tarik
- 79,711
- 83
- 236
- 349
14
votes
4 answers
Catching/hijacking stdout in haskell
How can I define 'catchOutput' so that running main outputs only 'bar'?
That is, how can I access both the output stream (stdout) and the actual output of an io action separately?
catchOutput :: IO a -> IO (a,String)
catchOutput =…

worldsayshi
- 1,788
- 15
- 31
13
votes
5 answers
Preventing file handle inheritance in multiprocessing lib
Using multiprocessing on windows it appears that any open file handles are inherited by spawned processes. This has the unpleasant side effect of locking them.
I'm interested in either:
1) Preventing the inheritance
2) A way to release the file…

14256424
- 163
- 1
- 7
13
votes
4 answers
Forcing the creation of a WPF Window's native Win32 handle
I need to access the Win32 window handles of some of my WPF windows so I can handle Win32 activation messages. I know I can use PresentationSource.FromVisual or WindowInteropHelper to get the Win32 window handle, but I am running into problems if…

Zach Johnson
- 23,678
- 6
- 69
- 86
12
votes
4 answers
Handle Keyboard Done pressed event on Iphone
I am moving my view when a text field is pressed in order to get proper view when keyboard appears. Now, when the Done keyboard button is pressed, I would like to return the view to its initial state. How do I handle an action when the done keyboard…

Ruthy
- 177
- 1
- 1
- 7
12
votes
2 answers
Resize Element with box handles in corners
in Jcrop , after selecting cropping area , a div appears with box handles in corners.
Is there any jQuery plugin that can build this type of box handles ?

Mironline
- 2,755
- 7
- 35
- 61
11
votes
3 answers
Android, handle SQLiteConstraintException
I've got this method in Android:
public void insertarTitulo(String _id, String title, String url){
ContentValues cv = new ContentValues();
cv.put("_id", _id);
cv.put("title", title);
cv.put("URL", url);
try{
…

butelo
- 1,653
- 1
- 18
- 29
11
votes
1 answer
Do I have to close inherited handle later owned by child process?
Microsoft played safe here. In their article, "Creating a Child Process with Redirected Input and Output", they are saying:
The remaining open handles are cleaned up when this process terminates.
To avoid resource leaks in a larger application,…

GSerg
- 76,472
- 17
- 159
- 346
11
votes
5 answers
Delphi: Check whether file is in use
I want to write to/delete a file but sometimes I get a crash if the file is in use by another program. How do I check to see whether the file is opened by another process or I can open it for writing?

Arthur
- 3,376
- 11
- 43
- 70
11
votes
3 answers
How to make a program not show up in Alt-Tab or on the taskbar
I have a program that needs to sit in the background and when a user connects to a RDP session it will do some environment setup then launch a program. When the program is closed it will do some housekeeping and logoff the session.
The current way I…

Scott Chamberlain
- 124,994
- 33
- 282
- 431
11
votes
2 answers
Handle a JNI crash
I have a dll that contains legacy C code, I call this dll via JNI, but sometimes the C code crashes and causes the JVM to terminate. Is it there a way to avoid JVM crash? Can I handle the JNI fault and let the JVM survive? :)

Farr
- 111
- 1
- 3
11
votes
3 answers
How do you obtain Current Window Handle Count and Window Handle Limit in .NET?
I want to obtain the current number of window handles and the system-wide window handle limit in C#. How do I go about this?
Roel Vlemmings