Go Back  Xtreme Visual Basic Talk > Legacy Visual Basic (VB 4/5/6) > General > Image Placement and Control


Reply
 
Thread Tools Display Modes
  #1  
Old 12-23-2004, 02:12 PM
SonHouse SonHouse is offline
Regular
 
Join Date: Apr 2004
Posts: 58
Cool Image Placement and Control


I have two sets of dynamic arrays, one set acts as containers on a table layout, the other holds images that I drag and drop on the container array coordinates. My question is how can I tell what container is associated with what image control? I drag and drop the image controls, picDeck(index), easy enough, but when I go to move them off the container,imgPlacement(index), I need to be able to recognize that the container control has nothing on top of it or associated with it...so I can move something else in the picDeck(index) place. Does that make sense? I tried using the tag property of the imgPlacement(index) control to flip back and forth between 1 and 0 so I can have a reference..but got stuck. Any ideas?

Thanks
Reply With Quote
  #2  
Old 12-23-2004, 02:55 PM
Diurnal Diurnal is offline
Enthusiast

Retired Leader
* Expert *
 
Join Date: Apr 2002
Location: Bellevue, WA.
Posts: 3,233
Default

Can you use the .Tag property of the image control to hold the index number of the container array. If the control is available, set the .Tag property to -1 or some value that the other array will never use. Then to find out if it is available or where it is being used, quarry the .Tag property.
Reply With Quote
  #3  
Old 12-24-2004, 03:27 PM
SonHouse SonHouse is offline
Regular
 
Join Date: Apr 2004
Posts: 58
Default Testing the Control

How can I test the control that acts as the container to see whether or not something is on top of it or not?
Reply With Quote
  #4  
Old 12-24-2004, 07:52 PM
Iceplug's Avatar
Iceplug Iceplug is offline
MetaCenturion

Retired Moderator
* Guru *
 
Join Date: Aug 2001
Location: California, USA
Posts: 16,583
Default

There is no method of the container that tells you if it has any contained controls... all of the controls are in the form collection.
So, it would be easier for you to set the tag of the container control when you add a picture to it. Make the tag like a count: increment it when you add a control, and decrement when you remove a control.
__________________

Iceplug, USN
Quadrill 1 Quadrill 2 (full) Quadrill 3 JumpCross .NET Website is ALIVE! - DL Platform Tour for VB.NET! Posting Guidelines Hint: Specify your location in your user cp profile if you want compassion!
Reply With Quote
  #5  
Old 12-25-2004, 11:02 AM
SonHouse SonHouse is offline
Regular
 
Join Date: Apr 2004
Posts: 58
Default Controls

Iceplug...so, should I move the entire picture box control of an array into the container array when I move a control around, if so how would I do that?? or should I just move the picture out of the picture box control.

Thanks and happy holidays...
Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Forum Jump

Advertisement:





Free Publications
The ASP.NET 2.0 Anthology
101 Essential Tips, Tricks & Hacks - Free 156 Page Preview. Learn the most practical features and best approaches for ASP.NET.
subscribe
Programmers Heaven C# School Book -Free 338 Page eBook
The Programmers Heaven C# School book covers the .NET framework and the C# language.
subscribe
Build Your Own ASP.NET 3.5 Web Site Using C# & VB, 3rd Edition - Free 219 Page Preview!
This comprehensive step-by-step guide will help get your database-driven ASP.NET web site up and running in no time..
subscribe
 
 
-->