Programming Forums
User Name Password Register
 

RSS Feed
FORUM INDEX | TODAY'S POSTS | UNANSWERED THREADS | ADVANCED SEARCH

Reply
 
Thread Tools Display Modes
Old Feb 16th, 2006, 1:49 AM   #1
diamondustice
Newbie
 
diamondustice's Avatar
 
Join Date: Jan 2006
Posts: 11
Rep Power: 0 diamondustice is on a distinguished road
adding an image control at run time

In my project I need to display images that the user will open in the form(in thumbnail form).. and the user can open as many images he/she wants. My problem is how can I dynamically create an image control at run time so that the number of the images that can be opened and displayed will not be fixed. Can anyone help me?
diamondustice is offline   Reply With Quote
Old Feb 16th, 2006, 10:19 AM   #2
pal121
Newbie
 
Join Date: Feb 2006
Location: Bedford
Posts: 2
Rep Power: 0 pal121 is on a distinguished road
what you mean? like there are many images and when the go mouse over one of them it goes bigger?

i havent got the code atm, but you would use something like this

pic1 being the first pic

Private Sub Form_Load()

pic1.Height = "2675"
pic1.Width = "2775"

End Sub

Private Sub pic1_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)

If pic1.Height = "2655" Then
    pic1.Height = "4455"
ElseIf pic1.Height = "4455" Then
    pic1.Height = "4455"
        End If
        
If pic1.Width = "2775" Then
    pic1.Width = "4455"
ElseIf pic1.Width = "2775" Then
    pic1.Width = "4095"
        End If

End Sub
pal121 is offline   Reply With Quote
Old Feb 16th, 2006, 4:06 PM   #3
BlackDal
Newbie
 
Join Date: Feb 2006
Posts: 12
Rep Power: 0 BlackDal is on a distinguished road
put un image control on form at run time and set it's index to 0
put thins code for runtime
load image1(1)
image1(1).left = 20
image1(1).top = 30
image1(1).visiable = true

your mean is that?
BlackDal is offline   Reply With Quote
Old Feb 19th, 2006, 8:27 PM   #4
diamondustice
Newbie
 
diamondustice's Avatar
 
Join Date: Jan 2006
Posts: 11
Rep Power: 0 diamondustice is on a distinguished road
Quote:
Originally Posted by BlackDal
put un image control on form at run time and set it's index to 0
put thins code for runtime
load image1(1)
image1(1).left = 20
image1(1).top = 30
image1(1).visiable = true

your mean is that?

yup! thank you very much
__________________
ice
diamondustice is offline   Reply With Quote
Old Feb 19th, 2006, 9:12 PM   #5
DaWei
Resident Grouch
 
DaWei's Avatar
 
Join Date: Jun 2005
Posts: 6,453
Rep Power: 10 DaWei is on a distinguished road
This might give you a problem: image1(1).visiable = true

Our machines aren't as adaptive as we.
__________________
Abstraction doesn't make it impossible to write bad code; it makes it possible to write superior code.
Contributor's Corner: Grumpy on C++ Exceptions DaWei on Pointers
DaWei is offline   Reply With Quote
Reply

Bookmarks

« Previous Thread in Forum | Next Thread in Forum »

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 On
HTML code is Off
Forum Jump




DaniWeb IT Discussion Community
All times are GMT -5. The time now is 7:50 PM.

Powered by vBulletin® Version 3.7.0, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Copyright ©2007 DaniWeb® LLC