|
Your code is a bit of a mess as it's doing stuff that has nothing to do with saving the file.
DialogResult sfdresult = sfd.ShowDialog();
if (sfdresult == DialogResult.OK)
{
sslblCurrentOp.Text = "Saving...";
strFilePath = sfd.FileName;
mnuSave.PerformClick();
blFileNeedsSaving = false;
sslblCurrentOp.Text = "Ready.";
ssMain.Refresh();
this.Text = "TriviaPad v3.0 - " + Path.GetFileNameWithoutExtension(strFilePath);
mnuSave.Enabled = tsbtnSave.Enabled = true;
}
Once you check the DialogResult for OK, you're doing a ton of stuff that has nothing to do with saving the file and that's where you're problem is.
Why on earth are you calling mnuSave.PerformClick()? That just kicks off the event handler that this code is sitting in all over again, including putting up a new Save dialog!
Strip all this stuff out of the if statement, put it into it's own method for updating the user interface, forget the PerformClick call completely, and just do nothing else by save the file.
|
|
|
|
|
Hello am new to entity frame work and am trying to create two chained comboboxes. am only able to read to one combo box but failing to put a where clause in my code. Bellow is the
Try
Dim db As New SRSEntities
db.Configuration.ProxyCreationEnabled = False
cmbDistrict.DataSource = db.Districts.ToList()
cmbDistrict.DisplayMember = "DistrictName"
Catch ex As Exception
MessageBox.Show(ex.ToString)
End Try
Please help how i could create a chained combo box, code samples if possible will be highly appreciated
|
|
|
|
|
Well, you need at least one combo box as the parent / "master" ... so, which one? I only see one cb.
"(I) am amazed to see myself here rather than there ... now rather than then".
― Blaise Pascal
|
|
|
|
|
Hi, I have a problem with the answer my calculator is giving me, for example I input sin 60 and the result produced is -0.304810621102217 instead of 0.866025403.
The code I used is:
Public form
Dim operand1, operand2, ans as double
Dim operators as string
Dim n as int32
Private sub buttonsin_click
Ans = math.sin(label1.text)
Label1.text = ans
Label3.text = "sin"
Private sub buttoncos_click
Ans = math.cos (label1.text)
Label1.text = ans
Label3.text = "cos"
Please help me with the solution.
|
|
|
|
|
|
|
What is role based security ?
Please Do suggest i am beginner in this field
|
|
|
|
|
It is "security based on roles"
So instead of saying "latakurekar guards that door", you have a role that says "door guard" to which you assign latakurekar. Instead of saying "Max and Eddy guard that chicken", you have a role saying "chickenguard", and assign the role to Max and me.
This has the advantage that you put the rights on the role, not the person. It might not be impressive in the example, but if you have lots of people it is crazy to manage each persons' right in detail. Instead, they get a role assigned, and access is granted based on those roles.
Role-based access control - Wikipedia[^]
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
"If you just follow the bacon Eddy, wherever it leads you, then you won't have to think about politics." -- Some Bell.
|
|
|
|
|
What Eddy said, but under normal system administration approaches it means that you do four things:
Granularize permissions
Give permissions to groups rather than to users
Assign users to groups based on roles (a role can - and should - belong to multiple groups)
Maintain those groups consistently
There are a lot of resources available from NIST about RBAC:
Role Based Access Control
"Never attribute to malice that which can be explained by stupidity."
- Hanlon's Razor
|
|
|
|
|
Hi,
My application is developed on dotnet core,
1)Do i need to install Dotnet Core on deployment server?
2) Can dotnetcore application runs on .NET Framework without installing dotnet core framework?
|
|
|
|
|
Syed Shakeer Hussain wrote: 1)Do i need to install Dotnet Core on deployment server? Yes.
Syed Shakeer Hussain wrote: 2) Can dotnetcore application runs on .NET Framework without installing dotnet core framework? No.
Bastard Programmer from Hell
If you can't read my code, try converting it here[^]
"If you just follow the bacon Eddy, wherever it leads you, then you won't have to think about politics." -- Some Bell.
|
|
|
|
|
Created a Custom Windows Forms WebBrowser to be opened a fixed url and search bar is disabled as per requirement. When user traversing next page (clicking next button available on the web page) there are few links which are opened in new window. And they are invoking default Internet explorer with search bar option. Can I disable the page to be opened or grey out the content having such links on the basis of next page url. Or if there any option to get the link opened in same window. Please advise.
|
|
|
|
|
If I understand what you're wanting to do, there is no reliable way of disabling the links. You'd have to rewrite the HTML after it's download in order to do that and there's many ways of putting links into the page that your code will not be able to disable.
|
|
|
|
|
Thanks for response. Can I capture the event whenever url has been changed. If possible, when user navigate certain page which consists of these kind of links (open in new window), we can try to exit or grey out the custom window. Please advise.
|
|
|
|
|
Unfortunately there's no reliable method for doing this. As content can be dynamically written in on the client side, there's not a lot you can do.
This space for rent
|
|
|
|
|
|
difference between angular 1 2 3 4 5 6 and 7
|
|
|
|
|
The difference is 1 each time. From 1 to 2 is 1. From 2 to 3 is 1 and so on.
If what you are really asking is what are the features of the different versions of Angular, you could start with a simple Google search[^].
This space for rent
|
|
|
|
|
The difference is that NG1 was worth using as a good, dependable, and flexible platform.
Then all the others happened.
"Never attribute to malice that which can be explained by stupidity."
- Hanlon's Razor
|
|
|
|
|
difference between interface and abstract class in c#
|
|
|
|
|
Have you never been taught how to search for your own information? The three questions you have asked here could all be answered with simple Google searches.
This space for rent
|
|
|
|
|
difference between api and web services
|
|
|
|
|
I'm sorry but I have to conclude that you are a help vampire[^].
This space for rent
|
|
|
|
|
I have a .NET (not MVC or ASP.NET) application (which is an Excel plugin), which performs 1 REST call for data (REST call is a protected resources - requires authenticated user). Currently this Excel plugin authenticates with the REST backend using basic authentication (with username/password input fields). Users are authenticated on a Windows domain.
Problem
I want to get rid of the username/password inputs and start using SAML2 to achieve true single signon for these users.from within this .NET application.
Question 1: Is it possible to perform client-side SAML2 authentication for my app?
Which framework/library to use?
If it is possible (I hope so...), I found this info:
"No is official C# client-side protocol stack", but there are various 3rd party libraries which implement SAML2", but these seem all focused on ASP.NET.
Sustainsys.Saml2
OneLogin
AspNetSaml
ITfoxtec
I've tried several libraries but they all seem to want to redirect the user (in browser - which I don't use in the app) to a specific endpoint.
I am no .NET guru, so if it is possible, any library with a clear example/tutorial would be really appreciated.
Thanks
Katherine
|
|
|
|
|
Hi all,
We created a windows application, we are going to sale it but we need to create a license key for that application
license key should be valid for one user and one time only
any other suggestion..
|
|
|
|