i used formatdatetime(dt,vblongdate).it gives me in format like monday , august 8th, 2005.but i dont want weekday means monday or tuesday in my date so on.
<%
prior = Request("Date")
if isDate(prior) Then prior = CDate(prior) Else prior = #1/1/1900#
For dt = DateAdd("m",-1,Date()) To Date-1
%>
<OPTION value="<%=dt%>" <%If dt = prior Then response.write "SELECTED" %>><%=FormatDateTime(dt, vbLongDate)%> </option>
<%
Next
%>
</SELECT></center> </td>
</tr>
I'm trying to use DatePart and Datediff functions to show the formatted m/dd/yyyy display for the dates of Monday and Friday of the current week. I want it to display as:
Our Weekly Schedule 8/23/2004 thru 8/27/2004:
Can't pinpoint the parameter to check for the current week. Is there a good reference anywhere to show how to use the methods and such of both datepart and datediff, or has anyone programmed something similar prior.
I am trying (with Classic ASP) to pass from a form multiple selected check boxes. These are the days of the week. On the receiving page I need to check for the selected days between a date range (eg. 1/12/07 - 24/12/07) and write those dats to a database.
eg. all mondays and thursdays in the date range. I can wite the thing in vba no problem but into a web page and no satisfaction.
i am trying to use the DatePart function on my SQL2000 database. I have a table called visitors with a field called DateTimeEntrance which is filled everytime a visitor enters the site. I am trying to build a stat page where i display the total amount of visitors per day, week, month, year and i can't seem to get the syntax correct.
I get an error with the following code:
sql = "SELECT * FROM tblVisitors WHERE (DatePart("yyyy", [datetimeentrance])) = (DatePart("yyyy", date()))"
Is there anything wrong with my code (see below) bcoz when 10p-6a shift my browser returns the error cannot be a zero-length string. Im wondering why, bcoz the 2 other shift works perfectly.
<% 'Shift: 6a-2p if DatePart("h", Now()) 5 And DatePart("h", Now()) < 14 then ShiftID = "A" end if
'Shift: 2p-10p if DatePart("h", Now()) 13 And DatePart("h", Now()) < 22 then ShiftID = "B" end if
'Shift: 10p-6a if DatePart("h", Now()) 21 And DatePart("h", Now()) < 6 then ShiftID = "C" end if %>
I'm trying to increment between the end of lunch and the end of the day. The code below is returning a datePart of 13 instead of 1 (for 1:00:00 PM) and 14 instead of 2:00:00 PM etc. If response.write just counter2 I get a real hour. how can I return the actual hour datePart?
if it is 50. i want to remove the (dot) at the end. can someone tell me how to use the instr function to see if there is a dot at end and if it is there then remove it.
i have problem in removing the gap between two images, pls see the attached image. coz my item name is quite long, i dun wnat it display in horizontal, i want it display as vertical. so i create the images for the character and use ascii to recognized it.
my code is as below:
<td align="left" class="BorderLeft" width="1%"> <%dim word, pic, word1 word = "AAAAABABABBA" pic = "" for i = 0 to len(word)-1 word1 = cstr(right(left(word,len(word)-i),1)) pic = asc(word1) & ".gif"%> <img src="../images/<%=pic%>" border=1 vspace=0 hspace=0> <%next%>
The main idea goes like this: I have a textarea, on the right I have a listbox whose elements are loaded from an Oracle Database, I want to have an "Add" Button which when pushed will insert in the textarea the value selected on the listbox between "{ }" (ej, The {white} cat), you can add as many values as you wish and also manually edit the text, and a Submit button which open another ASP page that will check the sintax of the textarea and insert it on the Database. So far I already have the part which checks the sintax and inserts it on the db, and the listbox with the elements you can insert on the textarea, but my boss really wants the "Add-Remove" feature and I need to finish this for Tuesday
I have image icons that are clickable. I want to remove the hyperlink from around the image. I tried the STYLE="TEXT-DECORATION: NONE" tag but thats not working. How should I remove the underline from the hypelink. Code:
I am wanting to create a large dynamic web site with an accessible Text Only version.Instead of creating additional pages for the text only version, is it possible to implement some regular expressions, which remove all the IMG tags from page.
I have found a useful tool at http://tantek.com/favelets/ which removes the CSS from the page but I also need to remove the images.Are regular expressions the best means of doing this?
arrColour = split("blue,blue,green,red,purple,blue,green,yellow",",") What I need to be able to do is to remove all items of the value "blue" from the array. I can just run a dictionary function to delete all duplicate values, because some of them need to be retained. I just need to delete all of them of a particular value. how this can be done?
I have a basket which people add stuff to that they want to buy. i want a code that allows them to delete the item too. how the basket works is. thy choose a item from stock page and then it adds to a basket table.
I have declared a multidimensional array as follows. dim parray(100,5). Now this array contains some duplicate values. So how to remove duplicate values in this multidimensional array.
I have a page which takes data in an HTML table, and exports it to an Excel file. It works fine, but I want several things about the spreadsheet to look different from the HTML version. Things like fonts and colors. I think I can use a style sheet for the latter, but I haven't figured out how to remove hyperlinks from some of the items. On the HTML page, the hyperlinks are useful, but I don't want the spreadsheet to have them.
So on my ASP page which builds the Excel file, I have this: ...
used to other languages and using ASP for a particular project. Is there a way in which I can remove the first element from an array and then return the array with remaining elements intact?
Using ASP/VB I need to remove unwanted commas from the end of a field that will be use in an array. There are items in the field that are comma separated, so I don't want to remove them, just the end ones, could be anywhere up to 5 unwanted commas.
Is there a way I can remove items- item2 and rearrange above cookie into Response.cookies("items")("item1") = "111111" Response.cookies("items")("item2") = "222222"
How can I remove the page.asp link from the address bar? For example I have a link called www.mysite.com/page.asp?f=1, after the user clicks on the menu navigation. How can I get rid of page.asp?f=1 so that only www.mysite.com appears? Another thing, will request.querystring still work then?
I'm importing data from a csv file but have the following problem.
It see any comma in a specific column as the end of the current column and move the rest of the values into the next column I.E Data from column 4 display as data from column 5.
I do know that it's comma delimited but would like to know if there's no way that I can distinguish between the commas in a column and the commas that indicate a new column.
Col1 Col2 Col3 Col4 Col5 Value Value Value Val,ue Value