Skip Item
I want to skip an item in a loop, and go to the next item, e.g
[vbs]
For Each bla In ble
If bla = "skip" Then
'Skip to next item
End If
Next
[/vbs]
Is this possible, and if so, could you show me how?
I want to skip an item in a loop, and go to the next item, e.g
[vbs]
For Each bla In ble
If bla = "skip" Then
'Skip to next item
End If
Next
[/vbs]
Is this possible, and if so, could you show me how?
If the physical path of a page is :
" e:facecgi_bindetails\_Nviews.asp "
and i want to remove "\_Nviews.asp" portion from this path.means whenever the page refreshes,no matter what the name of the page is.the last portion of the name of the page with slash must skip out from this path string .....how can i do this while using VBscript Functions.....like using Split(),RIGHT(),LEN(),LEFT()...etc..
How do you make the following skip the first field?
Code:
<%for each x in rs.Fields%>
How do you make the following skip the first field? Code:
<%for each x in rs.Fields%>
i have a recordset in a results page
this retrieves all records but i only show the first 6 with all details (using a repeat region)
then i want to follow this with just thumbnails of the additional results
- this repeat region uses the horozontal looper
Either i need this second repeat region to start at number 7
or i need another recordset but with sql to ignore the first 6
(database is access)
can anyone offer any guidance on either solution?
I searched an issue on the net and in our forum but could not find any solution. My question is :
How to skip some block of code while programming in asp page so that I get the necessary part of page only???
I'm using ASP FormMail to collect user info, but now I'm trying to figure out how to modify the code so that any blank fields from the form will not be displayed on the confirmation page/email. I tried to modify the code below in bold, but it gave me a syntax error. Code:
View Replies View Relatedwhenever i fetch any numeric value, having a zero at the end, e.g. 32080, from a database with a recordset object, i find that the value becomes stripped of the last zero, i.e. it becomes 3208.
View Replies View RelatedIf the physical path of a page is : " e:facecgi_bindetails\_Nviews.asp "
and i want to remove "\_Nviews.asp" portion from this path ...means whenever the page refreshes,no matter what the name of the page is ....the last portion of the name of the page with slash must skip out from this path string .....how can i do this while using VBscript Functions.....like using Split(),RIGHT(),LEN(),LEFT()...etc..
how to get many item in LIKE funtion?
Dim count integer
Dim part() as string
For i = o to i =count step 1
Sql = "SELECT TOP 5 T1.A,T1.B " & _
"FROM Table1 " & _
"WHERE T1.A LIKE '" & item[1]& "%' " & _
But the array [1] got error. How to get the array?Please advise me for the above problem.
i've made a calendar that uses newsitems from an access database.
Every newsitem is a record (newsID, date, title, fact).
When the page is loaded for the first time a visitor looks at that page, I want to set the calendar to the newsitem that is closest to the present, but lying in the past. So, today we are the 13th of October. In the database, i've got two items with date "the 2nd of October" and "the 25th of September". The query should return me the 2nd of October. Of course, when that newsitem did not exist, then the query should return me the 25th of September.
in my asp file i get the following error
Error Type:
ADODB.Recordset (0x800A0CC1)
Item cannot be found in the collection corresponding to the requested name or ordinal.
/emirate/view.asp, line 175
my database is access,i checked both data base as well as the coding,both field names are correct
my sql is only this
sql= "select * from MasterEntry"
I want to reverse a folder listing, can I referre to a collection with a
item number like in arrays?
ex:
set fs=Server.CreateObject("Scripting.FileSystemObject")
set fo=fs.GetFolder(smp)
for each subfld in fo.subfolders
..
..
next
can I do the FOR statement reverse without putting all folder names into an
array.
i have a view cart page which shows remove an item and remove all item but i also wish to have add item function so i can add quantities for an item in the view cart page. i am not sure the right code for it. below is the remove item code.
if i wanna have an add item code, is there an amendment to do the code below . cos from what i see, its like u can do the opposite function for the code below to add items. Code:
i have a list form object on my page:
<select name="item" size="5" multiple="multiple" id="item">
<option>something here</option>
<option>something here</option>
<option>something here</option>
<option>something here</option>
<option>something here</option>
<option>something here</option>
<option>something here</option>
<option>something here</option>
<option>something here</option>
</select>
but i cant find anywhere about how to get at these elements when the forms been submitted. for example, if a few of the items have been select, it returns a commar delineated line, but how can i get at, say the 3rd item selected or find out how many items were selected?
i have two dropdowns(dd1 & dd2) in the same page. dd2 items depends on the item index from dd1.when dd1 is onchange, the form will get the dd1 index value and then do a search in DB for the results to be input into dd2.How can i achieved that?
View Replies View RelatedIs there a way of creating a sent record in a outlook users account. I am sending the mail through our exchange SMTP server.If this cann't be done.
View Replies View Relatedhave a look at this code and see if they can spot the error. I've been looking for sometime but I'm blind to it - I have a feeling it might be something to do with the ID field? The connection appears fine so this is unlikely to be the cause .
View Replies View Relatedhow can i add item/s to a dropdown from another page. i am currently using window.opener to initial the link between the 2 different pages. i have 2 pages, main and sub page.
when i clicked on a button at the main page, it will pop out the sub page. when i clicked on the add button at the sub page, it will add the item into the dropdown list at the main page on the fly.
I know what this error is, all fieldnames have been verified and reverified. Not sure why it is happening. Here is the SQL statement
strSQL = "SELECT Problems.TicketNumber, Activity, ActDate FROM Problems LEFT
JOIN Resolutions ON Problems.TicketNumber = Resolutions.TicketNumber WHERE
Problems.TicketNumber = " & Ticket & " ORDER BY ActDate DESC;"
<td><% = rs("Problems.TicketNumber") %></td>
if it is possible to narrow in on an item within a listbox of states. For example, right now if I type "W", I will immediately drop down to those states beggining with "W".
However if I type "WI", I go to the top of the list with those states beginning with "I". I would like to continue to zero in on the state by dropping down to those that begin with "WI". Is this possible and if so, how do I go about doing it?
I'm doing an e-inventory system using Dreamweaver MX, ASP. The problem is that I want the system deleted the item that user already choose to use, for example in the store they got 12 keyboard. then when user choose to take 2 keyboard, I want the system automatically state the item left in the store was 10.
View Replies View RelatedI've got this listbox and this text field on an ASP page. Now I want the item I click on in the listbox to appear in the text field and I can't find the code nowhere for what seems to me such an easy thing to do.
View Replies View RelatedHow do I make an item the selected one based of the info I get from a querystring.
ie:
1 - I pass in a query string containing the color "blue"
2 - I have a drop box that has 30 colors in it (inserted manually)
3 - How do I code to have blue the selected one?
I'm getting this error working on a RecordSet that is filled by a LEFT JOIN query. Everything works fine, until an attempt to access data from the child table in the RecordSet when it doesn't exist.
Which results in "Item cannot be found in the collection". Is there a check that I can perform to see if a RecordSet item exists before attempting to access it?
if i have four option buttons all named r1, what will request.item("r1") give me??.. the "value" of the selected option button or what??..
View Replies View RelatedHow can I in a loop do something to every second item? my code is (extracted from within a loop) :
Code:
dblTotalPrice = cDbl(dblTotalPrice) + cDbl(qtyprice)
itemsincart=itemsincart+qtyselected
shipping= itemsincart*shippingrate
Discount='need to figure out discount
TotalPrice=dbltotalprice+shipping
What I need to change is that for every 2 itemsincart the discount will be half of the second item.
I am taking over a script that was created by someone else. I am trying to do a search for one card that is listed in two different categories, and I only want it to bring the card up once.
<input name="Order card" type="button" id="Order card" onClick="MM_goToURL('top','http://home.amm.org/cards
/search.asp?title=DG006');return document.MM_returnValue" value="Order card">
Right now it is bring up a page with the same card listed twice. Which is correct, cause it is listed in category 2 and in category 4. I want it to bring up the card from category 4 with the title DG006. And only show the card once.
Is there a way to remove item from cookie collection that has a key to it...
--
Response.cookies("items")("item1") = "111111"
Response.cookies("items")("item2") = "222222"
Response.cookies("items")("item3") = "333333"
Is there a way I can remove items- item2 and rearrange above cookie into
Response.cookies("items")("item1") = "111111"
Response.cookies("items")("item2") = "222222"
I have an array of lets say 10 items, I now want to remove an item, lets say
from somewhere in the middle, based on one of the element values equalling a
value I specify - is there a "clever" and "quick" way of doing this or, will
I need to iterate through it looking for a match, and build another array
where I dont find the match etc...
I have a script which creates an array by doing this:Code:
strInputValue = "this will be split into an array"
arrMyArray = split(strInputValue)
This produces an array of 6 (UBound(arrMyArray) = 6).
Is it possible to remove part of the array, so that "into" for example will be removed, such that UBound(arrMyArray) = 5?
Is there a way to display a Secure / Non-secure item from a ASp web page.Does anyone have any idea what i could type in in the URl or anywhere in the page to break it.
View Replies View RelatedFor Each keyb In Request.Form
If Left(keyb, 15)="excelFieldName_" Then
'Response.Write(Request.Form(keyb) & "<br />")
ReDim Preserve arrExcel(myCounterb)
arrExcel(myCounterb) = Request.Form(keyb)
myCounterb = myCounterb+1
End If
Next
I am able to get the values in the arrExcel array with the code below...
for each item in arrExcel if item <> "None" then
Response.Write item
Response.Write("<br>")
End if
Next
What I would like is to get the index of the item I have found from the array. I then need to get the corresponding index from another array.
I tried item.getIndex, but that does not work ..