Results for "Category: Miscellaneous"
Just an update responding to previous user requests. Added fastcall support, call by pointer and every return type I could think of: Byte, Integer, Long, 64bit, Single, Double and none. March 10: two asm optimizations and some comments fixed. March 17: LaVolpe's requests added.
I received a report recently that my 2003 CDECL submission had generated DEP errors on Server 2003. I've updated that submission, but whilst doing so, I saw the potential for some improvements. Enhancements that really needed a new submission. Features: Transparent CDECL/stdcall function calling. Call functions by ordinal or name. Module (.bas) callbacks for CDECL functions. Object (.cls/.frm/.ctl) callbacks for CDECL and stdcall functions. Support for multiple callbacks. Support for multiple cCallFunc.cls instances. Support unicode path\module names. NEW SUBMISSION: 70195
*** Update: See my new submission here... http://www.exhedra.com/vb/scripts/ShowCode.asp?txtCodeId=42918&lngWId=1 If you do want the original zip then email me at Paul_Caton@hotmail.com *** cSuperClass.cls is i believe the fastest, safest compiled in window subclasser around. Speed: The WndProc is executed entirely in run-time dynamically generated machine code. The class only calls back on messages that you choose. Safety: So far I've not been able to crash the IDE by pressing the end button or with the End statement. Flexible: The programmer can choose between filtered mode (fastest) and all messages mode. In filtered mode the user decides which windows messages they're interested in and can individually specify whether the message is to callback after default processing or before. Before mode additionally allows the programmer to specify whether or not default processing is to be performed subsequently. No module: AFAIK this is the only subclasser ever to eschew the use of a module. So how do I get the address of the WndProc routine? Simple, the dynamically generated machine code lives in a byte array; you can get its address with the undocumented VarPtr function. The real magic in cSuperClass.cls is getting from the WndProc to the callback interface routine using ObjPtr against the owning Form/UserControl, see the assembler .asm model file included in the zip. Speaking of which... it may well be the case that my assembler is sub-optimal. Any experts out there willing to take a look? I thought I had a nifty/dirty stack trick working for a while but it didn't pan out. Should work with VB5 if VarPtr & ObjPtr were in that release? Sample project included. Regards.
What: the latest version of my subclassing components. Why: this update fixes DEP (Data Execution Prevention) issues on 64bit Windows and XP SP2 with NX/XD cpu support. Additionally, I’ve eliminated the public callback; here the self-sub callback is the final private method. Who: whilst this submission will mostly interest UserControl authors, the cSelfSub sample class, cShadow, should be of general appeal. SelfSub 2.1 Apr 13 Additions: general purpose callback thunks. Updates: see comments
This is a fully commented project that shows how to use the Environ() function to display all the system environment variables or how to find just the one you want.
This version only works reliably with olderstyle Panosonic or REC-80 remotes, and a PC with pentium 200 Mhz or better. VB does not interface well with the hardware directly. I will admit that VC will do a better job at what I am doing with VB. I have used the Receive line as it is more stable and I have figured out how to read the signals. I began with using a 850 MHz Celeron machine, it captured the IR signal well on the DCD line, however slower machines did not fair so well. I first used Winlirc to decode the buttons of the remotes I am using, and compared them with a digital scope reading, and figured that the raw signal looked a lot similar to a signal being transmitted beteen 9600 and 14400 baud.
Do you know the Flying Windows Screensaver? now you can create Flying ANYTHING screensaver by changing 1 byte!!! (remember to rename the file that has a .rename me extension to EXE)
Sort Array without Swapping Strings The latest Sort submission by Ulli, whcih is unquestionably superior and advanced is, well, advanced! so i cooked-up this sort which is very simple, the algorithm used is shell sort but instead of swapping strings, we swap their index, and finally return an array of sorted indexes, well sort of (pun intended ;-)
API Created Folder Tree - this is the real one Windows uses, not a user control !! the code is not mine, i only cleaned it up a little,whatever...
Concat 2 Arrays (My Dream) - a simple function.... the point is that i wrote it in my dream! yes i did!!! and no i'm not stoned :-)
Clear contents of CMOS Memory
This Vb code shows how easy and good looking sliders can be. This code can be used to enhance your programming for audio, midi and sound programming. Find out in the code how simple some routines are done and freely use it for further purpose in your application. Voting will help giving more of my code out. Do not forget to download the free Live Midi Keyboard from www.rempro.nl
My code is a UMA, Ulimate Messenger Away for MSN Messenger. When your away you open this program and let it take messages. It have a interactive menu sytem
OK. I realize that probably everyone in the world but me knew this. I figured maybe theres 1 other person who never figured it out either, and may find it a time saver.
Search for string in listbox
Opens Notepad and mysteriously(By not creating a window) Types a message in notepads text.
This add-in adds a toolbar to the VB IDE and displays, in a tabbed format, each editable file in all loaded projects. This mimics the tabbed code layout in visual studio.net.
This project allows you to get a barcode from a serial barcode reader and put it into your applications, or another application using sendkeys. It uses the MSComm control and the OnComm event to read each individual character passed to the serial port, it detects the finished barcode from the carriage return sent by the barcode reader. This could be useful in epos programs or just to get data from the serial port.
Add modResize to any vb project. Controls on a form are resized automatically when the size of the form changes. The original form/control size ratio is maintained. Fonts are resized also.
First off, I am not the original author. I merely ported the C# sample to VB.NET. The purpose of this code is to help you implement a Plug-in framework for you applications. This will allow you, and others, to extend your original application without having to re-compile the main application. All credit goes to Roy Osherove for the original source, plus links to his homepage and 2 MSDN sample projects can be found in the readme.html file of the zip file. Enjoy.