|
You can't close the first form here - you've called ShowDialog so control transfers to the second form until you close that.
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
Switch your showDialog() to a Show() then you should be able to close the first form.
Ben
|
|
|
|
|
Hi,
while form2 is shown with ShowDialog() form1 normally remains visible, but inaccessible;
i.e. form2 behaves like a modal dialog, one that gets all the attention the process gets,
until form2 is closed.
If you dont want to see form1 behind form2, I would try this:
this.Hide();
objForm2.ShowDialog();
this.Show();
BTW: you normally capture the return value of ShowDialog to find out the reason it
got closed(use different DialogResult values for different buttons on the dialog).
|
|
|
|
|
I want source of an application that nobody can kill or terminate it .
please help me as soon as possible ...
DMASTER
|
|
|
|
|
You and every other script kiddie on the planet.
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
Sorry , bit I don't know you clear
please illubrate in more details ...
DMASTER
|
|
|
|
|
Let me put it another way then. In Windows, you can't - an application can always be terminated. Obviously, embedded systems don't work like this, but they are outside the scope of this discussion.
The application runs inside a process, and somebody with sufficient privileges must be able to kill a process. This is a by design behaviour, to prevent bad or runaway processes from trampling all over a system.
More importantly, this behaviour prevents viruses and worms from taking total control of a system and being unstoppable.
Deja View - the feeling that you've seen this post before.
|
|
|
|
|
Developer611 wrote: please illubrate in more details ...
Illubration: An application that cannot be terminated by the user is what every virus-writing, lowlife, script-kiddie excuse-for-a-programmer wishes was possible.
|
|
|
|
|
do you know any way?
DMASTER
|
|
|
|
|
Why would you want to do this? Why do you want your application never to be killed or terminated?
Upcoming events:
* Glasgow: Mock Objects, SQL Server CLR Integration, Reporting Services, db4o, Dependency Injection with Spring ...
"I wouldn't say boo to a goose. I'm not a coward, I just realise that it would be largely pointless."
My website
|
|
|
|
|
why you ask?
i like it...
DMASTER
|
|
|
|
|
What part of "ITS NOT POSSIBLE" don't you understand???
Developer611 wrote: why you ask?
i like it...
This is the typical response we expect from a script-kiddie to a questio nsuch as yours. There is NO LEGITIMATE reason to want to do this, and as such, your attitude justifies my response stated in the first line of this post.
For you - It's not possible.
For someone with a LEGITIMATE reason, it's possible, but will not be discussed out in the open because of the extremely sensitive nature of the process and it's possibility for abusive use.
|
|
|
|
|
while(1)
{
if (you dont know)
{
tell me dont know
}
else
{
tell me any thing you know
}
}
DMASTER
|
|
|
|
|
In the abstract (as in know what parts of win32 to start googling on) there are a number of people here who probably could do it. *BUT* hell will freeze over before any of us help you write malware!
--
You have to explain to them [VB coders] what you mean by "typed". their first response is likely to be something like, "Of course my code is typed. Do you think i magically project it onto the screen with the power of my mind?" --- John Simmons / outlaw programmer
|
|
|
|
|
Wow. This is just plain rude. Some of the experienced programmers probably could do it, but they are not going to because:
1) The whole idea of it seems malicious
2) You are being rude
_____________________________________________
Flea Market! It's just like...it's just like...A MINI-MALL!
|
|
|
|
|
Well, you discovered it yourself: the never ending program. It does not need any
I/O, does not consume disk space, it will keep on running forever, increasing
the Universe's entropy, completely ignoring Al Gore.
Good for you.
|
|
|
|
|
Developer611 wrote: do you know any way?
How much is it worth to you?
|
|
|
|
|
it is possible but its only a preventative from accidental termination if someone really wants to stop your process they can.
i'm not going to post code because it less about code and more about common sense in program design any programmer worth his salt can do it.
oh and i like to easily kill processes myself instead of having hunt through process explorer, so i don’t like the idea personally
some application require it (AV, security, system dependent Software) other like the above posts stated just cause pain for myself and other people.
good luck
what are you working on out of interest?
|
|
|
|
|
|
Maybe somebody has experience with WCF and can share knowledge .
I need to use WCF on server side and rich client application with grid .
The question is how to send a lot of data to grid with the best performance.
Do you have any idea ?
sebwaks@yahoo.co.uk
|
|
|
|
|
Hi I am working with DatagridView and List<>:
my code goes as follows
List<seatentity> seat = scs.GetSeats();//Returns List<>
SeatEntity seobj= new SeatEntity();
foreach (DataGridViewRow row in dataGridView1.Rows)
{
foreach (DataGridViewCell cell in row.Cells)
{
foreach (SeatEntity se in seat)
{
seobj.SeatId = se.SeatId.ToString();
seobj.RowId = se.RowId.ToString();
if (cell.ColumnIndex.ToString() == seobj.SeatId.Substring(14) && cell.RowIndex.ToString() == seobj.RowId.Substring(12))
{
cell.Style.BackColor = Color.Green;
//MessageBox.Show(cell.ColumnIndex.ToString());
//MessageBox.Show(cell.RowIndex.ToString());
}
}
}
}
While I execute this code the out put is First row of the datagrid only....
But requirement is It should give more rows....
Help me.....
|
|
|
|
|
I think you are trying to work with a generic List<> but your code doesn't show that. This line:
List seat = scs.GetSeats();//Returns List<>
Would need to be defined as
List<seatentity> seat = scs.GetSeats();
And scs.GetSeats() should return List<seatentity>
So that is my guess as to why your code isn't working.
Ben
|
|
|
|
|
Hi
In a database I have 5 related tables, so that, in my project I'm working with 5 tableadapters inside a dataset.
The problem is: How can I update those tables using a transaction? I already googled but couldn't find an answer.
|
|
|
|
|
Hi all,
I have a Windows application developped using C#.Net with .Net 2005. I have used a datagridview in it. That gridview is allowing its contents to be changed its cells are editable. When a button is clicked, a cell in the gridview is selected. This is how happeneing till now.
My clients requirement is, when that button is clicked apart from the cell is being selected, cursor must also be placed on the text of the cell, for user friendlyness. Pls. help me I will be thankfull to you.
The code that I am using to select a cell in the gridview :
dgvLasers.EditingPanel.Visible = true;
bEdit = true;
dgvLasers.SelectionMode = DataGridViewSelectionMode.CellSelect;
dgvLasers.Rows[intIndex].Cells[1].Selected = true;
Regards,
S/W Engineer
Akebono Soft Technologies
aleem_abdul@akebonosoft.com.
|
|
|
|
|
I am trying to use following regular expression to parse strings:
Strings I try to parse are for example:
My regexp should match all strings above.
Name can contain one underline character (_) but not two sequential characters (__).
Parameters start with first #-character and end to }-character.
If there isn't any parameters my regexp goes mad and takes next next line to <name>.
How I have to change my regexp so <name> doesn't allow double _-characters ?
|
|
|
|