|
Well _I_ would do the following:
When the user presses PRINT, I would generate a new page, with all the information in printable form (no images, just core information, all pages on ONE page, etc.).
Then the user must be advised to press the print button in his browser on THIS page.
On IE, you can even print automatically with javascript, if the page is loaded.
|
|
|
|
|
In ASP if i use Server.CreateObject(ANYCOMOBJECT)
I get the deafult interface pointer defined in the IDL file of that COM object. Now how to call the method of other interface which is there in my COM object.
|
|
|
|
|
When using Server.CreateObject() you have to provide a ProgID as a parameter. To the best of my knowledge ProgID is unique for each interface (correct me if I am wrong), so you should never have this problem. Also I could not find any references in documentation on being able to create object using default interface.
|
|
|
|
|
Hi!
VBScript/JScript access your object using the IDispatch interface and you cannot implement two IDispatch interfaces on a single object and make both available to Active Server Pages (ASP) clients.
What you can do instead, is to add a method (property) to the default interface which will return a pointer to the other IDispatch derived interface.
Regards,
Alex Gorev,
Dundas Software.
|
|
|
|
|
I am trying to run an external program using IIS and ASP on a Win 2K machine. This program is just a dops based program that has to be run on the server.
I have tried the AspExec component from serverobjects.com: http://www.serverobjects.com/products.htm#free
However I have not had any success getting it to work. Does anyone have any thoughts on what to try next??
Cory
|
|
|
|
|
This is a bit simplified, but basically you can write a little ATL DLL that calls CreateProcess. Leave the application name null and specify something like "cmd myprog.exe" in the command line parameter.
There are lots of subtleties in store depending on what you need from your program (stdin/out pipes are tricky) but this sort of thing works on NT and w2k - win9x too, but not as nicely. cmd has some useful switches you might want to check as well.
Tim
|
|
|
|
|
I need a tree control (written in JavaScript) which reside in a HTML page.
I need to populate them with data from a database. Althrough I passed some huge arrays from server to client and initialize the control, it does not work.
Probably I have a mistake in understanding the process, but really I need help with a working solution.
Which way to adopt??
|
|
|
|
|
Hello.
I would like to know the easiest, simplest way to dynamically generate the contents of one listbox ( item)based on the selected item of another listbox in the same asp page.
Thanks
|
|
|
|
|
Hi,
You can handle the event onselect for first listbox like this :
....
function MyFunction()
{
List2.length = newLength;
for(i = 0; i <= newLength; i++)
{
List2.options(i).value = newVal_Value;
List2.options(i).text = newVal_Text;
}
}
You can set newLength, newVal_Value and newVal_Text values according with the selected item in the List1 :
List1.options(List1.selectedindex).value
Good luck
|
|
|
|
|
Hi,
I figured out a way to execute applications, namely computer games such as the quake series and unreal tournament, by creating a file class in the registry that you that then create a url to, e.g. instead of file://myfile.txt, you could create a class and just put
myfile://param1 param2
so this works well for triggering games from a page. Alas - I need to figure out how to change the directory before executing the app. Any ideas? [and vb's chdir isn't the answer - it's not a script thing, its a setting in the registry's class that you create - I just cant find it]. ta
sim
|
|
|
|
|
Hi,
How to place site icon in IE Address text box like you can see in Hotmail.com?
Thank in advance.
|
|
|
|
|
assuming you have your site www.mysite.com, then in the root, put a file favico.ico [i think] - this will be downloaded onto clients pc's quickneasy so you get your own custom icon on ppls pcs
|
|
|
|
|
Try favicon.ico - Cristi added one to CodeProject.com and it works a treat.
|
|
|
|
|
Hi Chris,
Can you provide me the URL?? CodeProject has so much article..So little bit difficult to track.
One more ... I don't either it works in Netsacpe or not...? (I have no Netscape!!
|
|
|
|
|
There is no URL - you just need to create an icon for your site, call it favicon.ico, and place this in your website's root directory.
|
|
|
|
|
Chris,
Why don't you write it up as a simple article? Seems like enough people would be interested.
Also, I see the stanard IE logo beside codeproject.com in my address bar? What am I doing wrong?
|
|
|
|
|
Hi Chris,
I had already placed my icon named favicon.ico. But still I can't get my ICON in my IE address.
IE version 5.00.xx
Web Server: Apache (Latest!!)
Thanks for you help.
Regards,
Sarose Joshi
@YSGNet*
Nepal
|
|
|
|
|
To have the icon display in IE5 you need to add the site to your 'favorites' list. For some reason the icon that we had was doing some weird things, but Cristi has kindly reworked it and it seems to work fine for me now.
Easiest way to demonstrate it is to go back to the CodeProject homepage and click on the "Add to Favorites" link (top left hand corner) to add CodeProject to your favorites. The icon should appear next time you visit the homepage.
There are a couple of other ways you can specify favicon's so I guess I'd better write up an article
|
|
|
|
|
I need to make a script I wrote work in older versions of netscape. How can i set the inner html of a layer tag in javascript?
|
|
|
|
|
I'm not 100% sure but I think that these commands do the same thing in IE and Netscape:
*IE: object = document.all["objectName"];
object.innerHTML = ".......";
*Netscape: object = document.layers["objectName"];
object.document.open();
object.document.write(".......");
object.document.close();
|
|
|
|
|
Hi all,
I am trying to develop a search Engine that can rank
the search result like if I search using "Travel in Nepal",
The search will display the best matching with percentage
like you can see the MIT search engine.
If you have any idea, suggestion, links, hints or whatever please reply.
TIA
Regards,
Sarose Joshi
|
|
|
|
|
Are you talking about an internet search engine, or just a search engine for your site? IIS Index server gives you a rank. I'll be writing an article on it soon.
cheers,
Chris
|
|
|
|
|
Hi Chris,
Actually, I need to rank the result like if someone search using word like "Travel in Nepal"... I need top ten result. Can you provide me simple ANSI SQL or any hints.
Thanks
Sarose
YSGNet*
Nepal
|
|
|
|
|
|
Chris & Uwe.
You guys do realy a great and fantastic job ! The CodeProject has become one of my favorite sites, not only because of the success of my own article
I enjoyed reading your scripts and wistfully waiting for e.g. the comment scripts.
Keep on with your work !!!
|
|
|
|