|
Use both. Browsers that don't understand a css property are supposed to ignore that one, so cursor: hand; cursor: pointer; will do the trick.
|
|
|
|
|
thanks... it is a nice tip
|
|
|
|
|
Hello,
I 'm trying to run a program from within an asp page, wzzip (WinZip's command line add on). If I run "c:\program files\winzip\wzzip.exe" -r -p -e0 c:\inetpub\wwwroot\temp\temp4.zip c:\inetpub\wwwroot\temp\*.txt, from a batch file, it works fine, the zip file is created. I figure out I had to put the quotes around the path to the .exe or I get an error that c:\program is not a valid command.
But running the following from an ASP page (VB Script), the code runs, but no file is created. If I use line 3, which is all that is in the batch file "zipem.bat", I get an rror code related to a file not found. If I use that in a .vbs file, I get the file not found error, plus it shows the batch file name as the culprit, but I am not even referencing it!! Using line 4, the ASP script runs, but no zip file is created.
Can you help? Am I even doing this right?
1) Dim wshShell
2) set WshShell = Server.CreateObject("wscript.shell")
3) 'WshShell.Run """c:\program files\winzip\wzzip.exe"" -r -p -e0 c:\inetpub\wwwroot\temp\temp4.zip c:\inetpub\wwwroot\temp\*.txt"
4) WshShell.Run "c:\inetpub\wwwroot\temp\zipem.bat"
5) Set wshShell=Nothing
Kraig
Kraig Schuneman
|
|
|
|
|
About every 2 or 3 months, our Intranet comes across the following error on the Intranet Home Page:
Microsoft OLE DB Provider for ODBC Drivers error '8007000e' <br />
<br />
[Microsoft][ODBC Microsoft Access Driver] System resource exceeded. <br />
<br />
/index.asp, line 25
Our Intranet uses an MS Access DB to display news items on the Home Page. This error occurs when trying to query the database for the latest news items.
This problem can be fixed by rebooting the server. Does anyone know what could be causing this?
Chris LaQuerre
eBusiness Consultant
|
|
|
|
|
This is caused from too many connections at the same time.
A workaround might be to use the OLEDB driver:
"yourConnectionName.Open "Provider=Microsoft.Jet.OLEDB.4.0;" &_<br />
<br />
"Data Source=E:\foldername\databasename.mdb;" &_<br />
<br />
"Persist Security Info=false"
But I would look into U/G to SQL Server. As a rule MS Access will allow 10 concurrent connections to the DB, sometimes it will throw an error, and sometimes not.
Also be sure that you are closing your connection within your code:
yourConnectionName.Close<br />
<br />
Set yourConnectionName = Nothing
HTH
Tony
|
|
|
|
|
I'm new to using the IE control (MSHTML) and am not sure how to do something. I know it should be possible. Here it is:
If I have an object embedded in an HTML page and I display that page within the IE control, how do I get it programmatically? It has an ID and all of that.
<br />
<!-- DHTML Editing control Object. This will be the body object for the toolbars. --><br />
<object ID="tbContentElement" CLASS="tbContentElement" CLASSID="clsid:2D360201-FFF5-11D1-8D03-00A0C959BC0A" VIEWASTEXT><br />
<param name=Scrollbars value=true><br />
</object><br />
How do I get programmatic access to the tbContentElement object?
Any help, tips, or pointers to articles or whatever are/will be greatly appreciated.
Thanks,
Mike
|
|
|
|
|
You must use IHTMLDocument2 interface. You can find some help on msdn.microsoft.com :
http://msdn.microsoft.com/library/default.asp?url=/workshop/browser/mshtml/reference/reference.asp
example of function to retrieve the value of a tag in a html page :
CString YourApp::GetTagValue(LPDISPATCH lpDispatch, CString strTagId)
{
CString strVal = "";
IHTMLDocument2* pHTMLDocument2 = NULL;
if (lpDispatch == NULL)
return "";
HRESULT hr = lpDispatch->QueryInterface(IID_IHTMLDocument2, (LPVOID*)&pHTMLDocument2);
lpDispatch->Release();
if (hr != S_OK)
return "";
IHTMLElementCollection *pElementCollection = NULL;
hr = pHTMLDocument2->get_all(&pElementCollection);
if (hr != S_OK || pElementCollection == NULL)
return "";
long nElt = 0;
if (pElementCollection->get_length(&nElt) != S_OK)
return "";
for (int i=0; i<nelt; i++)
="" {
="" variant="" varindex,="" var2;
="" varindex.vt="VT_UINT;
" varindex.lval="i;
" variantinit(&var2);
=""
="" idispatch*="" pdisp="NULL;
" hr="pElementCollection-">item(varIndex, var2, &pDisp);
if (hr == S_OK && pDisp != NULL)
{
IHTMLElement* pElem = NULL;
hr = pDisp->QueryInterface(IID_IHTMLElement, (void**)&pElem);
if (hr == S_OK && pElem != NULL)
{
BSTR bstrId = 0, bstrVal = 0;
hr = pElem->get_id(&bstrId);
CString strId(bstrId);
strId.MakeLower();
// Oups, we find our tag !!!
if (strId.Find(strTagId) != -1 && strId != "")
{
// Retrieve all html code
pElem->get_innerHTML(&bstrVal);
strVal = CString(bstrVal);
}
pElem->Release();
}
pDisp->Release();
}
}
pElementCollection->Release();
return strVal;
}
you can use this function like this:
CString strValue = GetTagValue(m_web.GetDocument(), "myid");
With a object embedded in a html page, I think you must use the IHTMLObjectElement interface instead of the IHTMLElement interface.
This is not easy to play with the syntax of theses interfaces, but it works.... Good luck !!!
|
|
|
|
|
Thanks! This will get me started.
|
|
|
|
|
I have a client that needs to do Powerpoint presentations from his web site.
Does anyone know of any example of this using ASP.NET (C# or VB.NET).
Thanks
Tony
|
|
|
|
|
Why not just put the ppt file out on the web site and add a link to this file? It will download the ppt and open Powerpoint (or viewer) to display the presentation.
onwards and upwards...
|
|
|
|
|
|
on my first page i want to get a name and asign it to a variable:
exsample.....
please enter your name here .......
on submit we will go to next webpage
on the next page i want the name to be seen again,
exsample.....
this is where your name ...... could have apeared, if you would have filled it out on page one.
is there a way that java gets the name, assigns it to a variable
and than later use that variable to print the name again?
i have searched and searched tried many things but cant find it, i am totaly new to programming so if you know anything to help me out i will be thankfull
|
|
|
|
|
There's an example of this using cookies & JavaScript here on the JavaScript Source site.
|
|
|
|
|
Check out "PocketPrep" from handango.com.
It has 90 questions based on the test spec. (070-316 and 070-306)
|
|
|
|
|
A tip: get out your flameproof suit
Paul
I have been afraid always. When you see something insurmountable ahead of you, say to yourself: "All right! I am afraid. Now that I've been properly afraid, let's go forward." That is the whole secret. - Jeanne d'Arc
modified 18-Jul-18 11:59am.
|
|
|
|
|
Paul van der Walt wrote:
A tip: get out your flameproof suit
Some ppl just don't understand that "web dev" doesn't = arb test exams from MS that don't mean anything anyway.
Cheers,
Simon
"Don't try to be like Jackie. There is only one Jackie.... Study computers instead.", Jackie Chan on career choices.
animation mechanics in SVG (my first abstract photo)
|
|
|
|
|
hmmm....
Interesting....
Not a question or a suggestion....
Not an article proposal....
Not Web Developlment related....
hmmm.... what else?....
trying to advertise something here maybe.??....
Cmon CPians help me here....
Is this in anyway related to THIS SPECIFIC Message board?
Is there something that I didnt get?
WHICH PART OF
"Discussions on ASP / HTML/ DHTML / Javascript etc"
DIDNT HE UNDERSTAND ??...
...HMMM I REALLY WONDER!!...
|---------------|
| theJazzyBrain |
|---------------|
|
|
|
|
|
If use .
The problem is, I would like to know what the selection is BEFORE the drop down was dropped. anyone know if or how I can do this please?
Basically I would like ing="dosomething">.
I feel like I'm diagonally parked in a parallel universe
Jeremy Davis
http://www.astad.org http://www.jvf.co.uk
|
|
|
|
|
You can always create a property on the select to store the previous value and update it in your onchange handler. EX:
<script language=javascript><br />
<br />
function OnSelectChange() {<br />
var oElem = window.event.srcElement;<br />
var cOrigValue = oElem.LastValue;<br />
var cCurrValue = oElem.value;<br />
<br />
.. do whatever here...<br />
<br />
oElem.LastValue = cCurrValue;<br />
}<br />
<br />
</script><br />
<br />
<select name="MyDropdown" LastValue="" onchange="OnSelectChange()"><br />
<option value="red">Red</option><br />
<option value="white">White</option><br />
<option value="blue">Blue</option><br />
</select>
onwards and upwards...
|
|
|
|
|
|
Not sure about Netscape. We stopped developing for Netscape about 4 years ago. It is a HORRIBLE platform to develop real, functional business apps for.
onwards and upwards...
|
|
|
|
|
Hi
I have code where I position a dot on a map. I use a lot of style="position:absolute; left: numberpx; top: numberpx" code, but problem is it doesn't work in Netscape.
Where can I found comparisons of the two browsers especially for this type of problem
tx
|
|
|
|
|
Get used to it. Not much works correctly on Netscape.
onwards and upwards...
|
|
|
|
|
What version of Netscape?
A good list of many known bugs in the CSS implementations of different browsers can be found here:
http://www.richinstyle.com/[^]
Unfortunately, it only covers up to IE5.5 and NS6.
- Mike
|
|
|
|
|
We are going to be moving from one live web server, to 3 forming a web farm in the next month or so. We'll be using SQL and cookies to track sessions, and so far the examples I've looked at look great. However, one thing I'm not too sure of it the Verisign certificates. Obviously I have contacted them for more info, and it's looking very interesting, but I was wondering if anyone has experience of this, and if so, what advice (do's / don'ts ) you give?
Thanks
To honor you, and your sick games, this smiley will now represent licking chocolate off candy - David Chamberlain
|
|
|
|