Click here to Skip to main content
15,895,256 members
Home / Discussions / C#
   

C#

 
GeneralNeed help with Regex Pin
viperxp30-Jun-03 4:15
viperxp30-Jun-03 4:15 
GeneralRe: Need help with Regex Pin
leppie30-Jun-03 13:32
leppie30-Jun-03 13:32 
GeneralRe: Need help with Regex Pin
viperxp30-Jun-03 19:05
viperxp30-Jun-03 19:05 
GeneralRe: Need help with Regex Pin
1-Jul-03 5:22
suss1-Jul-03 5:22 
GeneralImage-Listbox Pin
jphuphilly30-Jun-03 4:13
jphuphilly30-Jun-03 4:13 
GeneralRe: Image-Listbox Pin
Manster30-Jun-03 9:03
Manster30-Jun-03 9:03 
GeneralRe: Image-Listbox Pin
jphuphilly30-Jun-03 11:08
jphuphilly30-Jun-03 11:08 
GeneralRe: Image-Listbox Pin
Manster1-Jul-03 3:59
Manster1-Jul-03 3:59 
Ok, I think this is what you're going to want to do.

On the parent form get the selected index of the listbox and pass that into the child form. On the child form take that index id and set that in the imagelist and picturebox controls to display the correct image when that form is loaded.

Parent form code:

int iLBID = listbox1.SelectedIndex;

ChildForm CForm = new ChildForm( iLBID );
CForm.ShowDialog( this );
CForm.Dispose();
this.Focus();

Child form code:

private int m_iSelID;

// Constructor code.
public ChildForm( int iLBID )
{
m_iSelID = iLBID;

pictureBox1.Image = imageList1.Images[m_iSelID];
}

** remember to add a picturebox and an imagelist control to your child form. Load up the imagelist control in design mode and then set the picturebox image index to the index selected in the parent listbox.

Hope this helps. Wink | ;)
GeneralRe: Image-Listbox Pin
jphuphilly1-Jul-03 7:27
jphuphilly1-Jul-03 7:27 
GeneralRe: Image-Listbox Pin
jphuphilly30-Jun-03 11:35
jphuphilly30-Jun-03 11:35 
Questionwho knows sth. about FolderNameEditor? Pin
gongxiancao30-Jun-03 2:48
gongxiancao30-Jun-03 2:48 
GeneralToolbars, main menus & context menus Pin
hbandarra29-Jun-03 23:48
hbandarra29-Jun-03 23:48 
GeneralRe: Toolbars, main menus & context menus Pin
hbandarra30-Jun-03 3:19
hbandarra30-Jun-03 3:19 
GeneralDeserializing dynamically loaded types Pin
Oyvind Bratland29-Jun-03 22:26
Oyvind Bratland29-Jun-03 22:26 
Generalopacity of panels Pin
Member 138827529-Jun-03 21:39
Member 138827529-Jun-03 21:39 
QuestionSerialize into the appropriate App.exe.config file? Pin
Anonymous29-Jun-03 17:59
Anonymous29-Jun-03 17:59 
GeneralKeyword.... Pin
Steve McLenithan28-Jun-03 17:41
Steve McLenithan28-Jun-03 17:41 
GeneralRe: Keyword.... Pin
Bo Hunter28-Jun-03 18:19
Bo Hunter28-Jun-03 18:19 
GeneralRe: Keyword.... Pin
Steve McLenithan28-Jun-03 18:36
Steve McLenithan28-Jun-03 18:36 
QuestionHow Do I: Write an Addin for IE in C# Pin
Rahul Singh28-Jun-03 13:48
Rahul Singh28-Jun-03 13:48 
AnswerRe: How Do I: Write an Addin for IE in C# Pin
Mazdak29-Jun-03 4:32
Mazdak29-Jun-03 4:32 
AnswerRe: How Do I: Write an Addin for IE in C# Pin
J. Dunlap29-Jun-03 8:32
J. Dunlap29-Jun-03 8:32 
GeneralRe: How Do I: Write an Addin for IE in C# Pin
leppie29-Jun-03 9:35
leppie29-Jun-03 9:35 
GeneralRe: How Do I: Write an Addin for IE in C# Pin
Rocky Moore30-Jun-03 0:42
Rocky Moore30-Jun-03 0:42 
GeneralWeb Service Pin
puppiesLover28-Jun-03 8:57
puppiesLover28-Jun-03 8:57 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.