Can I set up a data-driven menu box to have a default value?

I'm working on building a little webpage that lets user's
update one column.
So, for this column.. I have setup a drop-down box giving
choices (from a table).
I'd like for the box's "default" selected value to be the one
that is already choosen in the table...
How can I get this to bind?
Example: Each row need to get tagged as "lost", "won", or
"unsure".
I need these three choices to be in the drop-down (easy -
already done).
But if there is already a value of "won" for that column,
then I want the drop-down to say "won" as it's default.
Any ideas?
Thanks so much!!!

It looks like that VBScript already has this capability built
in.
<%If (Not
isNull((rsContact.Fields.Item("ContactNumber").Value))) Then
If
(CStr(rsNumber.Fields.Item("Number").Value) =
CStr((rsContact.Fields.Item("ContactNumber").Value))) Then
Response.Write("selected=""selected""") :
Response.Write("")%>
><%=(rsNumber.Fields.Item("Number").Value)%></option>
This markup is comparing the current value of the data from
the
rsNumber.Fields.Item("Number") recordset to the value of the
data from the
rsContact.Fields.Item("ContactNumber") recordset, and if they
are the same,
it is writing the selected attribute to the field -
Response.Write("selected=""selected"""). Is this not working?
Murray --- ICQ 71997575
Adobe Community Expert
(If you *MUST* email me, don't LAUGH when you do so!)
==================
http://www.projectseven.com/go
- DW FAQs, Tutorials & Resources
http://www.dwfaq.com - DW FAQs,
Tutorials & Resources
==================
"simp1eton" <[email protected]> wrote in
message
news:gbg6fd$1ts$[email protected]..
> Awesome, thanks!
> How do I fit it into the code of my list/menu?
>
>
>
> <select name="contactNumberMenu<%=counter%>"
> id="contactNumberMenu<%=counter%>">
> <%
> While (NOT rsNumber.EOF)
> %>
> <%
> rsNumber.MoveNext()
> Wend
> If (rsNumber.CursorType > 0) Then
> rsNumber.MoveFirst
> Else
> rsNumber.Requery
> End If
> %><%
> While (NOT rsNumber.EOF)
> %><option
value="<%=(rsNumber.Fields.Item("Number").Value)%>" <%If
(Not
> isNull((rsContact.Fields.Item("ContactNumber").Value)))
Then If
> (CStr(rsNumber.Fields.Item("Number").Value) =
> CStr((rsContact.Fields.Item("ContactNumber").Value)))
Then
> Response.Write("selected=""selected""") :
Response.Write("")%>
>><%=(rsNumber.Fields.Item("Number").Value)%></option>
> <%
> rsNumber.MoveNext()
> Wend
> If (rsNumber.CursorType > 0) Then
> rsNumber.MoveFirst
> Else
> rsNumber.Requery
> End If
> %>
> </select>
>

Similar Messages

  • Can we set the dynamic data source when using getReportParameters() ?

    Hello!
    I have a report where one of its parameters refers to a list of values (LOVs). This list of values is an SQL Query type. When the data source used in the report is defined in the BI Publisher server, I'm able to get the report parameters using the getReportParameters() function in my application. However, if the data source is not defined the function throws an exception, which is understandable.
    I decided to dynamically set the data source so that even if the data source used by the report is not defined in the BI Publisher server, it still will be able to get the LOVs for the parameter. I tried setting the JDBCDataSource of the dynamicDataSource for the ReportRequest object that I passed to the getReportParameters() function. Please see the sample code below:
    reportRequest.dynamicDataSource = new BIP10.BIPDataSource();
    reportRequest.dynamicDataSource.JDBCDataSource = new BIP10.JDBCDataSource();
    setReportDataSource(reportRequest.dynamicDataSource.JDBCDataSource, connectstr, jdbc, dc); //function to set the values for JDBCDataSource object
    reportParams = webrs.getReportParameters(reportRequest, uid, pwd); //call the getReportParameters
    I was expecting this to work as this is what I did to dynamically set the data source before calling the runReport function. So, my question is -- can we set the dynamic data source when using getReportParameters() ? I tried this both in versions 10g and 11g. It does not seem to work on both versions.
    Regards,
    Stephanie

    report_id column of apex_application_page_ir_rpt can help us uniquely identify each saved report.
    We can assign this report_id value to a page item and this page item can be put in the Report ID Item text box of the Advanced section of the Report Attributes page of the IR.
    This should load the saved report identified by report_id and you can get rid of javascript
    Regards,
    Vishal
    http://obiee-oracledb.blogspot.com
    http://www.packtpub.com/oracle-apex-4-2-reporting/book
    Kindly mark the reply as helpful/correct if it solves your problem

  • How can I set the insert date to auto update in Pages 5.2.2

    how can I set the insert date to auto update in Pages 5.2.2
    I am attempting to have the date in header auto update in a Pages file.
    I can insert it, but where is the AUTO UPDATE selection
    OS10.9.4
    thank you

    Apple never included the auto-update feature for dates in Pages v5.2.2. You would have to single-click the date, and deliberately update it.
    If you have Pages ’09 v4.3 in /Applications/iWork '09, then it will allow you to configure auto-update of the date field. Right-click on the date, set the format, and click the selection for automatically update on open.

  • How can I set an expiration date on a pdf in adobe acrobat 9?

    I am trying to set an expiration date for some documents, I have tried to use several javascript methods with no success. My adobe skills are very minimal so the easiest way possible would be appreciated.

    Acrobat can act as a client to the LiveCycle DRM encryption system but you must have an existing account on a LiveCycle ES/ES2/ES3 server with the Rights Management module activated. That requires you either license a copy from Adobe or work for someone who already has it running and who can issue you an account.
    LiveCycle ES3 is an extremely powerful enterprise-class solution for document creation and publishing, designed for use by hundreds or thousands of employees. To say it's not cheap is somewhat of an understatement, and the Rights Management module is an optional extra.

  • How can I set a password for firefox so that everyone have to enter the password before executing firefox

    My younger sister executed my firefox just at this afternoon(she originally use IE), and she saw something that can't be seen. How can I set a password for firefox so that everyone have to enter the password before executing firefox?

    Also see this for an English version of Profile Password:
    *Profile Password: http://nic-nac-project.de/~kaosmos/profilepassword-en.html#PPF
    It is an extension to protect the profile with a password, but being an extension that protection can easily be bypassed by starting Firefox in [[Safe mode]].<br />
    So do not rely on it.<br />
    If you want to protect content then you have to use methods supported by the OS like a separate user account with a password or an encrypted file system.

  • Some how I missed the set up assistant on my mac mini now I can't set up user accounts as I don't have a password ...help

    some how I missed the set up assistant on my mac mini now I can't set up user accounts as I don't have a password ...help

    Hmmm, did it come with an Install Disc? What OSX version is it?
    I wonder if this old method still works...
    Reset OS X Password Without an OS X CD...
    http://theappleblog.com/2008/06/22/reset-os-x-password-without-an-os-x-cd/
    It'll boot like a newly setup Mac, if it works.

  • Can you set up apple tv from cable box HMDI to apple tv box?

    Can you set up apple tv using cable box HDMI to Apple tv box if your tv has no HDMI slot?

    No

  • Can you set up outlook with a pop 3 and have folders installed on a iPad?

    can you set up outlook with a pop 3 and have folders installed on an ipad?

    Watch folders is a Windows only feature.

  • Data field FUNCTIONAL_YN does not support the default value (Message 14120)

    L.S.,
    When defining a data type of category NC, I would like to use data fields of type checkbox. At NC logging data entry the checkbox should be "checked" by default.
    When looking for the proper value to indicate that the ccheckbox is selected, I have tried values like: 0, 1, TRUE, FALSE, T, t, X, x ... etc. But always I got the same error message:
           "Data field FUNCTIONAL_YN does not support the default value (Message 14120)"
    What should be the right value?
    Kind regards, Hans

    Hans,
    It looks as if by means of GUI you cannot specify default state of being selected for Checkbox field. The default state is unselected.
    It is easier to invert the statement in the label of the field so that an operator could use unselected state as default.
    Regards,
    Sergiy

  • How can I set a due date for reminders?

    I DO NOT want it to remind me at a certain time. I just want it to be due on a certain day. You used to be able to do this when the reminders were part of the calendar on icloud.com, but now you can only set a day AND a specific time for an alert about the reminder, which I don't need.
    And as far as I can tell, you can't change it on the iPhone either. I'm guessing you can still change it on the iCal app on an actual Mac, but the whole point of icloud is that I don't have to carry my computer with me everywhere I go.

    I found a round about way to get the DUE feature.    
         click <<remind me>> and set a day
         select <<daily>>
         clink <<done>> and exit
    go back into the same reminder and you should see a due feature. 
    I then removed the reminder, but kept the repeat. As I use this for a check off for my bills.
    I think this only works if the date you select initially is in the future.
    Let me know if that works,
    morenalx

  • How can I set an validity date for a given vendor?

    Hello,
    we are currently trying to set a "validity date" for vendors.
    Basically, our vendors need to be audited, and are "accepted" for a period of time, beyond which we'd need to re-audit them.
    What we'd like the system to do is block use of the vendor if this date was exceeded.
    Anyone has an idea on the way to achieve this?
    PS: We know that there is a way to do this at the material level, we instead wish to manage it centrally for the vendor
    Tx

    Hello Nisha,
    before doing business with a new vendor for services, our QA group needs to go thru a serie of verifications. We check various things such as insurance, certification,...
    Once "approved", the vendor can be utilised by the plant for a certain period of time, after which a "re-audit" is necessary.
    What I'd like to implement is a field where the QA group would enter this date, after which the vendor would be automatically blocked for usage.
    This would then trigger the "re-audit" followed by the release from QA (who'd re-modify the date with the new one), and so on.
    The vendor is not necessarily used for supply chain. Sometimes, it could be for services , maintenance, or other.
    Tx for the ideas.

  • How can i set user's date format?

    problem:
    I have two users daniel and william.
    daniel login the EBS and the date format is :yyyy/mm/dd
    william login the EBS and the date format is : DD-MON-RRRR
    How can i set date format for everyone?
    Thanks.
    Daniel.
    2006.11.16

    Check the system profile ICX: Date Format Mask. Is it set at the application level? Does each user have different date format?
    How do you access the application? Through ICXINDEX page or through dev60cgi/f60cgi?
    Please note that changing the above profile option will not affect users logging through dev60cgi/f60cgi, in case you need to change it for the users who are accessing the application this way you can use the FORMS60_USER_DATE_FORMAT parameter in the url

  • How can I set up a data connection to an Oracle DB

    Hi,
    I want to set up a data connection to an Oracle DB.
    I know the first step is to go to New data connection, then select OLEDB database and then I need to create a connection string. Well from now on I am lost. What are the next steps I need to take? Does anyone has an example

    Your iMac with ARD... this is the bona fide, ($300/$500) "Remote Desktop.app" admin install, or do you mean that you have ARD "Remote Management" access enabled or have tried to control Vista with Microsoft's similarly-named "[Remote Desktop Connection|http://www.microsoft.com/mac/products/remote-desktop/default.mspx]" app? (Just making sure—it would be a very different conversation otherwise.)
    Remote Desktop does lots of fancy stuff, but for the Observe and Control mechanisms it behaves as a plain-jane VNC client. It can connect to any standards-compliant VNC server. You should, for example, be able to run a different VNC client on your Mac and have a similar success/failure experience; perhaps the excelent [Chicken of the VNC|http://sourceforge.net/projects/cotvnc>. If you have the same failures, we'll still help, but ARD is obviously not the culprit. In any case, the usual suspects for windows VNC servers include UltraVNC, realVNC \[paid ver. required for vista\], and TightVNC. They all have caviats, but they're fairly well documented. Vista itself throws VNC under the bus "in favor of security" but again, you'll find lots of users in the same boat; unable to get the VNC server working on the Vista side. Your statement that you "couldn't even see the machines connected to it to get the IP" was bit confusing though, as devices don't need to be running a VNC server to at least show up in a scan (IP printers should appear, for example). Are you sure they're on the same subnet of the same lan/being otherwise scanned for correctly; or if remote, are you sure the remote Vista laptop is directly addressable with NAT from the web?
    Let us know. Good luck. Joel

  • Why my atv can't set time and date after restoring it using itunes ?

    when my atv restarting after  I restored it using iTunes, it can't set the time and date.
    the atv is connected to the net by wi - fi.
    when I try to sign in using my apple id, I get a massage that the password is incorrect.
    I have apple tv with ios 7.

    The network and signal test on device won't give the full picture, for that you need a network report. Go to istumbler, netstumbler or similar, that will show true signal strength as well as any nose detected. You can also try Ethernet to help rule out WiFi issues.

  • Can you set a due date in Reminders on Mountain Lion?

    It seems that there is no way to set a due date for a task in Reminders on Mountain Lion.  In Lion in iCal you could set a Due Date that was different than the reminders you could set for a task.  It seems obvious to me that reminders are different than due dates.  Reminders can occur multiple times leading up to and on the due date (and perhaps even after a due date), but it is helpful to set a due date.  Hopefully Apple will bring this functionality over to Reminders from the Lion version of iCal, as this is a downgrade in this one respect for me.

    After having created a reminder, click on the little that appears when you hover over the right side of the list.
    Or, when creating a reminder, add the time and date, like this:
    "Say Hello 6:32 pm today"

Maybe you are looking for