The Name-the-function Game
I'm trying to detect if a specific character is in my string. I looked through all the string functions via-google and I can't seem to find one. I'm trying to use:
if InStr(myString, *) = "" then
print: the * isn't in the string
else
print: the * is in the string
end if
but this doesn't seem to work... Any ideas?
View Replies
ADVERTISEMENT
I am developing a blackjack game which is multiplayer, multitable game in which 4 users playing on each table.
There are 8 tables like this.
I am generating random cards through my random card function. Main problem is that I want to track cards for avoiding repitition. I can use application veriable for one table . But how to do for multitable ? We can't track it on session side as well as application side as all tables are in one application.
View Replies
View Related
I am looking for a free ASP game code that I can use on my site. I'm not too fussed what thjegame is but I would like ti to have a higgh score chart to increase the interactivity of my site.
View Replies
View Related
I'm trying to teach myself ASP, I've done very small modifications before but would like to get into it seriously and so have decided to build a website using ASP, obviously this has to be something of interest to me to help me through the hard "head scratching" coding times, so I've decided to attempt to make a fantasy league game for Moto GP.
I know, I know not very easy (well maybe it is for you, but not me) Anyways I was looking for a good script on the web which I could sit down and look at and then rip to pieces and rebuild so that it will fit what I want it to do (I often find it's a good way of learning)
However I've been completely unable to find an ASP script anywhere for a fantasy type game.
View Replies
View Related
Eu gostaria de criar a seguinte página e gostaria da ajuda de todos. I have a data base (jogos.mdb) that he has a name table (resultados). In the table resulted I have the
fields: data | time1 | resultado1 | time2 | resultado2
I want to create a command that goes to show these information nu'ma line of a page any. Example of as he will have to be shown: 12/03/2006 São Paulo 1 x Saints 0 . I would like to not only call these information a data base that goes to be in another site and in that the data base will be housed. I do not have idea of as I can make this. They can help me to create this page.
View Replies
View Related
how to MONITOR (send/recieve) data from a game? (or game server) I've spoken with a few people, and they say I need to tie into the game's API that it uses for the chat channel, but I've no idea how to do that (I assume a technology like ASP, along with some other technologies or not) should be able to communicate with a game. Does anyone have resources I can read up on or can spread some light on the situation?
View Replies
View Related
What's the difference between private and public functions in ASP? When should I use either?
View Replies
View Related
I am using a simple guestbook /portal and i want script to send mail to the thread owner when someone reply his message.
this is the send message code ....
View Replies
View Related
Can I define a function inside a function. e.g;
function abc()
function xyz()
....some code.....
End Function
End Function
I googled this but can't find any related topic.
View Replies
View Related
I want to use the instr function, but return results from it depending on surtain functions, I can't realy explain so I'll show my example:
I have a string in wich some word I want to find might be in diffrent Capital Letters order, I want the Instr function to return all the values of the place of that word (avcourse I'll run a for and increase the starting point of the Instr func until it returns 0). The instinct thought is to use the Lcase or the Ucase functions, but in this case I don't know how to use them. In the same Idea I wanted to use the Instr Func with the trim Func, But Its realy the same principle if I just understood how to do so.
View Replies
View Related
I am trying to call a function in asp to check to see if a varibale has a value stored in it if there is nothing wite the value NA into it. My code is
<%
Function NullValues(userField)
if userField = "" then userField = "NA"
end function
AccountNo = ""
Name = "sam clowes"
email = ""
AccountNo = (NullValues(AccountNo))
Name = (NullValues(Name))
email = (NullValues(email))
response.Write AccountNo & "<br>"
response.Write Name & "<br>"
response.Write email & "<br>"
%>
When I run this code ALL the variables are blank and nothing is output
View Replies
View Related
the function
<%
Dim objXML, objXSL
Function ShowXML(strXML,strStyleSheet)
Set objXML = CreateObject("MSXML.DOMDocument")
Set objXSL = CreateObject("MSXML.DOMDocument")
objXML.load(Server.MapPath(strXML))
objXSL.load(Server.MapPath(strStyleSheet))
Response.Write objXML.transformNode(objXSL)
Set objXML = Nothing
Set objXSL = Nothing
End Function
%>
calling the function in an asp file
<%Call ShowXML("http://msn.foxsports.com/feedout/syndicatedContent?categoryId=142","nhl/xsl/news/teamNews.xsl")%>
the errors
1. the http:// part
2. and the ? mark
the error message says that the path has been typed wrong.
View Replies
View Related
the user can key in variable A and B
then C is auto generated by C = A / B
so how and where should i write the C function??
View Replies
View Related
Possibly a very simple question but how do I get a value out of an XML document so I can play with it in ASP
E.G: <Name>Tom</Name
How do I pull the work tom into asp
View Replies
View Related
I am using the now() function to be displayed on an email after a form submission has been sent. The problem is that the server is not in the same timezone as I am for the result. How do I adjust the hours on the now() to allow for this please ?
View Replies
View Related
I know the basic difference between a subroutine and a function is a
subroutine performs a task and a function performs a task and returns a
value. The Call keyword is required when using parens with subs with more
than 1 parameters. Parens around values passed are ByVal vs ByRef and is a
waste of processing if passed ByRef for no reason.
I am told there is no reason to ever use a subroutine as a function can be
used even if it doesn't return a value. While this appears to be true, is
there any reason why it's ever a bad idea to use a function, instead of a
subroutine, that doesn't return a value? Are there memory, performance,
etc. issues?
View Replies
View Related
I am trying to locate information on how to call a sub within VBScript on an
ASP page but I can't locate generic information. What I want to do is
generate a page that will stay up but the information on it will change
based on a series of drop down boxes. I need the first drop down box to call
a second dropped down box based on the state that is chosen then city and so
on.
View Replies
View Related
I have a column in the table which contains 2 full names seperated by "&" (e.g: Joe Smith & Jeff Scott) I want to display only the first names of the whole record in an asp page. Is there an asp function using which i can do this?
View Replies
View Related
im using the mod function to create a calendar for me, which everything works perfectly, all is totally well with that!
but...when i use the mod function it churns out this loooooooooong string which is the whole table...
if there is some way that i can insert hard breaks IN THE CODE ITSELF.
View Replies
View Related
I used to be quite an experienced ASP programmer but I haven't used it for a while
I’m trying to do something that I remember as very simple I'm trying to check that the value of a form text box is numerical using the isNaN function. The code I am using is:
<%
quantity = Request.Form("number1")
if isNaN(quantity) = true then
Response.Write "Your input was not a number"
else
Response.Write "Your input was a number"
end if
%>
All I get is a NaN type mismatch error.
View Replies
View Related
Is there a function to check to see if a string contains a space
Thanks
View Replies
View Related
I was just wondering when using the mid function how does the assigment work when the length is longer then string itself? For example
test = mid(12345, 1, 10)
What would be the end result of test?Would it be 0000012345 or 1234500000 or 12345?
View Replies
View Related
When I create a single character string
var str = "A"
'convert to ascii
num = asc(str)
Response.Write num ' 65 shows up
'when I have a whole string
str = "hello"
str = mid(str, 1, 1) ' return 'h'
num = asc(str)
'I get an error:
Invalid procedure call or argument:'asc'What can be done to fix this?
View Replies
View Related
I've an array to store alphabets, in my code...in a random order. How can i use the Asc() function to get the equivalent Ascii of each alaphabaet of that array....
whenever i use ,
for i = 0 to NoOfElements
Response.write Asc("ArrayName(i)")
next
it displays 65, "NOOfElements" times (ascii of A)...on the other hand..i can't write
Response.write Asc(ArrayName(i))
since this shows some error...How can i solve this?
View Replies
View Related
Depending on some situations, I or the user, need to execute a function (e.g., login, sending email, etc...) and then continue from the original place. How can I make one function to be available from any page from my site?
View Replies
View Related
I have a problem with max() function. The SQL is as follow SELECT max(group_no) as group_no FROM doc_groups. if I run the sql in MS SQL server, it will return correct result. However when I run in ASP file, there is no record return. I check with RecordCount property and it return -1.
View Replies
View Related
Does anyone know how to use the Excel PV Function in an asp page? Is it possible at all? I know how to use it in .Net but not in ASP.
View Replies
View Related
i need to write sql statment to compeare the first three letters btween input user and a field in a database, i used the Mid function but it seems there is something wrong ..
dim str1
str1= Mid((Form1.SiteName.value), 0, 2)
<% strSQL = "SELECT EQUIPMENT_ID FROM ne.equipment_view WHERE Mid([EQUIPMENT_ID], 0, 2) = '&str1&'" %>
by the way i use dropdown list for user input ....
View Replies
View Related
I need function that will recognize URL in some string. For ex. somebody in forum sends some text which is in variable TEXT. I want a function to look at it and if it finds www... , http://... or https:// - he has to change it into url link.
View Replies
View Related
in vbscript:
Int(11.4)=11
What function in JScript like this function?
View Replies
View Related
I'm getting error in Dir$ after run this code using IIS. Can anyone help me to solve this matter? Code:
If (Mobile1.MSGType = 2) And (Dir$(Mobile1.MSGPictureName) <> "") Then
Image1.Picture = LoadPicture(Mobile1.MSGPictureName)
Else
Image1.Picture = LoadPicture()
End If ..
View Replies
View Related
is there a vb function that I can use to copy chars 1, 3, 5, and 7 from a string of 7 chars?
View Replies
View Related
Here's a tricky question for you all, is it possible to have a session or global function?
Page1.asp
<%
Function Hello()
Hello = "Good Bye"
End Function
Page = "Page2"
Server.Execute(Page & ".asp")
%>
Page2.asp
<%
Response.Write(Hello())
%>
However, When I run the pages, nothing is returned. Without using page includes, is it possilble to create some sort of global function?
View Replies
View Related