Advertisement

Results for "Author: rde"

2_2002-2004 #114727
Over 7070 Windows API flags as VB Constants (4)

Collection 4 of 4 (7070 out of nearly 30 thousand in all!) constants (flags) for the Windows API functions in 83kb zip!. The API documentation tells you what flags you need but not their values. Well here they are, as many as I can find so far, converted to VB constants. But be warned I have not tested them all so some may not work correctly, I don't know. Happy coding, Rd.

2_2002-2004 #114737
The Question of Existence

I have come across several different solutions for testing for a file's existance, from Dir to opening the file, testing for error, then closing the file again. I remembered an article/comment by Bruce McKinney that influenced my solution to this problem and thought I would share it.

2_2002-2004 #114886
MDI File Muncher - Opens multiple files into one instance (New version - no hook)

Hi. This is an MDI app work in progress. Many have asked after a way to open files into a single (previous) instance of a program. This demo can open multiple files at startup into one instance, you can drag-and-drop onto the running program to open files, and it can receive files to open when already running from explorer or the command line. It also includes working file handling code (open, edit and save files) and some generic menu items. It cannot yet receive commands like [print], this is yet to be added. I have eliminated the need for the MsgLink module which subclass's the window. By raising the LinkExecute event (I looked at doing this programatically but it also needed a hook) using DDE and a label on an invisible form. My idea was to use this form as a progress meter but I made it invisible, using an existing form would load the new instance when the DDE properties are accessed. I have used a RTB control on the child form which is likely to give you trouble. If so you can add your own RTB ref from Components and place it on the child form and name it rtfText. You do not need to size it as it will auto-size at runtime. Please don't complain too much about the lack of comments in the code (there aren't many I admit). I am working on it. Let me know if you have any issues with this working correctly. I've uploaded already to get comments and suggestions, so please DO.

2_2002-2004 #115137
InstallFile module - Install files on end user's machine w/o copy older version over a new version.

When installing a file on an end user's machine, you should not copy an older version of the file over a new version. The InstallFile wrapper in the InstFile.bas module uses the VerFindFile and VerInstallFile API functions provided by Version.dll to copy files to the user's machine, and will not overwrite an existing file with an older version. The InstFile.bas module requires the GetVersionInfo wrapper in the VerInfo.bas module (also included) which uses several API functions also provided by Version.dll, most importantly the GetFileVersionInfo function.

2_2002-2004 #115138
BAS Module Mania (LUCKY 13 UPDATED)

Collection of lucky 13 modules packed with API wrappers, commonly used funcs, and some not-so common bits as well. Includes: AlertErr.bas (new) APITimer.bas Common.bas (updated) Conv.bas FileSys.bas FileTime.bas FindFiles.bas MemMaps.bas Misc.bas MRUFiles.bas MsgLink.bas ShellExe.bas WinVersion.bas (updated) UPDATED Now has NEW AlertErr.bas! This CHERRY mod includes the full GetClientSpec module code which it replaces so still 13. Must be lucky! Thanks to everyone who responded to my request for info to update the WinVersion module. Please give more feedback :)

2_2002-2004 #115170
AlertError (Updated)

AlertError module - this is a simple solution for handling and alerting errors when they occur. Rather than hiding errors away this module uses the philosophy of alerting you to errors right where they occur, while logging errors to file in the most convenient location when in your end-users space, all automatically according to the running environment. This module can *best pick* the log path for all running environments including when running as a compiled ActiveX component in/out of the IDE. Update inspired by Ulli's submission at: txtCodeId=56112&lngWId=1

2_2002-2004 #116104
Setting and getting file attributes w/o affecting other attributes - Updated

These two simple wrappers can be used for setting and retrieving individual or selected file attributes without affecting the other attributes of the file. For example, to set the Archive bit of a file you should not just set its attributes to vbArchive (32), as this will turn off any other attributes currently set. Normally you would need to get the file attributes, add the desired attribute to the current attributes, then set them again. These wrappers just hide the details of this process. Update thanks to redbird77. +++++++++++++++++++++++++++++++++++++++++++++++++++ With the GetAttrib wrapper you can easily test the current state of an attribute. You simply specify the attribute(s) and the function will return True if the specified attribute(s) is set to on. You can specify more than one attribute and True will be returned only if all specified attributes are turned on. +++++++++++++++++++++++++++++++++++++++++++++++++++ The SetAttrib wrapper simplifies the setting of an attribute to on or off, and will be set as desired irrespective of its current state. You can set more than one attibute at a time (eg. SetAttrib(sFile, vbReadOnly Or vbHidden) will set these attributes to on, no matter if they are on or off, without affecting other attributes that may be set. +++++++++++++++++++++++++++++++++++++++++++++++++++ My first version of the SetAttrib function used 'Xor' to turn attributes off, but thanks to redbird77, I have updated it to 'Not' which has eliminated a limitation of my version. The bottom line is that you can set a files attribute(s) to on or off without needing to know the current state of the specified attributes, while not affecting other attributes that may be set.

2_2002-2004 #126902
Demonstrating Objects and Arrays

This demonstrates the use of Objects and Arrays using simple examples. Shows the differences between objects and arrays, adding properties and methods, explains associative arrays, constructor functions, all by example. Although I have put it in the beginners section, experienced js scripters may find some interesting facts about arrays lengths, deleting items and more. Hope you find it helpful.

3_2004-2005 #131511
An Inter-App Messaging Control v2

MsgLink - An Inter-Application Messaging Control v2. This is a complete and functional control that uses the Copy Data Structure to pass data between applications that utilize this control. It allows you to pass numeric data, strings, dates, currency, in fact all data types except variants, including arrays and udts, and arrays of udts (except arrays of variants and strings). Possibly could be extended to handle arrays of pointers to the data (strings and variants).

3_2004-2005 #132346
API data types

Explains the use of non-VB data types to help in converting C declarations to Visual Basic. 10k zip

3_2004-2005 #132816
Tips

Some very basic but handy tips for newbies (and maybe not so newbies). Hope you learn something. I've added quite a bit more to the article, mostly very basic info on the vb language, but we all had to learn this stuff when we started out.

3_2004-2005 #133093
JpgStrip v1 Freeware Source Code

This JPEG strip code is in response to a recent submission on JPEG info extraction. This code was developed by David Crowell using vb5, so don't vote. I posted it for those interested in learning more about the internals of the JPEG graphic format. Please follow Davids request to leave this zip archive intact if you re-distribute it. This is version 1, and David is still developing it, he has a freeware exe version 1.3 available at: www.ksurf.net/~bermania/prog/dessin/jpgstrip.zip I don't know whether sourse code is available.

3_2004-2005 #133195
A ShellSort with a twist (updated)

Introducing a shellsort hybrid that slips pre-sorted data to a built in walker with a very fast smart-find (binary search) twister. This shell algorithm is founded on a very solid performer that was originally developed by vb2themax, and optimized further by several very talented coders, before I twisted a little more out of it in this hybrid version. Although this algorithm is optimized for re-sorting and reverse sorting, it also has been greatly boosted in raw outright speed to square up against anything, anytime! This is the fastest shellsort I know of by far*. This algorithm excels on both un-sorted and pre-sorted data. *A hybrid shellsort with a twist, and no bubbles.

3_2004-2005 #133270
Over 6320 Windows API flags as VB Constants (1)

Collection 1 of 4 (6320 out of nearly 30 thousand in all!) constants (flags) for the Windows API functions in 84kb zip!. The API documentation tells you what flags you need but not their values. Well here they are, as many as I can find so far, converted to VB constants. But be warned I have not tested them all so some may not work correctly, I don't know. Happy coding, Rd.

3_2004-2005 #133271
Over 7070 Windows API flags as VB Constants (4)

Collection 4 of 4 (7070 out of nearly 30 thousand in all!) constants (flags) for the Windows API functions in 83kb zip!. The API documentation tells you what flags you need but not their values. Well here they are, as many as I can find so far, converted to VB constants. But be warned I have not tested them all so some may not work correctly, I don't know. Happy coding, Rd.

3_2004-2005 #133281
The Question of Existence

I have come across several different solutions for testing for a file's existance, from Dir to opening the file, testing for error, then closing the file again. I remembered an article/comment by Bruce McKinney that influenced my solution to this problem and thought I would share it.

3_2004-2005 #133430
MDI File Muncher - Opens multiple files into one instance (New version - no hook)

Hi. This is an MDI app work in progress. Many have asked after a way to open files into a single (previous) instance of a program. This demo can open multiple files at startup into one instance, you can drag-and-drop onto the running program to open files, and it can receive files to open when already running from explorer or the command line. It also includes working file handling code (open, edit and save files) and some generic menu items. It cannot yet receive commands like [print], this is yet to be added. I have eliminated the need for the MsgLink module which subclass's the window. By raising the LinkExecute event (I looked at doing this programatically but it also needed a hook) using DDE and a label on an invisible form. My idea was to use this form as a progress meter but I made it invisible, using an existing form would load the new instance when the DDE properties are accessed. I have used a RTB control on the child form which is likely to give you trouble. If so you can add your own RTB ref from Components and place it on the child form and name it rtfText. You do not need to size it as it will auto-size at runtime. Please don't complain too much about the lack of comments in the code (there aren't many I admit). I am working on it. Let me know if you have any issues with this working correctly. I've uploaded already to get comments and suggestions, so please DO.

3_2004-2005 #133681
InstallFile module - Install files on end user's machine w/o copy older version over a new version.

When installing a file on an end user's machine, you should not copy an older version of the file over a new version. The InstallFile wrapper in the InstFile.bas module uses the VerFindFile and VerInstallFile API functions provided by Version.dll to copy files to the user's machine, and will not overwrite an existing file with an older version. The InstFile.bas module requires the GetVersionInfo wrapper in the VerInfo.bas module (also included) which uses several API functions also provided by Version.dll, most importantly the GetFileVersionInfo function.

3_2004-2005 #133682
BAS Module Mania (LUCKY 13 UPDATED)

Collection of lucky 13 modules packed with API wrappers, commonly used funcs, and some not-so common bits as well. Includes: AlertErr.bas (new) APITimer.bas Common.bas (updated) Conv.bas FileSys.bas FileTime.bas FindFiles.bas MemMaps.bas Misc.bas MRUFiles.bas MsgLink.bas ShellExe.bas WinVersion.bas (updated) UPDATED Now has NEW AlertErr.bas! This CHERRY mod includes the full GetClientSpec module code which it replaces so still 13. Must be lucky! Thanks to everyone who responded to my request for info to update the WinVersion module. Please give more feedback :)

3_2004-2005 #133714
AlertError (Updated)

AlertError module - this is a simple solution for handling and alerting errors when they occur. Rather than hiding errors away this module uses the philosophy of alerting you to errors right where they occur, while logging errors to file in the most convenient location when in your end-users space, all automatically according to the running environment. This module can *best pick* the log path for all running environments including when running as a compiled ActiveX component in/out of the IDE. Update inspired by Ulli's submission at: txtCodeId=56112&lngWId=1

Languages
Top Categories
Global Discovery