ASP .NET Using a Repeater inside of UpdatePanel with UpdateProgress - updatepanel

I am using ASP .NET 4.0 using C#. I have a web form where all of my layout exists within an UpdatePanel. Inside it I have the following:
Panel for entering search criteria with textboxes and search button
UpdateProgress with animated .gif
Panel with a Repeater that gets populated according to my first sproc (using the search criteria) - inside each row is a LinkButton that when clicked calls my second sproc and populates a Panel within the Repeater row. I am populating the Panel in the code-behind in the ItemCommand event of the Repeater. I use the CommandArgument on the LinkButton for my second sproc. I have a CollapsiblePanelExtender to animate the Panel that contains data from my second sproc.
I have it working but not the way I want. When the search button is clicked the UpdateProgress does show my animated .gif. However, when the LinkButton is clicked within the Repeater datarow my second sproc takes about 6 seconds to process. I want to have an UpdateProgress that shows an animated .gif when this occurs. I tried to fix this by implementing a second UpdatePanel but I could not get the UpdateProgress to fire at all. Any help would be greatly appreciated. Thanks in advance.

I have this all working now.
After much digging I found this: How to do AsyncPostBackTrigger for the LinkButton in the Repeater
I was able to use this in my Page directive: ClientIDMode="AutoID"
I also ended up adding an ImageButton to my Repeater datarow, and whether I click on the LinkButton, ImageButton, or Search button I get the desired result now - the UpdateProgress fires and displays the animated .gif file.
My UpdateProgress resides inside of my UpdatePanel and has an AssociatedUpdatePanelID set to the ID of my UpdatePanel.
I hope this helps someone.

Related

Using AfterUpdate event on a control in one subform to requery a control on another subform

I have an Access 2010 database set up with using the native Navigation Form interface feature.
Using this very helpful table, I've been able to use vba on multiple ocassions to reference forms throughout my database. However I seem to be having difficulty in this one instance.
On the Navigation form I have a number of main tabs. Clicking on one of the main tabs brings up a number of sub-tabs that have various forms attached to them.
On one of these sub-tabs, I have a main form (main) attached to it. There is a subform (subform1) within that main form containing a control text box (control1). Within subform1 there is another form (subform2) containing an unbound text box (control2) displaying a value that is calculated using a TempVar.
I want to use the AfterUpdate event on control1 to requery subform2 in order to update the calculation in control2, or simply requery control2.
Using Refresh and/or Requery on the AfterUpdate event for control1 does not do anything to control2.
Currently I have a button on subform2 that users can click which refreshes the form and updates the value in control2. The user can also hit F5 and refresh all the forms with the same result.
My goal is to take away the manual aspect and have the AfterUpdate event for control1 to update control2.
Any help would be much appreciated as I haven't been able to find anything online that works and I've been kicking tires at the problem for over a month now.
**** UPDATE **** I did not correctly describe the layout of my forms. subform1 and subform2 are actually both nested under main. subform2 is NOT nested under subform1 as I originally described above.
Wow. Now I feel like an idiot. Tackling my problem again with the update I provided above allowed me to solve it.
All I needed to do was requery subform2 by referencing it this way:
[Forms]![HOME]![NavigationSubform].[Form]![subform2].[Form].Requery
Where "HOME" is the name of my Navigation Form.
For anyone with the same issue that hasn't renamed their Navigation Form I believe the syntax would be:
[Forms]![Navigation Form]![NavigationSubform].[Form]![subform2].[Form].Requery
Thank you to #Erik von Asmuth and #June7 for your patience and help.

How to use tabstrip in VB6?

I searched about tabs in VB6 over and over, but I couldn't find anyway. How I can replace buttons and other thing in which tab?
Private Sub TabStrip1_Click()
Here I found the answer. All objects in each tab must be in one frame and each frame must be for a special tab.
http://www.vb-helper.com/howto_use_tabstrip.html
Start a new project
Add a new form from availables templates: choose the Options window template
Now you have a form frmOptions which contains a TabStrip named tbsOptions, complete of code to manage the tabs using the Click event.

passing a variable inside a variable to an angular directive in html

I am doing a signup form with a few steps, made with angular material tabs. I have 5 tabs each containing a few inputs that the user should fill in. I also have 2 buttons below the tabs, one to get to the next tab and one button to get to the previous tab. I want to disable the upcoming tabs and also disable the button that takes the user to the next tab until the user has filled in the the tab he is on properly. I want the user to be able to go back and change the information that is already filled in on the previous tabs, and when all the tabs are filled in properly a send button is shown. So, that's basic functions for a multi step signup form.
I have managed to do the basic functions for the buttons and the tabs with ng-disabled and ng-hide combined with changing the value on the variable tabNr in my controller, like hiding the previous-button on the first tab and hiding the next-button on the last tab, and that works fine.
When it comes to hide the next-button based on if the form is filled in its a bit more tricky. I am able to disable the next tab by validating the form on the previous tab like this: ng-disabled="!tab1Form.$valid", so that's hard coded and works fine.
The previous- and next-buttons, though, are the same for all tabs and that is the tricky part, so I can't just disable the button if a form isn't valid because the button does not know which tab that is active. I have tried to make a function in the controller but then the problem is that the valid-variable is just a thing in html and I cant evaluate it in the controller.. As far as I have tried and have understood.
So this is the next-button:
<md-button ng-click="FormCtrl.tabNext()" ng-disabled="FormCtrl.tabNr >= 5 || !tab{{FormCtrl.tabNr}}Form.$valid" ng-hide="FormCtrl.tabNr > 4">Next</md-button>
Each tab has this, with it's own number:
<form name="tab1Form" novalidate>
What I've tried is to change the tab, that should trigger the disable, by using angular:
ng-disabled="!tab{{FormCtrl.tabNr}}Form.$valid"
The browser seems to change the number, and it works for the first tab, but on the rest of the tabs it does not disable the button even though it should, like if the browser does not evaluate the variable properly. I hoped that it should work because I cant think of another way of doing it with these variables...
Does this way of using angular simply not work or am I doing anything wrong? Does anyone have a solution I could use?
In your controller
function Controller($scope){
var vm = this;
vm.form = $scope['tab' + anyNumber + 'Form'];
}
then in your html
ng-disabled="!FormCtrl.form.$valid"

incompatible type passed in as a parameter created by loading a GUI component.

I am having a problem with a UI that I am building in a Google Spreadsheet. I will First explain a little about how it works and than I will get to the problem. The UI is fairly simple program that connects to a SQL database, it allows users to create new records, Query, search, and render reports. I have created all the panels (eg the intro page, the create record) in the GUI builder. As the user navigates through the UI I swap out a Grid with the new panel that i want the user to see. For example on the intro page there is a create button when the user clicks the button the gird where there intro panel was is replaced by the create record panel. I have created two ways for the user query/search for data. The first way is to select a number range on the intro panel and click the Query button. This will than query the last 10 or so records into a GUI built Panel that I will call MainForm. The second way is to "search" for a job. On the intro page there is a search button when the user clicks with button it goes to a new page; the grid is switched to the search panel. On the new page/panel the user can put in some parameters to search for. After the user clicks the search button the program should load the search results into the MainForm in the same way as when you Query from the intro page. I have taken the whole function apart line by line, so i am sure that the issue has to do with loading the panel/Component. What i mean by that is these few lines of code.
var Component = app.loadComponent("MainForm");
var panel = app.createVerticalPanel().setSize("770px", "900px").add(Component);
app.getElementById("contentGrid").setWidget(0,0, panel);
But why would it load in one case, but not in another? Also it is not the method of loading the Component, rather it is the returning the panel/ Component.
To Summarize, When I load the Component with the query function it works, but when i load the Component in the search function I get and error: Incompatible type passed in as a parameter. Also I load the MainForm Component in two other functions as and it works most of the time, but some times I get the same error.
I think your approach is not ideal, load component is not supposed to be called multiple times. It would be far more efficient to get all your panels in the same compnent and play with visibility of each panel to show / hide them on demand. Each panel should be inserted in a vertical panel so that the "new panel" slips to its place when the "old one" hides.
An example of this approach is shown in this post to simulate tabs and could easily be adapted to your needs.
btw, this method is also very fast and responsive since the full UI is ready from the very beginning ;-)

Oracle Forms : How to make a window/canvas/form the starting one

I have a school project where I have to make a small database application using Oracle Forms.
I have 4 forms in my application:
A login form
A main form
A form that is displayed after the new button is pressed on the main form
Another form that is displayed after the edit button is pressed on the main form.
I've created the forms in the mentioned way.
When I start the application, I want the login form to be the starting form. Now what starts first is the edit form (the last one created).
How can I manage that?
Thank you.
The form loads that canvas first which holds the first data block in the Object Navigator. So make sure that your login form block is first on the list.
You can also set the "First Navigation Data Block" in the Property Palette for the form to the desired block on the login form and it will display that first, overriding the first block in the other answer.