|
Just for a follow-up. I think it has worked for now. But I won't know until tomorrow. It didn't create an install file, but an application file. Hopefully this will be sufficient.
Thanks again
|
|
|
|
|
|
Great attitude mate, u sound like a complete MVP
1. The guy has not even completed a single app 1000 comp installation will be a bit less.
2. I think Bill Gates runs to his customers with a floppy disk in his hand (for may be Windows XP).
-- modified at 1:57 Tuesday 19th June, 2007
|
|
|
|
|
Did you notice the quote was yours? It was in response your suggestion, it just got mixed up in the DB.
only two letters away from being an asset
|
|
|
|
|
Yeah I did notice that. May be u did not read what i wrote. Try to solve problems more that making smilies
|
|
|
|
|
Hi guys, I need your help in preventing multiple instances of the same window from opening in an MDI parent child window application ? Its urgent ...thanks ...
|
|
|
|
|
What is the question, where are you stuck?
|
|
|
|
|
My question is simple and straight..I want to prevent multiple instances of the same child window from opening i.e. only one instance of a window should open up when i select a certain menu option from the main menu. I hope i made myself clear this time..!!
|
|
|
|
|
One way can be:
use frm.ShowDialog();
This way, unless you have not closed the current child form, you cannot open anyother.
This might be a quick fix for your problem. If you don't want this you might have to google intensly
|
|
|
|
|
yeah..I have tried that approach, but as u say, i was not able to to open up any other window until i closed this one..but tht should not happen in an MDI windows application ..right ?
Can Dispose() method help in this case?
|
|
|
|
|
yeah..I have tried that approach, but as u say, i was not able to to open up any other window until i closed this one..but tht should not happen in an MDI windows application ..right ?
Can Dispose() method help in this case?
|
|
|
|
|
MDI Parent forms contain a collection of it's children (this.MdiChildren). Before you open a new instance of a form you could check this collection if your form exist and simply activate this instance.
|
|
|
|
|
Can you elaborate a bit more...thanks
|
|
|
|
|
I found the solutions mate:
Form2 frm = new Form2();
if (MdiChildren.Length != 0)
{
for (int i = 0; i < this.MdiChildren.Length; i++)
{
if (this.MdiChildren[i].GetType().Name != "Form2")
{
frm.Show();
frm.MdiParent = this;
}
}
}
else
{
frm.Show();
frm.MdiParent = this;
}
PS: you will have to modify this the above is real quick and dirty.
You will have to check this for each and every form you open.
Cheers.
|
|
|
|
|
Can you fire an event inside of an event that is already executing?
|
|
|
|
|
|
Is there anything special you have to do to get this to work because the event inside the executing event is not firing?
|
|
|
|
|
It is possible that you are not firing the event properly, can you pass me the code.
|
|
|
|
|
This is the code:
protected void btnNext_Clicked(object sender, EventArgs e)
{
switch (m_teststage)
{
case "STEP1":
hidMode.Value = "STEP2";
break;
case "STEP2":
hidMode.Value = "STEP3";
break;
}
m_teststage = hidMode.Value;
FormatPageChange();
}
private void FormatPageChange()
{
if (m_teststage == "STEP2") InitialiseDMRGrid();
if (m_teststage == "STEP3") InitialiseTestGrid();
SetPanelVisibility();
SetButtonVisibility();
SetValidatorsEnabled();
}
private void InitialiseDMRGrid()
{
WebGridHelper m_webgridhelperDMR = new WebGridHelper(wgDMR, "", "ID");
wgDMR.PrepareDataBinding += new DataSourceEventHandler(wgDMR_PrepareDataBinding);
wgDMR.InitializeDataSource += new DataSourceEventHandler(wgDMR_InitializeDataSource);
m_webgridhelperDMR.SortColumns += new SortColumnsEventHandler(m_webgridhelperDMR_SortColumns);
wgDMR.InitializePostBack += new PostBackEventHandler(wgDMR_InitializePostBack);
}
If I click the Next button the event fires but when it gets to the InitialiseDMRGrid method it goes in but does not fire the events inside.
|
|
|
|
|
I think the problem is:
You are "adding" the events on button click and not "firing" them. They will fire when they are suppose to fire.
Your code will add the events to, for eg:
wgDMR.InitializeDataSource += new DataSourceEventHandler(wgDMR_InitializeDataSource);
and when the DataSource in initialised then this event will fire. (I guess you have defined the event handlers somewhere else, because I can't see the event handlers for any of the above events.)
|
|
|
|
|
I see what I am doing wrong now. Thanks for your help.
|
|
|
|
|
This is not good approach by firing an event inside the already firing event.
Regards,
Satips.
|
|
|
|
|
Why not?
only two letters away from being an asset
|
|
|
|
|
Satips wrote: This is not good approach by firing an event inside the already firing event.
WHY ?
|
|
|
|
|
hello every body.
is there any method to write a matlab code within c#?
Please help.
|
|
|
|