We are currently building a request form in html that will allow users to look through a learning catalogue and if they want to apply for it they click the apply button which takes them to a request page and automatically chooses the resource from a drop down to save them having to choose it themselves.
Is there any possible way to do this?
Thanks.
Related
I have developed an application that tracks financial transactions. In the form used for data input, there is a dropdown where the user would choose the reason for the transaction from a fairly long list of choices. To clarify the choices, there is also a gallery that gives transaction codes and explanations for each of the choices in the dropdown. My client has asked if they can click on the choice in the gallery causing the dropdown to select that choice.
I created a variable that is blanked out when the screen with the form in question is opened. I also set the default of the dropdown equal to the same variable. From there I can choose an item from the gallery via an icon and set the variable equal to the desired field in the gallery, which causes the dropdown to populate with the desired value. However, if the user chooses from the dropdown first, then tries to choose from the gallery, I lose the functionality due to defaulting to the variable no longer works. I want to reset the dropdown when I choose from the gallery, but I can't get the dropdown to reset from the icon in the gallery since the gallery is outside the form.
Thanks.
I have a site which is populated from a database. I want to access the pages in Selenium. The number pages associated with a particular topic is variable.
Using Selenium I am clicking through successive pages using a line like
driver.find_element_by_xpath("""//*[#id="mainContent"]/
div[2]/div/div[2]/div[1]/
div[3]/div[2]""").click()
This works successfully.
However I would like to detect when the element I am clicking (a next button) is "greyed" out rather than having to predict how many pages are available.
Currently I am using a block of code inside a for loop with a counter for the number of available pages.
EDIT: The page element has the word Inactive added when it is "greyed out" as in
<div class="paginationBtn paginationNextContainer inactive"><div class="icn chevron-left"></div><div class="visuallyHidden">Previous</div></div>
If your button is changing its color on click, it's associated with CSS attribute.
I advise to look at this answer to learn the subject. For your case, I advise you to develop a method to get the button color value before and after, as your script should operate accordingly.
I have created a help index on a tab control with 60 pages. Each page contains helpful information to the question that corresponds to the page. The questions that are being answered are on a different form from the tab control form. I have created a button next to each question so that the user can access the help form if they need background and instructions for completing each question. I am trying to write code that will open the form and go to the correct page based on the button that was clicked. So the button for question one would open the form and go to page 1. I have tried a few different things, and can't get it to recognize the page. Below is the code that I currently have in place:
DoCmd.OpenForm "frmTestingHelp"
Forms!frmTestingHelp.SetFocus
DoCmd.GotoPage (0)
The form opens, but cannot find the page and results in an error. I started without the second line, but added it to see if the issue was that it wasn't looking for the object in the right place.
Thanks in advance!
DoCmd.GotoPage is used only with page breaks, which hardly anybody uses. See e.g. here: http://www.functionx.com/vbaccess/Lesson13.htm and scroll down to "Using the Pages of a Form".
To select the second page of the tab control TabControl on your form:
Forms!frmTestingHelp!TabControl.Pages(1).SetFocus
or preferably, if you don't want to set the focus,
Forms!frmTestingHelp!TabControl.Value = 1
assuming you haven't changed the default PageIndex values 0,1,...
So no SQL tables or anything here. Basically, I have 3 pages that have 6 items each. Each item consists of an image and then some text and also a smaller image than changes from a check to an "x" depending on if user selects or not. So if the image is checked, the user is adding that to a list which would display on a fourth page. This data needs to persist through just a session and if the session times out, then it resets. If the list is complete and on that fourth page the user choices to email or share list via social sharing, then the data would be gone after that action. What I am trying to figure out is the best way to approach and implement this with minimal time and effort as it has to go out quickly. Can any of you explain and maybe point to some links with info on the best way to achieve?
This is being done in asp.net web forms with html, css, and javascript.
Much appreciated!
You can use ViewBag() (for view in razor) or ViewData[] (for page in .net) to hold data for one web page.when you want it to other page. You can pass it to other page.
check this out
ViewBag, ViewData and TempData
I have a html drop down list in my web site. When the user selects a particular item in the list I want it to be shown in all the pages when the user navigates through the site.How Can I do that??
I am using visual studio 2010 and mvc3 views. Currently what happen is when the user selects a particular item,the selected value only stays for the current page, when I go to another page, the default value, which is the very first item in the list is shown.
How can I have persistent dropdown list value??
Thanks.
There are different ways to achieve this. You could store it in Session or Cookies. So for example on the first page create a form containing the DropDown with a submit button. When the user clicks on the submit button the form will post the selected value back to the server and the server could either store it in Session or client side cookie. Then the controller action could redirect to some other action which will be able to retrieve the value. And from now on this value will be available on all subsequent requests.