resource files
Does classic ASP have some notion of resource files, similar to JSP,
for use in internationalization/localization?
It should also support variable substitution too.
Thanks Tag: Manage .ASP Include-Files... Tag: 298559
Lots of Response.Writes of HTML - How do YOU do it?
I'm a newbie at ASP & HTML. It seems that when you use server side
code and you're going to return a customized HTML form with several
fields and labels, you have to do an extensive amount of
Response.Writes.
Are there any tools that will let you design the form then convert
that form to Response.Writes that you can further customize with ASP
logic? For instance: use Dreamweaver to design the form, then another
program to convert to response.writes in an aspx file.
What's the easy way of doing it? Just trying to make it less
laborious for me.
Response.Write "Thanks,"
tt Tag: Manage .ASP Include-Files... Tag: 298557
Execute an ASP and output into a string
Suppose there is a page at http://mysite.com/schedule.asp
Is there a way for me to write an ASP program which loads
http://mysite.com/schedule.asp into a string? That is, instead of
outputting directly to a browser, it outputs to a string?
So, the expected result of the string would be:
strScheduleASP = "<HTML><HEAD>........</BODY></HTML>"
Thanks. Tag: Manage .ASP Include-Files... Tag: 298555
Synchronize framed page output to browser?
I have an ASP page split up with three different frames. One of the frames
takes long time to load (due to long running function) and the first two are
loaded before the most important one - loaded about 5 seconds later.
Is there a way to synchronize the output so that the other frames wait for
the last one to load? Tag: Manage .ASP Include-Files... Tag: 298554
Error accessing the OLE registry error
Hi there,
I am getting a Error accessing the OLE registry when the system goes
hit the following line
set xWd = Server.CreateObject("Word.Application")
in my asp?
Anything I have to set-up in order to remove this error...
Please advice the steps that I should take...Thank in advance...Any
help would be greatly appreciated.
Wanda Tag: Manage .ASP Include-Files... Tag: 298548
ASP Pages 401.3 ACL Error
Server 2003 fresh install of IIS. Default iisstart.htm
page in root displays. Test hello.asp returns a 401.3
access error. Anyway to check basic ASP
functionality/reinstall ASP services in case this is
really the problem? Tag: Manage .ASP Include-Files... Tag: 298540
Why are "bookmarks" appearing in my querystrings?
On July 3, I started noticing some page errors in my web application. All
of the erroring clients where using Windows XP - MSIE 6.0. It seems these
clients were passing the bookmark (fragment identifier) portion of the URL
to the server.
For example, with the following URL:
http://testsite.com/page.aspx?myquery=test#bookmark
The browser *should* send a request for:
http://testsite.com/page.aspx?myquery=test
However, these clients were sending the entire URL as the request. Thus, my
querystring parameter "myquery" had the unexpected value of "test#bookmark".
Has anyone else noticed this behavior? Perhaps it is related to the
download.ject patch (released July 2). I have yet to recieve a response to
this message, which was posted one week ago in two other newsgroups.
Thanks,
Rob Tag: Manage .ASP Include-Files... Tag: 298539
sprintf for VBScript?
Hi,
I'm looking for the asp equivalent of PHP's sprintf/printf
function...In PHP you can do this:
$format = "There are %d monkeys in the %s";
printf($format,$num,$location);
This might output, "There are 5 monkeys in the tree".
You can also specify the order of the placeholders and repeat the
placeholders without adding more arguments in the code. Argument
swapping:
$format = "The %2\$s contains %1\$d monkeys. That's a nice %2\$s full
of %1\$d monkeys.";
printf($format, $num, $location);
Output, "The tree contains 5 monkeys. That's a nice tree full of 5
monkeys."
Any suggestions to acoomplish something similar with VBScript?
Thanks Tag: Manage .ASP Include-Files... Tag: 298536
web client disconnects from SQL Server - IIS timing out?
I am having a problem executing long running queries from an ASP application
which connects to SQL Server 2000. Basically, I have batches of queries that
are run using ADO in a loop written in VBScript. This works pretty well
until the execution time of a single query starts to exceed some threshold,
which I am trying to narrow down. I can typically run 2 - 10 queries in a
loop, with the run time being anywhere from under a minute to an hour or
more. Now that this application is being subjected to run against some large
databases (25 - 40G), I'm having problems getting the application to
continue beyond the first query if it takes a while to run.
I used SQL Profiler to try to diagnose what was going on. I can see the
query executes to completion, but immediately after completing I can see an
"Audit Logout" message, which apparently means that the client has
disconnected. The query durations vary from 45 or 50 minutes to up to over
90 minutes. I have the ADO connection and query timeouts set to very large
values, e.g. 1000 minutes, so I can't think its that. My guess is that there
is some IIS setting or timeout that I am running up against and the
connection to SQL Server is just dropped for some reason.
The configuration is
NT 4.0 SP6
SQL Server 2000 SP3
IIS 4.0
Explorer 5.5
I'm only running into this problem on the very largest databases we run
against. The vast majority continue to function properly, but this is going
to happen more often as time goes on the databases continue to grow in size.
Any advice is appreciated,
-Gary Tag: Manage .ASP Include-Files... Tag: 298535
Permission denied for copying file
Hi all,
I have a permission denied error when I tried to copy a file from the
local directory to another local directory by using the FSO
(FileSystem)
Set fso = createobject("scripting.fileSystemObject")
fso.CopyFile "c:\inet\wwwroot\webappname\template\aaa.doc",
"c:\inet\wwwroot\webappname\template\bbb.doc"
When I looked at the IIS setting, I have the IUSR_machinename got
setup, and have the write permission on, but I still have no idea why
I still got this error.
Please advice what else I have to know. Thanks in advance. Any help
would be appreicated.
Wanda Tag: Manage .ASP Include-Files... Tag: 298533
ASP Report to Word / PDF etc ??
I have created an ASP App that seems to be working well.
I can get the data out of the Access DB and displayed in screen fine.
But instead of sending it to the screen, is there any way I can create the
report and have it saved / outputted as a PDF or word Doc ?
Any links with examples ??
Thanks Tag: Manage .ASP Include-Files... Tag: 298531
Display Data Between Commas In Form ASP
I would like to know if you can display only certain data into a field
between commas or any other symbol without using the curshort feature.
For example. I have the following.
Part, A3472, Desc: Controller: Price$ 45.00
I just need this out of it in a single form field.
A3472
I cannot use the cutshort feature because my part numbers are
different lengths.
Thanks for any help in advance.
Thanks,
gil@ambry.com Tag: Manage .ASP Include-Files... Tag: 298529
Display Data Between Commas In Form ASP
I would like to know if you can display only certain data into a field
between commas or any other symbol without using the curshort feature.
For example. I have the following.
Part, A3472, Desc: Controller: Price$ 45.00
I just need this out of it in a single form field.
A3472
I cannot use the cutshort feature because my part numbers are
different lengths.
Thanks for any help in advance.
Thanks,
gil@ambry.com Tag: Manage .ASP Include-Files... Tag: 298528
ASP Vbscript Class Includes
Hi, I'm running into a problem with VBSCRIPT classes in ASP.
I use a seperate file for each class I use. Some of these class files
are included in multiple ASP scripts, but are also included in other
include files. So if you can't see the problem already, it is that
occasionally the class file will be included twice in the same script,
relsulting in the following error:
Microsoft VBScript compilation error '800a0411'
Name redefined
/includes/classes/closableobjectlist.asp, line 2
Class ClosableObjectList
------^
Does anyone know a clean solution for this problem?
Right now I am just having to be really careful with my includes, but
if there was a way I could protect against this, I believe it would be
a much more user friendly solution.
Thank You
Mike Biang
Senior Web Application Developer
Cramer Development Tag: Manage .ASP Include-Files... Tag: 298521
CDONTS on WINDOWS 2003 Server
Hi
Some one has posted this question on 10th August, as CDONTS is not working
on windows 2003 serever. I have the same problem and I copied CDONTS.DLL
from Windows 2000 Server and registered on Win 2003 server but it giving the
error on line when I calling method send of the object.
Error is
Microsoft VBScript runtime error '800a0046'
Permission denied
I tried to register CDONTS as COM+ with Admin user right to execute but it
still giving same error.
Any Advise
Regards Tag: Manage .ASP Include-Files... Tag: 298519
JS Problem
I'm having a problem with JavaScript and ASP that need to be intermixed.
I'm querying a database, and creating JavaScript arrays for use on the
client side...which works fine. Basically I have two drop down lists, and
when you select an item in the first drop down, the items in the second one
change. The functionality there is no problem.
My problem lies in the fact that I'm embedding ASP code within a javascript
function, and it's causing my form to post every time I try to do validation
or some other client side function. Is there a simple way around this?
Thanks,
James Tag: Manage .ASP Include-Files... Tag: 298507
multiple db connections-your advice needed
On my website, I want to provide 3 pieces of statistics that will
require 3 queries to my SQL database. As much as I'd like these to be
live, they are part of a footer that will load each time for about 10
pages on my site. I am thinking that, although they are simple queries,
it may be just too much.
What do you recommend?
I could open the connection, run the query and then close it, each time.
Would this be a recommend plan?
Or, should I create a daily task that builds a simple text file with
those query results and just pull those in each time the footer is
loaded? This would not be live, but I can deal with it.
What do you all think?
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it! Tag: Manage .ASP Include-Files... Tag: 298501
Non friendly error messages
I have a little gripe with my ASP pages, for some reason I am not getting
error messages I would expect and don't know if it's an ASP thing, browser
thing or IIS problem.
I use option explicit to ensure I define every variable.
When I have forgotten to define one the error page just dislays the 500.100
error screen.
I have ensured that in my IE 6 that 'show friendly http error messages' is
unchecked but have the problem still.
I would have expected it to display some output and then state the error
later in the page.
How can I achieve this as I am totally stumped now. :o/
Thx
Stu Tag: Manage .ASP Include-Files... Tag: 298500
Example code
Hi all. First of all, I am totally new to ASP! I want to create a
webpage that a user can fill in and then press submit. Upon pressing
submit, the server will create an email and then mail me the contents
of the form. I would also like the webpage to automatically get
someones Windows 2000 user id and include that in the email.
I have been googling around and have not been able to find any example
scripts for what I need. So, I am wondering if anyone would be kind
enough to post one.....?
Thanks! Tag: Manage .ASP Include-Files... Tag: 298498
How to access variables (form text box values) on same form?
Hello Asp Programmers,
I have a question. I have a form on an ASP page that has 5 text boxes, for
data
entry. I am trying to get data from the text box, and pass it to a hidden
text box on the form.
The hidden text box is called "MyDateTime" (a SQL date and time value).
I am attempting to concatenate data from two other textboxes (one for date
and one for time) to give a string like : "8/8/2004 8:00 AM"
I am trying to use the following:
<% Dim time
Dim date
Dim dateAndTime
time = Request.Form("usertime")
date = Request.Form("userdate")
dateAndTime = FormatDateTime(time & " " & date,vbGeneralDate)
in the html for MyDateTime hidden field i use this: value=
"<%=dateAndTime%>
for some reason the time and date fields, do not have data in them (although
typed on form)
I want to use data typed in the text boxes including the dateAndTime value
and insert those values in a database.
What am I not doing here??
Thanks for your help (previous posts answered and provided fixes for me)
eric Tag: Manage .ASP Include-Files... Tag: 298497
Page Expires - even on Back button?
Hi All!
At the moment, I have this in the footer section of my login protected
pages:
<%Response.Expires=-1%>
But I notice this doesn't prevent me from being able to press 'Back' after I
have logged out and view the same content - content I should not view if I
have logged out! How do I force the page to expire then?
Any advice would be most welcome!
Rob
:) Tag: Manage .ASP Include-Files... Tag: 298495
ASP CDO Problems
Hey All, I have MDaemon running locally on the server, and that is
what I want to send mail through. It's a normal mail server which
doesn't require an access list, I just have a list of trusted IP's to
accept mail from.
This is the code I use on my ASP page
<%
'Send email using CDO.
Public Function sendEMail( fromAddress, toAddress, subject, body )
Dim outgoingSMTPServer, smtpUserID, smtpPassword
Dim objMail
'Trim all the parameter values.
fromAddress = Trim( fromAddress )
toAddress = Trim( toAddress )
subject = Trim( subject )
outgoingSMTPServer = ""
smtpUserID = ""
smtpPassword = ""
'outgoingSMTPServer = Application( "OutgoingSMTPServer" )
'smtpUserID = Application( "SMTPUserID" )
'smtpPassword = Application( "SMTPPassword" )
'Correct COX SMTP address.
outgoingSMTPServer = "127.0.0.1"
'Make sure that we have from, to address and body.
If fromAddress = "" Or toAddress = "" Or body = "" Then
sendEMail = False
Exit Function
End If
'Create the object.
Set objMail = Server.CreateObject( "CDO.Message" )
objMail.From = fromAddress
objMail.To = toAddress
objMail.Subject = subject
objMail.HTMLBody = body
'Send using the specified SMTP server.
objMail.Configuration.Fields.Item _
( "http://schemas.microsoft.com/cdo/configuration/sendusing" ) =
2
'Name of the smtp server name.
objMail.Configuration.Fields.Item _
( "http://schemas.microsoft.com/cdo/configuration/smtpserver" )
= "localhost"
'Default port.
objMail.Configuration.Fields.Item _
( "http://schemas.microsoft.com/cdo/configuration/smtpserverport"
) = 25
'Set the user ID and password if available.
If smtpUserID <> "" And smtpPassword <> "" Then
objMail.Configuration.Fields.Item _
( "http://schemas.microsoft.com/cdo/configuration/smtpauthenticate"
) = 1
'Your UserID on the SMTP server
objMail.Configuration.Fields.Item _
( "http://schemas.microsoft.com/cdo/configuration/sendusername"
) = smtpUserID
'Your password on the SMTP server
objMail.Configuration.Fields.Item _
( "http://schemas.microsoft.com/cdo/configuration/sendpassword"
) = smtpPassword
objMail.Configuration.Fields.Item _
( "http://schemas.microsoft.com/cdo/configuration/smtpusessl"
) = False
objMail.Configuration.Fields.Item _
( "http://schemas.microsoft.com/cdo/configuration/smtpconnectiontimeout"
) = 60
End If
'Update the configuration.
Call objMail.Configuration.Fields.Update()
'Send the message
Call objMail.Send()
'Release the object.
Set objMail = Nothing
sendEMail = True
Exit Function
End Function
%>
That function is in it's own asp page. I just include it when
necessary.
when I call the function and pass it the appropriate parameters, it
seems to go through without erroring, but of course I never get the
email, and the MDaemon logs dont even show an attempted connection.
Any ideas? Tag: Manage .ASP Include-Files... Tag: 298494
Web Publish behind ISA
I have been assigned a perm IP address for my registered domain along with a
gateway and two dns addresses. I am using one W2003 Server for domain
controller and ISA. My local address is 192.xxx.xxx.xxx
Q1:what do I put in the Lat for internal addresses?
Q2: Does mydomain.com go into the LDT?
Q3:More to come......
--
Generations Ranch Tag: Manage .ASP Include-Files... Tag: 298493
IIS 5.0 Config for Asp hosting trouble
Hi
I am having some trouble getting a asp page to load. Im a
noob to the asp side. I have followed knowledege base
Article 301305. I am running 2000 adv, IIS 5.0
I have the following settings to the folder that has the
asp.
Application settings
application name: upload
Starting poing: <website>\upload
Execute Permissions: Scripts Only
App Protection: High(isolated)
Is there anything else i need to do? I installed the
lockdown awhile back...does that interfere?
Thanks,
James Tag: Manage .ASP Include-Files... Tag: 298484
Managing a Database using Word / IIS
I have a fairly ambitious client who would like to offload the management of
intranet content to other individuals in the organization. For the project
to be successful, the data management must be as painless as possible.
Accordingly, the ideal interface for data input is Microsoft Word, as most
users are extremely comfortable working with it.
I would like to be able to create word templates/forms which are dynamically
populated with data from an database, then downloaded to the client PC. Once
the data is updated, I would like the user to upload their files back to the
server, which will in turn update its database and maintain an audit-trail of
all changes.
Can this be done? I'm assuming that if I install Office on the server, it
would be feasible using the office API, but I would love to be able to do
this without office on the server..
any hints / suggestions would be HUGELY appreciated!
Thanks,
Aaron Tag: Manage .ASP Include-Files... Tag: 298479
Urls messy - extra characters not expected?
After peforming a basic redirect with two query string parameters I load the
page successfully...however the url does not look pretty...can anyone tell
me why these percentage signs and extra symbols are showing up:
http://69.2.200.70/dev/1/doc3.asp?vID=12&u_FromURL=http://69.2.200.70/dev/1/link.asp&bhjs=1&bhrf=http%3A%2F%2F69%2E2%2E200%2E70%2Fdev%2F1%2Flogon%2Easp%3FCookieChk%3DDisabled%26u%5FFromURL%3Dhttp%3A%2F%2F69%2E2%2E200%2E70%2Fdev%2F1%2Flink%2Easp%26u%5FCurrentURL%3D%2Fdev%2F1%2Fdoc3%2Easp&bhqs=1
Is this related to UNENCODE or something along these lines...? I know
percentage symbols traditionally stand for 'spaces' but this seems
different....
Thanks
Jason Tag: Manage .ASP Include-Files... Tag: 298469
ASP Web Application Timeout
Greetings,
I have an ASP web application that is written in VBScript, uses MS Access
2000 for record storage, and is running on a Windows 2000 Professional SP4
computer with IIS 5. The application can be started, have a record updated
and stored, and then terminate successfully on demand. I would like to have
the application remain active on the IIS Server without timing out, but when
I attempt to run it in that way, I receive a message (usually first thing in
the morning) of "An Eror Occurred - Your Session Timed Out". I have set the
Session Timeout feature in IIS to 1440 minutes, and the Server Script Timeout
feature in IIS to 1000000 seconds, but the application still times out each
morning.
Can anyone tell me what else I need to do to keep this application available
all day and all night?
Thanks!
MrLr Tag: Manage .ASP Include-Files... Tag: 298468
localization and ASP
Hi,
I have a simple 'user' table (SQL Server 2000) and an ASP form that
connects to it. I want users of all languages to be able to type in
their registration info, in their own language (chinese, german,
etc..), store it that way, then have another page that displays it.
Is there anything specific I need to do with ASP (classic, not .NET),
to handle this?
Thanks Tag: Manage .ASP Include-Files... Tag: 298464
Out of memory error message.
I get the following error message from an ASP page that we have:
METHOD: POST
ERROR DESCRIPTION: 007~ASP 0100~Out of memory~Unable to allocate required
memory.
ERROR NUMBER: -2147024882
ERROR SOURCE: Response object
Does anyone out there have any ideas? Please let me know if you need any
more information ... I am not sure why this message has suddenly started to
pop up.
I checked the system logs and cannot see any particular memory loss related
message so I don't know.
TIA,
Rohan Tag: Manage .ASP Include-Files... Tag: 298463
How can I test to see whether a particular object variable is defined?
Hi Gang,
I want to test and find out whether or not a particular variable object has
been defined. I need to know whether or not a recordset has already been
defined in the current script. However, my script crashes even though I've
disabled error handling, which doesn't make a whole lot of sense to me, but
anyways :). Here's my code:
---------------------------------------------------
on Error Resume Next
If objRS.Fields.GetCount > 1 Then
RestartRecordSet()
Else
OpenConnection()
End If
On Error Goto 0
-----------------------------------------------------
Is there some command like If isdef(objRS) then... or something to that
effect? Also is .GetCount the correct command? I think it is, but MSDN
help has a special way of giving too much information.
Thanks in advance,
Christian Blackburn Tag: Manage .ASP Include-Files... Tag: 298448
Source Control for Web Projects
What are people using for source control for ASP and HTML files? We have a
typical scenario here, a handful of developers working locally on
development, an internal staging server, then an external-facing production
web server, all Windows 2003. I'm quite familiar with Visual Sourcesafe, but
it doesn't easily allow (to my knowledge, anyway) to move ad-hoc files
through to production to fix high severity bugs on the fly. It requires
project labeling or "pinning" other files that have been checked-in but
aren't ready for prime time.
Other solutions?
thx
Jeff Tag: Manage .ASP Include-Files... Tag: 298447
Converting hrs and min to just min
I am using two fields on a form to capture time someboby is working. The
fields are hours and minutes. How can I when submitting to the db take both
fields and convert them to a single field in the db as minutes?
Thanks
Carmen Tag: Manage .ASP Include-Files... Tag: 298444
Where do I go wrong when using URLencode?
<A href= "GenericUploader.asp?SavePath=<%=server.URLEncode("D:\my new
web site\U") %>">folder name</A>
the link above does not seem to produce the appropriate query string
value upon being clicked on. That is, when an internet user clicks on
that link, the Internet Explorer opens the GenericUploader.asp web
page, and the code in that asp web page responsible for picking up the
value corresponding to the argument 'SavePath' (i.e,
request.querystring("SavePath")) returns solely the first word of the
value rather than the entire CORERECT value, which is 'D:\my'rather
than 'D:\my new web site\U'.
Can anyone tell me what needs to be done?
Thank you in advance
Avi Tag: Manage .ASP Include-Files... Tag: 298441
Error "cannot update database or object is read-only" when updating MDB file in ASP
I have IIS installed on XP Professional workstation machine. I have an ASP
page that open connection to an Access database, then when trying to update
the database, it gave me the error "cannot update database or object is
read-only". This is a workstation machine, not connected to any other
computer, and I login to the PC using an administrator account. I already
check the .MDB file is NOT read-only. But, I do not see the .LDB file.
Manually, I can update the .MDB file, and I can create a new file on the
directory where the MDB file is. The directory where the MDB is located says
"read only", then I uncheck the read only, click apply and OK. When I go
back to the property of the directory, it went back to "read only". This
seems to happen on any XP machine. But, I can still manually create a new
file, delete a file, rename a file on this directory.
The MDB file used to have a password, when it did, I got the error on the
statement
sds("SECURITY_EXTRA1") = sExtra
When I got rid of the password, I got the error on the statement
sds.update
How can I fix this problem ? Thank you.
Here are my codes:
Set dbConnection = Server.CreateObject("ADODB.Connection")
session("CustomersDB_ConnectionString") = "dsnName"
Session("CustomersDB_RuntimeUserName") = "userId"
Session("CustomersDB_RuntimePassword") = "passw"
dbConnection.Open Session("CustomersDB_ConnectionString"),
Session("CustomersDB_RuntimeUserName"),
Session("CustomersDB_RuntimePassword")
Set sds = Server.CreateObject("ADODB.Recordset")
sds.ActiveConnection = dbConnection
sds.CursorType = adOpenKeyset
sds.LockType = adLockOptimistic
sds.Source = "select SECURITY_ID,SECURITY_EXTRA from SECURITY where
SECURITY_USERID = 'abc'"
sds.Open
sds("SECURITY_EXTRA1") = sExtra
sds.update Tag: Manage .ASP Include-Files... Tag: 298438
upload sql files from IIS to sql
We have clients upload sql files to a folder on an IIS 6.0. The sql
file are then processed by a scheduled task that runs once every
10mins to process the file with oSQL. With oSQL the files upload the
data to a 2 tier SQL server. The developers are complaining about
performance and are saying it is the OS/hardware. I have Profmon on
the IIS server and 2 tier SQL server. Both only peak at %5 usage on
processor memory stays close to the same.
I believe that it would better to have IIS make a connection to the
SQL server and upload the record directly.
What do you think?
and any examples would be nice or URL that talks about how to do this.
Thanks for you ideas and help!! Tag: Manage .ASP Include-Files... Tag: 298434
Using special characters within a string
Hi
Doing my best to understand why I cant insert a vbcrlf or an equivalent into
this piece of code that read messages from an SQL DB. The messages it takes
read into a marquee fine but I want the Marquee to scroll up instead of
horizontally and I need new line spacings else the mesages are difficult to
read.
At present we use the strNewTextDelimitor and I am unable due to syntax or
perhaps idioscy to find a way of adding the VBCRLF or any derivative into
this code so......I am sure its simple but could do with a hand...Tx in
advance.
This outout is pumped to a page back to a page which will not pick up the
new messages if I use any of the following characters (even without placing
them into a variable) vbcrlf vbcr vblf chr(13) chr(10).
Do While Not adoRecordset.EOF
' Add the current message in the recordset to the string that is
returned
strNewText = strNewText & strNewTextDelimiter &
Trim(adoRecordset.Fields("Message").Value & "")
' Set the delimiter ready for the next message.
strNewTextDelimiter = " * * "
' Get the next message from the recordset
adoRecordset.MoveNext
Loop
The code above works fine but the moment I attempt to add the special
characters the scripts do not run and the web page will not update :-( ,
Tis driving me crackers!
Cheers, Tag: Manage .ASP Include-Files... Tag: 298428
Centrilized Data Connection
Hi,
I have several ASP pages, and some of them are using the same access
Database and table.
Can I put the connection string somewhere centralized, so I can link to it ?
Thx in advance
TNGgroup Tag: Manage .ASP Include-Files... Tag: 298419
Put a Timer on the web form
Hi,
I'm new to ASP.NET. I have an WebForm1 which contained a ListBox1. I have
drag a Timer on the form. In the timer1_Elapsed() function , I have add the
line ListBox1.Items.Add("haha"). But when the timer elapsed, it called that
line of code, but the ListBox1 didn't show "haha".
Would you tell me what I have missed?
I'm using C#/ASP.NET
Best regards,
C Learner Tag: Manage .ASP Include-Files... Tag: 298418
asp with radio buttons on forms
Hello all...
I have a page that will be performing a search. The search consists of 3
radio button options. The first 2 will search the entire web through google
and the site as indexed by google. The 3rd option I want to search the site
using MS-Index Server. I can get them to run individually but I'm not sure
how to set the parameters and test for the 3rd radio button (index server)
selected on the page.
I thought that, for example, my Searchinc.asp could have an
If...then...else:
<form action="../gw/incl.idq" method="GET">
<td valign="bottom" align="right" width="100%">
<input type="HIDDEN" name="CiScope" value="/geo_portal/gw">
<input type="HIDDEN" name="CiMaxRecordsPerPage" value="10">
<input type="HIDDEN" name="TemplateName" value="incl">
<input type="HIDDEN" name="CiSort" value="rank[d]">
<input type="HIDDEN" name="HTMLQueryForm" value="../gw/incl.asp">
</td>
<td width="1">
</form>
<%else%>
<!-- SiteSearch Google -->
<form method="get" action="http://www.google.com/custom"
target="google_window">
<%end if%>
<table width="770" height="32" border="0" align="center" cellpadding="0"
cellspacing="0" bgcolor="#FFFFFF">
<tr class="geoTopLinks"><td width="99" height="32" align="left"
valign="top" nowrap="nowrap">
<a href="http://www.google.com/">
<img SRC="http://www.google.com/logos/Logo_25wht.gif" alt="Google"
height="32" border="0"></img></a>
</td>
<td nowrap>
<input type="hidden" name="domains" value="www.site.com"></input>
<input type="text" name="q" size="15" maxlength="255" value=""></input>
<input type="submit" name="sa" value="Search">
</input> </td>
<td width="342" height="32" nowrap><font size="-1" color="#000000">
<input type="radio" name="sitesearch" value="">
<span class="Verd10pt">Web
<input type="radio" name="sitesearch" value="sitename">
GeoPlace
<input type="radio" name="sitesearch" value="geoworld" checked>
GeoWorld
</span></font><br>
<input type="hidden" name="client" value="pub">
</input>
<input type="hidden" name="forid" value="1">
</input>
<input type="hidden" name="channel" value="a number">
</input>
<input type="hidden" name="ie" value="ISO-8859-1">
</input>
<input type="hidden" name="oe" value="ISO-8859-1">
</input>
<input type="hidden" name="safe" value="active">
</input>
<input type="hidden" name="cof" value="big number">
</input>
<input type="hidden" name="hl" value="en">
</input>
</td>
<td width="133" nowrap>
The google part works just fine, I can't seem to get the index server piece
to work....
Can anyone give me any suggestions?
Thanks in advance...
Brian Tag: Manage .ASP Include-Files... Tag: 298394
how do i allow access to a shared folder?
how can i allow access to a shared network folder? i am trying to give
access to my as pages only. i don't want just anyone to type in the path of
my files. i can't seem to do this with a shared folder.
--
5khzgjf9e001@sneakemail.com Tag: Manage .ASP Include-Files... Tag: 298392
using ASP and parametized query
Per a previous suggestion, I'm trying to use a parametized query in Access
2002. The query functions properly in Access. Now I'm trying to call it from
ASP. I'm using code I found at
http://www.xefteri.com/articles/apr302002/default.aspx and trying to adjust
for my needs. I'm getting this error. The query is there and functioning. It
appears that I'm not connecting. Can I get some more insight?
thanks!
------------------------------
Microsoft VBScript runtime (0x800A01A8)
Object required: 'qry_FindSongs 'White'
------------------------------
My connection string is
------------------------------
Dim conn, mdb, mdw, MM_GenKAccess_STRING
set conn = CreateObject("ADODB.Connection")
conn.Mode=adModeRead
mdb = Server.MapPath("songs.mdb")
mdw = Server.MapPath("system.mdw")
MM_GenKAccess_STRING = "Provider=Microsoft.Jet.OLEDB.4.0; " & _
"Data Source=" & mdb & ";" & _
"Jet OLEDB:Database Password=xyz;" & _
"Jet OLEDB:System database=" & mdw
conn.open MM_GenKAccess_STRING
------------------------------
<% OPTION EXPLICIT %>
<%
Dim T
T = "%"
If (Request("title") <> "") Then
T = Request("title")
End If
%>
<%
Dim A
A = "%"
If (Request("artist") <> "") Then
A = Request("artist")
End If
%>
<%
Dim C
C = "%"
If (Request("category") <> "") Then
C = Request("category")
End If
%>
<%
Dim TY
TY = "%"
If (Request("type") <> "") Then
TY = Request("type")
End If
%>
<%
Dim M
M = "%"
If (Request("manuf") <> "") Then
M = Request("manuf")
End If
%>
<%
Dim SA
SA = "%"
If (Request("singleartist") <> "") Then
SA = Request("singleartist")
End If
%>
<%
Dim rsResults
Set rsResults = Server.CreateObject("ADODB.Recordset")
rsResults.ActiveConnection = MM_GenKAccess_STRING
rsResults = "qry_FindSongs '" & T & "', '" & A & "', '" & C & "', '" & TY &
"', '" & M & "', '" & SA & "'"
rsResults.Open rsResults, 0, 4
%> Tag: Manage .ASP Include-Files... Tag: 298391
asptxn.dll in Windows 2000 but not in Windows 2003
Hello All
This might just be my ignoranace.
---------------------------
The asptxn.dll exists on my Windows 2000 box:
C:\WINNT\system32\inetsrv>dir asptxn.dll
Volume in drive C has no label.
Volume Serial Number is 5839-8874
Directory of C:\WINNT\system32\inetsrv
06/19/2003 01:05p 30,480 asptxn.dll
2 File(s) 369,184 bytes
0 Dir(s) 264,912,896 bytes free
--------------------------
However, on my Windows 2003 box:
C:\WINNT\system32\inetsrv>dir asptxn.dll
Volume in drive C has no label.
Volume Serial Number is 7CFC-DDD5
Directory of C:\WINNT\system32\inetsrv
File Not Found
Does anyone know if
(a) I missed an installation step
(b) If there is a replacement for asptxn.dll that I should be using
(c) If there is another location that I should search for this dll.
Actually, I searched the whole filesystem and didnt find anywhere.
Any help would be appreciated. Please respond to this post.
Thanks
-R Tag: Manage .ASP Include-Files... Tag: 298389
http_referer empty? Firewalls?
Can one reliably use http_referer to track a user page selections as I
appear to be getting BLANK values?
I have read that company firewalls etc block this method....
Thanks
jason Tag: Manage .ASP Include-Files... Tag: 298376
Converting 25062002120236 to a date!
How can I convert a string such as 25062002120236 into a date
(25-06-2002 12:02:36). I have tried using the CDate() & ISDate()
functions but they don't recognise and convert this into a date.
Thanks in advance,
Quintus Tag: Manage .ASP Include-Files... Tag: 298373
Cookies being reset or disappearing mysteriously
My website uses cookies to persist a certain amount of data on the
client. However, occasionally the cookies will disappear or be set to
an empty string for no discernable reason. It does not happen in our
development environment at all, but does happen in our production
environment. We looked at all the likely settings and they were
identical on both the production and live servers.
We set the cookie domain properly and the cookie path.
Has anyone seen similar behavior? And if so, what did you do about it?
What IIS settings should I be looking at? Could it be a service pack
that was installed on one machine but not another? Any ideas, thoughts
or advice would be appreciated.
Thanks for any help!
Richard Tag: Manage .ASP Include-Files... Tag: 298370
Script to format existing Access table into wall calendar format?
I have the tables set up in Access, viewing in column format on ASP
pages but now the company wants the schedule reports to be in a
wall-calendar type format. I've searched and found calendar scripts
but I need one that's creates a table resizable to a report size
format. Using the existing MS Access db I've written is also a plus.
Any suggestions on where to start?
TIA!
Lisa Tag: Manage .ASP Include-Files... Tag: 298369
HTMLBody and variable
Hi everybody,
It seems that a variable cannot be assign to HTMLBody field. Am'I doing
something wrong?
- this line write a bold html phrase in the email body
.HTMLBody = "<HTML><HEAD><BODY><B>Here is the text body</BODY></HTML>"
- this line produce an empty body. The variable TableData contains all
the required HTML to construct the table. I Use Response.Write and see
all the code in it..
.HTMLBody = "<HTML><HEAD><BODY>" & TableData & "</BODY></HTML>"
thanks in advance Tag: Manage .ASP Include-Files... Tag: 298364
ASP object required error - vbscript
Dear Group
I am trying to use the following code to refer to a form and control on my
form. I am supposed to be using VBSCRIPT for this code.
I always get an "object required: 'document' " error:
<%
Dim Myform
Set Myform = document.forms.thisform
Myform.textbox1.value = "fish" %>
None of this code will work. Always get an error.
Using Visual Interdev, plain ole ASP, and vbscript, and Win XP Pro with IIS
5.1
What am I missing or doing wrong???
Thanks
eric Tag: Manage .ASP Include-Files... Tag: 298353