|
Thanks Richard I get it now...
But how manage to show large icon and small icon from Byte Array...
Please, give me a clue..
Thanks so much Richard.....
|
|
|
|
|
Deadlast wrote: But how manage to show large icon and small icon from Byte Array...
I'm not sure what you mean by Byte Array in this context. Check out the LargeImageList and SmallImageList Properties in the ListView.
|
|
|
|
|
What i meant was that i have files that have been converted into Array of byte...
These files could be any kind of file type...
then instead of displaying the files from specified location on hard drive...
I want to display the files that have been converted into Array of byte.....
Thankyou...
|
|
|
|
|
Deadlast wrote: I want to display the files that have been converted into Array of byte.....
I think you will need to use the OwnerDraw property and event for this. See here[^] on MSDN for more information.
|
|
|
|
|
Hi richard, thanks for the advice
But i seem don't get it
I just want to display the icons based on byte array...
Not to redraw Listview on my own
Im sorry....
I dont really understand...
|
|
|
|
|
Well a quick Google search produced this[^]!
|
|
|
|
|
I am looking for someone help to develop a motion tracking system.
I need a very basic application to track a fairly fast moving ball in 2D from a web or video camera. If I can get funding following a proof of concept demo it could lead to a lucrative contract.
Ian
|
|
|
|
|
Something like this[^]? Perhaps the code would work with a fluorescent ball?
Sounds cool
I are Troll
|
|
|
|
|
Is is at all possible to detect mouse movement or keyboard strokes while the computer is locked by the user? The application I made is supposed to go on if it detects someone is there, by moving the mouse or hitting the keyboard. When the computer gets locked the user would have to type his password back in and log on again for it to detect him/her. Is there a way to simply move the mouse or hit the keyboard without unlocking the computer and detecting that with my application?
Thanks
|
|
|
|
|
RyJaBy wrote: Is is at all possible to detect mouse movement or keyboard strokes while the computer is locked by the user?
I don't know if it would work if the computer is locked, but the only way you could do that would be to implement global keyboard and mouse hooks.
Google for "vb.net global keyboard hook" and you'll find examples.
|
|
|
|
|
Dave Kreskowiak wrote: I don't know if it would work if the computer is locked,
That would definitely be uncool, since one could read keystrokes that are meant for Gina's eyes only
I are Troll
|
|
|
|
|
Yeah, I kind of knew that, though my "recall" is a bit hampered today because of a lack of sleep.
|
|
|
|
|
Isn't a locked computer showing another desktop, kind of a parallel universe, to which your regular "global keyboard and mouse hooks" have no access? Otherwise GINA would be in trouble as Eddy pointed out.
Luc Pattyn
I only read code that is properly indented, and rendered in a non-proportional font; hint: use PRE tags in forum messages
Local announcement (Antwerp region): Lange Wapper? Neen!
|
|
|
|
|
Yeah, I'd be willing to say it won't work at all. I gave him an avenue to try though.
Yep, the Unlock screen is shown on a completely seperate Desktop than the one the user sees.
His only other option would be to write a new GINA. Good Luck with that!
|
|
|
|
|
Okay so if I cant detect the keyboard while it is locked, is there a way to determine if the computer gets locked? Is there a specific event that is triggered when the computer gets locked?
|
|
|
|
|
If you're running this on Windows XP SP2 and above and you're using .NET 2.0 or better you can use the SystemEvents.SessionSwitch event. You have to wire this event up and tear it down yourself though.
|
|
|
|
|
I hope nobody gets upset about me starting a new thread - I've posted a couple about this project already but the problems I'm encountering are different each time.
The server application I've written in Visual Basic is receiving a packet of data from a client. I have had nothing to do with how the client communicates, and I can't change it - I'm sort of trying to 'reverse engineer' an existing application.
A packet sniffer tells me what the data of the packet from the client contains. In hex it is:
414D464D1A000000BD020012FB21CC1F0600000053746F636B73
The same packet sniffer software tells me that this converts to:
AMFM....½...û!Ì.....Stocks
The word 'Stocks' at the end is the client name, so obviously that's what I'm trying to obtain. I have no idea what the other bits mean.
But when the little application I've written receives this packet and displays the data received it only displays "AMFM". Nothing else. If I change my code to display the hex received and not the ASCII conversion it shows the whole hex code, just as the packet sniffer does.
Why does it only show me these first four characters (plus the mysterious box)? How can I get the rest?
Oddly enough, when copying the output from the packet sniffer to the clipboard as I wrote this, even though I selected the whole string when I pasted it into my browser window it only pasted "AMFM". What's going on?!
|
|
|
|
|
Not all data is text, some is just binary data; and some is mixed (as in an EXE file).
Text processing often stops at the first NULL character, which is a zero byte.
The non-user content of TCP/IP packets is documented in the TCP/IP documentation.
Luc Pattyn
Local announcement (Antwerp region): Lange Wapper? Neen!
|
|
|
|
|
By "non-user content" are you referring to the header information and so forth? I'm already ignoring all of that, this is just the part identified as "data" by the packet sniffer.
Is there a way to have my code continue to look for text in the string after it encounters a null byte? Or just to read the last characters of the string, which seem to constitute the client name?
|
|
|
|
|
You'll have to go over the byte data yourself and look for alphanumeric ASCII values. Relying on the Encodings classes to do it for you will all result in stopping at the first 0 byte they encounter.
You're going to have a very difficult time with this. It's like you're trying to speak Japanese by duplicating the sounds of the words you hear instead of understanding the language.
|
|
|
|
|
And here was me thinking I'd had a difficult time up until now! I like your analogy - but if this packet contains data in a 'foreign language', what does speak this language?
So in theory if I create a loop which works through every byte in the string looking for characters with ASCII values between 32 and 126 and adds them to a string if they match those criteria that should work?
/sigh
|
|
|
|
|
phil2415 wrote: So in theory if I create a loop which works through every byte in the string looking for characters with ASCII values between 32 and 126 and adds them to a string if they match those criteria that should work?
You'll get some form of data. Whether or not it means anything is a whole other issue.
How about this? 1, 16, 32464, 2342, 6547. What does that string of numbers mean? Without knowing precisely what the applications send back and forth and how it's formatted by the applications, you have no hope of ever understanding what the numbers mean, nor how to respond in a manner that's going to be understood.
Also, if the data object thats being transferred is bigger than one packet, how will you know??
|
|
|
|
|
Hi,
if all the sniffer knows is Ethernet packets, then it would strip Ethernet heads and tails, and call the remainder "data". However other protocols are built on top of that, each adding either entire packets, or pre- and postfixing their own header and tail to the actual user data.
research TCP/IP, it is all standardized and documented and slightly complex if you're new to it.
Luc Pattyn
Local announcement (Antwerp region): Lange Wapper? Neen!
|
|
|
|
|
Luc Pattyn wrote: slightly complex
Slightly?! :p
Thanks for the help, I'll crack on and read the documentation!
|
|
|
|
|
Not immediately recognizing some hex output doesn't necessarily make it complex.
if you want something complex, have a look at PEF, the file format used by Windows executables.
Luc Pattyn
Local announcement (Antwerp region): Lange Wapper? Neen!
|
|
|
|