|
Privileges within your own app ? You would basically define for yourself how to do that, how you store them, define them, and check them before performing an action.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Erhm, there are too many ways to handle users & privileges. You should choose the best of all options depending on the needs of your client.
You can create a security object yourself, or you can use the windows authentication (for example use domain users etc)
The number of possibilities is enormous...
|
|
|
|
|
If you're developing this as an ASP.NET application, you can use the Membership and Role Providers that are part of the .NET 2 installation.
|
|
|
|
|
Hi all,
I have a no. of forms in a Wndows application I want to naviagte to different forms on button click Event.
How can I do this....
|
|
|
|
|
Erhm.... I think I understand your question partly. You have several forms which you want to display.... Do you want to show multiple forms at once, or just one each time?? Explain a bit more please...
|
|
|
|
|
Yeah I have several forms.
And I want to display a form at one time.
And I want to navigate from one form to other form on click event.
|
|
|
|
|
I could understand you very wrong, but you app. looks like a wizard like app. Can't you use a TabControl on a single form??
Anyway, double click the button in design view to generate the click event.
newFormName yourNextForm = new newFormname();
yourNextForm.Show();
this.Hide();
|
|
|
|
|
To show a form, create an instance of it, and call ShowDialog(). This is winforms 101, you should buy a book and work through it.
Christian Graus - Microsoft MVP - C++
"I am working on a project that will convert a FORTRAN code to corresponding C++ code.I am not aware of FORTRAN syntax" ( spotted in the C++/CLI forum )
|
|
|
|
|
Hi Christian,
I think you got me wrong.
I have a number of predesigned forms already. That need navigation from one from to another form on click event.
Sangram
|
|
|
|
|
I want to know hoe to erite program to stay in system tray while it is running . Something like virus notification.
-- modified at 7:05 Wednesday 11th July, 2007
|
|
|
|
|
Drag a NotifyIcon control on your form. Select it with a single left mouse click and press the 'F1' key on your keyboard...
|
|
|
|
|
You will need NotifyIcon control
|
|
|
|
|
when ever ToolStripTextBox control got focus, i want to make a AutoCompleteStringCollection so that i can assign this collection to
ToolStripTextBox.AutoCompleteCustomSource property.
but the problem that i m facing while i'm typing in this ToolStripTextBox the Enter event raises again and again
can anyone explain me this behavior?
|
|
|
|
|
Has anyone managed to impliment NUnit testing on an Excel plugin project using Add-In Express ? I can write the tests, but I can't get an instance of Excel to work with.
Sorry if this is not the correct forum.
Johan Lombaard
Only two things are infinite, the universe and human stupidity, and I'm not sure about the former - Albert Einstein
|
|
|
|
|
Hi,
in my application (.NET 1.1, Windows.Forms) I have built a progress bar form, which is started in its own thread. It gets the progress information from the main thread and is thus successfully redrawn during the calculations - when it is kept on the top.
My problem refers to the window instances: I want the progress bar form to be always on top of the main form, but that seems not to be easy. It always shows up on top of the main form, when I define the main form as its owner, but then the progress-bar form is not redrawn during the calculation. At the moment I have it not defined as owned by the main window, but when I now bring another window on top and then want to change back to my, still calculating, application by activating it on the task-bar, the progress-bar window is invisible under the main window.
I hope, you understand my problem... What do I do wrong? Is it not allowed to define a form, which was created in an own thread, as owned by a form created in the main thread?
Thanks in advance,
Alex
|
|
|
|
|
Hello,
Have you tried the "TopMost" property of the Form?
All the best,
Martin
|
|
|
|
|
Thanks for the hint, I tried it and it works as expected, but that would be just a workaround, I think that the user will be annoyed by such a status window (I would). Is there another chance to make this window on top of my program´s windows?
|
|
|
|
|
Hello,
Maybe you like:
BringToFront();
SendToBack();
All the best,
Martin
|
|
|
|
|
Unfortunately this also does not work. With each progress update I execute:
this.BringToFront();
this.MainWindow.SendToBack();
this.Focus();
Console.WriteLine("Forcing to front..." + DateTime.Now.Ticks.ToString());
This is continually executed, but I still can only make the progress window visible by minimizing other windows
|
|
|
|
|
Hmm...
Would it be an option if you use ShowDialog from MainForm to show ProgressBarForm?
All the best,
Martin
|
|
|
|
|
I am already using ShowDialog from a special class I created to implement starting the second thread. But when I use the overload providing the "owner" I get the same result as when defining the owner "manually".
I´ll have to correct me: The problem which I encounter when I define the owner is that however the progress bar is redrawn, but the buttons on the progress form cannot be clicked (do not fire an event) as well as the whole form cannot be moved with the mouse, it sticks on the owner form and does not react.
|
|
|
|
|
Hi,
you dont need a separate thread to show a progress bar.
you could call Application.DoEvents() every time you update the progress, but I do not
recommend that, it is a hack/ugly/not descent/whatever.
You would be better of using another thread to do the lengthy calculation,
and let the main thread (aka GUI thread) show the progress bar; to get it on top,
make it a form owned by your main form.
To communicate from your lengthy calculation thread towards the progress bar, you would
need Control.Invoke if that thread holds the update-progress initiative. I often do it
the other way around: have a Forms.Timer periodically interrogate the calculating thread
about its progress (e.g. use a property of your job object) and update the progress bar.
|
|
|
|
|
|
Hm, this class is Framework 3.0 specific.
|
|
|
|
|
Nope, it was added in .NET 2.0.
|
|
|
|