picturebox things

  • Thread starter Thread starter EricJ
  • Start date Start date
E

EricJ

imagine having a fixed picture in a form, if the user clicks in the picture
an x has to be displayed where the user clicked (so far not much problems).
But the user can make as much x'ses as he wants and has to be able to resize
them. furder the positions of the x images has to be saved in a db so when
the user calls the form the x'ses are still there 1 more thing he can also
delete them.

w i was thinking
create picture boxes at runtime when the user clicks save the xy and size to
the db if they are manipulated.

if there is a standard way of doing this it would be welcome
but i would be gratefull if someone could give me some pointers on creating
picture box controls at runtime and displaying them on the right spot.

tnx for reading this (and for any help :)


eric J
 
* "EricJ said:
an x has to be displayed where the user clicked (so far not much problems).
But the user can make as much x'ses as he wants and has to be able to resize
them. furder the positions of the x images has to be saved in a db so when
the user calls the form the x'ses are still there 1 more thing he can also
delete them.

w i was thinking
create picture boxes at runtime when the user clicks save the xy and size to
the db if they are manipulated.

if there is a standard way of doing this it would be welcome
but i would be gratefull if someone could give me some pointers on creating
picture box controls at runtime and displaying them on the right spot.

\\\
Dim p As New PictureBox()
p.Size = New Size(...)
p.Location = New Point(...)
p.Image = ...
Me.Controls.Add(p)
///
 
ok w this i get the picbox on the other picbox (picbox.controls.add) :)
2 more things
1 getting the clicked coordinates out of the event arg e
(picturebox_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs)) thats probably a cast to a better event w a xy
and 2 how to make it possible for the user to move and resize the newly
added picturebox

more probs will probably follow (i have to complete this fast and don't have
my books w me :/ )

tnx for the help
 
were dropping 2 due to lack of time (if someone knows its still welcome) i
still need to find point1 getting the coordinates where the user clicked im
starting a new tread for that

EricJ said:
ok w this i get the picbox on the other picbox (picbox.controls.add) :)
2 more things
1 getting the clicked coordinates out of the event arg e
(picturebox_Click(ByVal sender As System.Object, ByVal e As
System.EventArgs)) thats probably a cast to a better event w a xy
and 2 how to make it possible for the user to move and resize the newly
added picturebox

more probs will probably follow (i have to complete this fast and don't have
my books w me :/ )

tnx for the help
 
Back
Top