Display Busy on pointer on mouse until the page loads completely [duplicate] - c#

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 7 years ago.
Improve this question
I just want to inform the user that the page is busy when it is loading or the action is being carried in the background or when the postback occurs by just changing the mouse cursor to busy.
The cursor should turn to normal pointer when the page is completely loaded in ASP.Net.

try this from setHourglass
With ASP.NET pages this is a bit more of a problem to do. You need to employ a little JavaScript.
Add this JavaScript between the tags on your ASP.NET web page:
Code:
function setHourglass()
{
document.body.style.cursor = 'wait';
}
Now you have to tell the web form to run the JavaScript funciton when a post back happens.
Add this to your tag:
Code:
<body onbeforeunload="setHourglass();" onunload="setHourglass();">
Also try this Hourglass-cursor-for-Web-ASP-NET-pages
Now to set it back to normal do this
document.body.style.cursor='default';

This helped me. However, it was for the ajax updatePanel. It may give you some ideas.
http://encosia.com/improved-progress-indication-with-aspnet-ajax/

Related

How to Suppress Event calls in Blazor? [closed]

Closed. This question needs debugging details. It is not currently accepting answers.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
Closed 2 years ago.
Improve this question
I have a page that has a form having a TODO list with Add Button and at the footer of the form there is submit and cancel button. When I press the add button in the todolist the Submit function is being triggered. How to stop this triggering of the submit function call on clicking add button
Default behaviour for an html button in an html form is to submit.
To prevent this add type=button to your button.

Access mainpage content from other page loaded in frame [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 5 years ago.
Improve this question
I'm developing a program in C# & XAML where my MainPage has two frames, one of which is an entire page.
I want to load another page inside the Inner frame of MainPage, which has a number of buttons. By pressing one of them, I want to load the Third Page in my Whole Page Frame (bigger frame).
Any suggestions to make this happen?
"frame" being the name of the frame you want your page to appear on and "ThirdPage" a page item of your project, you could add the code below to the button click event you are talking about:
frame.NavigationService.Navigate(new ThirdPage());

Using same menu on multiple pages ASP.NET [closed]

Closed. This question needs to be more focused. It is not currently accepting answers.
Want to improve this question? Update the question so it focuses on one problem only by editing this post.
Closed 7 years ago.
Improve this question
I'm trying to make one menu and using it on every web page I have instead of copying the same code in every file. This way I can change the menu in one file instead of 5.
I'm using ASP.NET Web Forms application (aspx-files).
I've tried googling it but the only result I get is PHP related, isn't there a way to do it with aspx/html files?
I think you're looking for master pages: https://msdn.microsoft.com/en-us/library/wtxbf3hh%28v=vs.140%29.aspx
You can create your menu in Web user control and then include it where ever you need
This link can show you how to add Menu bar in Master page, If Menu bar is in master page then you don't need to change the code in every page.
Master Page with Menu bar

How can hide controls in Windows Form Application without hide base form [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 9 years ago.
Improve this question
i'm sorry for poor English.
I have a form in my C# Winform Application. This form includes controls such as Label,TextBox...!
how can i hide Form without hide it's controls?!!
For example it use in create User Control such as DateTimePicker,...
how do work hidden and show calendar box in DateTimepicker?!!!!!!!!!!!!!
Well this isn't possible since the form is the root element and making it invisible automatically hides the children inside,
you can cleverly customize the height and width somehow according to your needs.

How to build Pentomino game [closed]

Closed. This question needs details or clarity. It is not currently accepting answers.
Want to improve this question? Add details and clarify the problem by editing this post.
Closed 9 years ago.
Improve this question
I want to build the Pentomino game in C#/XAML for Windows 8(8.1). I need field and draggable figures.
How I can do it? For draggable I'm using ManipulationDelta property, but how do I know that the figure is in the field and how do I attach it (figure in field)?
As your question stands, it's too broad.
For future reference, you should try splitting your problem into smaller problems, and asking seprate questions for each of them after doing some home research first.
Also, sharing some code about what you've tried can get more people to help you.
Having said that, I've never worked with XAML, though I've worked with C# for some time now.
About your problems:
For pentomino you will need a board. using Grid or DataGridView sounds like a good approch to me.
For representing your figures, your grid can be queried to find out if your figure can be droped on a certain square. Prepare for writing some for loops.
Abput drag'n drop, here are some links that you may find useful:
XAML GridView to GridView Drag and Drop Mouse vs Touch
Dropping an item on an UserControl item in GridView doesnt trigger Drop event (includes sample project)
How do I drag an element in Windows 8 XAML app?

Categories

Resources