Results for "Category: Custom Controls/ Forms/ Menus"
A utility class for adding/hiding the horizontal scroll bar in the ListBox control dynamically taking into account its font (using the IFont interface). The code uses the SendMessage API function to add a horizontal scroll bar dynamically to a list box using the LB_SETHORIZONTALEXTENT message. To precisely calculate the width of a new item, our class uses the DrawText API function with the DT_CALCRECT flag. Draw attention at the fact that our class works properly if you change the font of the listbox as you want. We use the IFont interface and its hFont property to retrieve the handle of the font used in the listbox. Our class can also calculate the minimum width of the list box when the horizontal scroll bar disappears (it takes into account the visibility of the vertical scroll bar in the listbox; it determines whether this scroll bar is present by retrieving the listbox style flags and testing these set of flags for WS_VSCROLL).
The attached code demonstrates a technique you can use to create multiline balloon tooltips for ListView items. The code is based on the following simple idea. In the MouseMove event you need to check the index of the item under the mouse pointer, and if this item is changed, you simply redefine the text of the tooltip attached to the ListView control. Notice that you should destroy the tooltip if there is no any item under the mouse pointer. To determine the index of the list-view item under the mouse pointer, we send the LVM_HITTEST message to the ListView control. The SendMessage function you should use to send this message returns the index of the item at the specified position, if any, or -1 otherwise. Before you send the message, populate the pt field of an instance of the LVHITTESTINFO structure with the coordinates of the mouse pointer (you pass the reference to this structure as the value of the lParam parameter in SendMessage). You can use for this purpose the X and Y parameters of the MouseMove event of the control, but draw attention at the fact that these parameters can be measured in twips and you need to convert them in pixels. This simple idea can be used to create such tooltips for ListBox items, any grid control items and so on. For instance, we use this technique in extra samples for iGrid ActiveX Control we produce (this is an editable replacement for ListView and FlexGrid – visit www.10Tec.com for more info).
'I took most of this codes from PSC so credit to whomever wrote them 'The purpose of this aplication is to explain how you can custumize controls 'with their own code inside an OCX and the call them from a Dll into your 'application 'See if you can find a use for it, I already got mine... 'HINT: To be able to "Configure" personalized applications from a mother 'application, so you 'don't have to code things all over again every tyme you want to write 'a new program... 'if I didn't Explain myself, I believe you can figure it out....
A simple procedure you can use it works like the Internet Explorer Address Bar. It will save what is typed into the Combo Box and it does not allow duplicate entries to be entered. Please vote if you like it. Sendmessage API can be used also for speed. This is a little simpler because there no declarations.
Dynamic controls made easy for everyone.
Very simple Progressbar, a picturebox, an imagebox, a label and some line of codes and that's it:) no OCX and no API you can change the look of the progressbar if you want, juste change the image in picture1 (representing the backGround of the progressbar) and the image in in image1 (representing the status and value of the progressbar) and that's it Excuse my bad english
Final Version of My MM CheckBox 2009 (now, with beautiful Caption if you want)+Code Optimization. (see the screen capture)
Version 2.1 of my very simple and beautiful CheckBox (MM CheckBox 2009 v2.0). Now with beautiful Antialising (perfect circle) (thanks to "Dana Seaman" for this technique) Check the Screen Capture my blog, http://mmvb2008.unblog.fr/ (some sympathetic utility makes in vb6)
This module allows any form to snap to the edges of the work area. (Kinda like winamp) It is multi-monitor compatible. (not kinda like winamp)
This is an ActiveX control with enhanced features of normal TextBox allowing u to write VB Applications with more ease.
Beware of cheap imitations!!!!!!!!
update 07-17-08 Fixed a bug I caused fixing the last bug.Sorry for the bad upload. update 07-16-08 fixed a bug with path property pointed out by Ed Wilk and Rodger Gilchrist. Thanks. update 07-13-08 A few changes addressed in the ucThumbs code, most notable is saving the thumb image in an array for faster drawing. update 03-03-08 Added auto size and maintain ratio to the thumbs. also changed the way text is writen. I'm working on unicode. Update 02-27-08 fixed a few bugs in the code and added some key events along with keyboard shortcuts. You cna find info on the changes at the top of the UC code module. This is an image file list box. It has a lot of the same properties of the file list. It also has a few properties of its own. A built in right click menu with (Copy, Delete, Move, Rename, Browse for folder, and a File Properties option). Update: found a few problems I fixed. And also I thought since I wrote the code it would be easier for me to update it to do different size thumbs. I couldn't decide on user defined or optional set sizes so I did both.I also added them to the menu so you can change the size at runtime. I'm working on comments and cleaning the code. This may take a few days as I'm quite busy these days. Please let me know if you find any errors in the code or need something added. Thanks! 02-22-08 fixed some problems pointed out by users, credit an reports given in uc code. Thanks for the comments. added runtime resizeability to the Usercontrol
Skingen loads a bitmap and makes a form transparent. See screenshot.
Hi All,This is the first time i am uploding some of my code here , its a demo control which will allow your application to be made as a Trial version in few minutes Just Place this Control and set its NofDays and NofTimes(how many time aplication will run) and sets its status property to Demo And provide yoour trial Expiration code on DemoCreator1_DemoCompleted event to handle the execution when demo expired Rest is automatically handeld by this control Thanks Nitin
A N (3-20) sided regular polygon button control. It started out as the Circular Button from Praveen Menon, went a step further and changed it to fit my needs. It wouldn't be difficult to change it to any shaped button control, just load the array with the points.
Customize your menu with images. Just create a menu with the VB Menu editor. Add some PictureBoxes to your form and assign to the CMenu class. This class uses the whole region of the main-menu not only the regions of the items. So, if the window width changes, the background image of the main-menu also does. The screenshot shows where PictureBoxes are applied. UPDATE: Now using a better method for subclassing. A MsgBox blocked the WM_DRAWITEM message when running in the IDE and as long as the msgbox was on top, the menubar was grey. This doesn't happen in the new version.
This is a very simple and precise solution to keep a form on top of only one other form. I was looking for a solution, but couldn't find it anywhere. All the codes and suggestions either keep the form on top of All windows programs or on top of the whole application. But this one will only keep one form on top of another one.
Ever wanted to have function keys in your application (F1, F2, F3 etc..)? Here is the very simple and streight forward solution to it. Moreover, its very very solid to impliment. No API calls, no HOOKS grabage. Just use form functions. Download code and see the instructions on form.
This is a systray control with scrolling text on the tray.
This Active-X Control allows you to access your MS-Access file on your webserver.you only need to put the serverside script on the root of the webserver which you want to access the file I included scripts in ASP and ASP.NET Open the testproject that shows all the use this Control