HP970 Printing (OT)
Apologies for this, but I'm getting desperate! Has anyone else experienced persistent print queue stalling (sometimes with erroneous timeout error messages) when using the HP970cxi? There has been a driver upgrade on hp.com, but it is still most unreliable even with 128Mb RAM available. Since the program generates certificates involving digital photos at the end of an event day, it relies on time-critical printing which at present is virtually impossible. Are we are the only ones with problems using this otherwise excellent printer? /H Hugh Senior The Flexible Learning Company Consultant Programming Software Solutions Fax/Voice: +44 (0)1483.27 87 27 Email: [EMAIL PROTECTED] Web: www.flexibleLearning.com Archives: http://www.mail-archive.com/metacard%40lists.best.com/ Info: http://www.xworlds.com/metacard/mailinglist.htm Please send bug reports to [EMAIL PROTECTED], not this list.
client side http
Hi I've been playing with the sockets features in order to try and implement some client side http. I've been doing this because Metacard's built-in http support won't work with some URLs (something to do with the way aliasing is set up on the server, I think). The script below is a crude first attempt at this. It simply loads the data from the specified URL. (I've removed some stuff that was specific to my situation.) So far, it seems to work, even with previously unreachable URLs. Ideally, I'd like to be able to emulate the built-in http features of Metacard, but using sockets. (I've also had a go at the POST method, and it seems to work, but I need to make a more general solution than what I've done so far.) The scripts may be useful to anyone else wanting to do the same thing. More importantly, I'd appreciate any feedback from the sockets gurus about whether I'm going in the right direction. Two questions foremost on my mind: In order to show progress of the download (progress bar or whatever), is it necessary to do reads in short steps (as in the script below) or is there another way? How to handle http proxies? Is this just a question of opening the socket to the proxy and carrying on as before, or is it, as I fear, more torturous? Any comments appreciated. Cheers Dave Cragg --- local lcSocket, lcPath, lcData, lcHeader on httpLoad pURL ## remove initial "http://" if present if "http://" is char 1 to 7 of pURL then delete char 1 to 7 of pURL end if put offset("/",pURL) into tOff if tOff = 0 then put pURL into lcSocket put "" into lcPath else put char 1 to (tOff - 1) of pURL into lcSocket put char tOff to -1 of pURL into lcPath end if put numToChar(13) numToChar(10) into CRLF open socket to lcSocket put "GET" lcPath"HTTP/1.1" CRLF into tString put "host:" lcSocket CRLF after tString put CRLF after tString ## blank line is necessary write tString to socket lcSocket read from socket lcSocket until CRLF ##line 1 if word 2 of it = 200 then read from socket lcSocket until CRLF CRLF ##get the header put it into lcHeader get lineOffset("Content-Length", lcHeader) if it 0 then put it into tLineNum put word 2 line tLineNum of lcHeader into tLength put 1024 into tStep end if put empty into lcData put 0 into tCount put tLength div tStep into tTimes ## read in small steps in order to show a progress bar or other indication repeat for tTimes add 1 to tCount read from socket lcSocket for tStep put it after lcData ## handle progress bar updating here end repeat read from socket lcSocket until empty ## catch last few dribbles put it after lcData close socket lcSocket ## do something with lcData here (cache it, return it, or whatever) else ## crude error handling put word 2 of it close socket lcSocket end if end httpLoad --- on socketError pSocket, pErr ##crude error handling put pSocket ":" pErr end socketError -- on socketTimeout pSocket ##crude error handling put "Timed out" close socket pSocket end socketTimeout -- _ The LACS Centre (Business English Training Resources) mailto:[EMAIL PROTECTED] http://www.lacscentre.co.uk _ Archives: http://www.mail-archive.com/metacard%40lists.best.com/ Info: http://www.xworlds.com/metacard/mailinglist.htm Please send bug reports to [EMAIL PROTECTED], not this list.
Re: client side http
On Mon, 11 Sep 2000, Dave Cragg wrote: I've been playing with the sockets features in order to try and implement some client side http. I've been doing this because Metacard's built-in http support won't work with some URLs (something to do with the way aliasing is set up on the server, I think). Please try 2.3.2, which is a lot better about these things. It has just been released to beta test and now available for Linux, MacOS, and Win32 in the directory ftp://ftp.metacard.com/MetaCard/2.3.2/ The script below is a crude first attempt at this. It simply loads the data from the specified URL. (I've removed some stuff that was specific to my situation.) So far, it seems to work, even with previously unreachable URLs. Ideally, I'd like to be able to emulate the built-in http features of Metacard, but using sockets. (I've also had a go at the POST method, and it seems to work, but I need to make a more general solution than what I've done so far.) We're actually working on the same thing, as the plan all along was to replace the built-in HTTP routines with an script library that uses sockets to do HTTP, FTP, and other protocols. We welcome your participation in the design, implementation, and testing of this new library. 2.3.2 already has one new feature that will make implementing such a library much easier: a "wait for messages" command which allows event dispatching within a handler. This is useful for building synchronous function calls that still require some event dispatching (e.g., one that does the equivalent of "get url http://somehost/somefile"). The scripts may be useful to anyone else wanting to do the same thing. More importantly, I'd appreciate any feedback from the sockets gurus about whether I'm going in the right direction. Two questions foremost on my mind: In order to show progress of the download (progress bar or whatever), is it necessary to do reads in short steps (as in the script below) or is there another way? The best way to do it is to do a simple "read from socket s with message m" and handle the assembly and processing of the data in the message handler. This does the chunking automatically for you in whatever size chunks the OS is dealing in and so is the most efficient method. How to handle http proxies? Is this just a question of opening the socket to the proxy and carrying on as before, or is it, as I fear, more torturous? There are (at least) two types of proxies: those that you know the address of and those where the proxy is actually specified as a URL of a document which contains the proxy information. MetaCard's built-in HTTP support supports the former, but implementing support for the latter is one of the things that the new script-based library will do. Regards, Scott Any comments appreciated. Cheers Dave Cragg _ The LACS Centre (Business English Training Resources) mailto:[EMAIL PROTECTED] http://www.lacscentre.co.uk _ Scott Raney [EMAIL PROTECTED] http://www.metacard.com MetaCard: You know, there's an easier way to do that... Archives: http://www.mail-archive.com/metacard%40lists.best.com/ Info: http://www.xworlds.com/metacard/mailinglist.htm Please send bug reports to [EMAIL PROTECTED], not this list.
A few short questions
Here are some questions that have occurred to me during my development work using MetaCard. I'm not sure whether I'm simply missing a few tricks (not unheard of!), or whether these are genuine feature holes. Some 'constant' questions: 1) Is it possible to declare global constants or are all constant declarations limited in scope to the script in which they are contained? 2) Is it possible to declare a non-printing (special) character as a constant, e.g. something like "constant CRLF = $013$010" to declare a end of line constant? 3) Is it possible for a constant declaration to include expressions, e.g. something like 'constant padding = tab "|" tab'? Some script debugging questions: 5) Is it possible to insert some special breakpoint or trap command that let's you run scripts at near normal speed (without having the script debugger open), but that will suspend the execution and allow you to look at variable values etc. single step etc. - i.e that will throw you into the script debugger ONLY when you reach a breakpoint? 6) Is it possible to 'watch' a variable, i.e. set up a monitor that only kicks in when a named variable's value changes? Cheers Peter -- Peter Reid Reid-IT Limited, Loughborough, Leics., UK Tel: +44 (0)1509 268843 Fax: +44 (0)870 052 7576 E-mail: [EMAIL PROTECTED] Web: http://www.reidit.co.uk Archives: http://www.mail-archive.com/metacard%40lists.best.com/ Info: http://www.xworlds.com/metacard/mailinglist.htm Please send bug reports to [EMAIL PROTECTED], not this list.
Re: A few short questions
On Mon, 11 Sep 2000, Peter Reid wrote: Here are some questions that have occurred to me during my development work using MetaCard. I'm not sure whether I'm simply missing a few tricks (not unheard of!), or whether these are genuine feature holes. Some 'constant' questions: 1) Is it possible to declare global constants or are all constant declarations limited in scope to the script in which they are contained? They're limited to one script. Suggestions about how to do it globally (like a #include in C) are welcome, but the discussion about this on the xtalk mailing list awhile back broke down before any suitable method was proposed (the big problems are establishing *when* the definition is to be done and what to do if the #included script isn't found). 2) Is it possible to declare a non-printing (special) character as a constant, e.g. something like "constant CRLF = $013$010" to declare a end of line constant? No, but "crlf" already is a pre-defined constant ;-) 3) Is it possible for a constant declaration to include expressions, e.g. something like 'constant padding = tab "|" tab'? No, they must be either strings or numbers. Allowing escapes (like C strings) is something we considered but rejected. Some script debugging questions: 5) Is it possible to insert some special breakpoint or trap command that let's you run scripts at near normal speed (without having the script debugger open), but that will suspend the execution and allow you to look at variable values etc. single step etc. - i.e that will throw you into the script debugger ONLY when you reach a breakpoint? No, but this is on the feature-request list. 6) Is it possible to 'watch' a variable, i.e. set up a monitor that only kicks in when a named variable's value changes? Theoretically, yes. But there is no UI that supports this now so you'd have to hack up the debugger scripts, which is not an endeavor to be taken lightly. Regards, Scott Cheers Peter -- Peter Reid Reid-IT Limited, Loughborough, Leics., UK Tel: +44 (0)1509 268843 Fax: +44 (0)870 052 7576 E-mail: [EMAIL PROTECTED] Web: http://www.reidit.co.uk Scott Raney [EMAIL PROTECTED] http://www.metacard.com MetaCard: You know, there's an easier way to do that... Archives: http://www.mail-archive.com/metacard%40lists.best.com/ Info: http://www.xworlds.com/metacard/mailinglist.htm Please send bug reports to [EMAIL PROTECTED], not this list.
Re: A few short questions
On Mon, 11 Sep 2000, Peter Reid wrote: Here are some questions that have occurred to me during my development work using MetaCard. I'm not sure whether I'm simply missing a few tricks (not unheard of!), or whether these are genuine feature holes. Some 'constant' questions: 1) Is it possible to declare global constants or are all constant declarations limited in scope to the script in which they are contained? They're limited to one script. Suggestions about how to do it globally (like a #include in C) are welcome, but the discussion about this on the xtalk mailing list awhile back broke down before any suitable method was proposed (the big problems are establishing *when* the definition is to be done and what to do if the #included script isn't found). 2) Is it possible to declare a non-printing (special) character as a constant, e.g. something like "constant CRLF = $013$010" to declare a end of line constant? No, but "crlf" already is a pre-defined constant ;-) 3) Is it possible for a constant declaration to include expressions, e.g. something like 'constant padding = tab "|" tab'? No, they must be either strings or numbers. Allowing escapes (like C strings) is something we considered but rejected. Some script debugging questions: 5) Is it possible to insert some special breakpoint or trap command that let's you run scripts at near normal speed (without having the script debugger open), but that will suspend the execution and allow you to look at variable values etc. single step etc. - i.e that will throw you into the script debugger ONLY when you reach a breakpoint? No, but this is on the feature-request list. 6) Is it possible to 'watch' a variable, i.e. set up a monitor that only kicks in when a named variable's value changes? Theoretically, yes. But there is no UI that supports this now so you'd have to hack up the debugger scripts, which is not an endeavor to be taken lightly. Regards, Scott Thanks for the answers Scott - now I know (I'm not missing any tricks this time!). Cheers Peter -- Peter Reid Reid-IT Limited, Loughborough, Leics., UK Tel: +44 (0)1509 268843 Fax: +44 (0)870 052 7576 E-mail: [EMAIL PROTECTED] Web: http://www.reidit.co.uk Archives: http://www.mail-archive.com/metacard%40lists.best.com/ Info: http://www.xworlds.com/metacard/mailinglist.htm Please send bug reports to [EMAIL PROTECTED], not this list.
Re: client side http
At 12:02 PM -0600 9/11/00, Scott Raney wrote: On Mon, 11 Sep 2000, Dave Cragg wrote: I've been playing with the sockets features in order to try and implement some client side http. I've been doing this because Metacard's built-in http support won't work with some URLs (something to do with the way aliasing is set up on the server, I think). Please try 2.3.2, which is a lot better about these things. It has just been released to beta test and now available for Linux, MacOS, and Win32 in the directory ftp://ftp.metacard.com/MetaCard/2.3.2/ I just tried it, and you're right. It now works with previously unreachable URLs. Great stuff. Thanks too for the other information. Cheers Dave Cragg _ The LACS Centre (Business English Training Resources) mailto:[EMAIL PROTECTED] http://www.lacscentre.co.uk _ Archives: http://www.mail-archive.com/metacard%40lists.best.com/ Info: http://www.xworlds.com/metacard/mailinglist.htm Please send bug reports to [EMAIL PROTECTED], not this list.
Re: client side http
Hi I've been playing with the sockets features in order to try and implement some client side http. I've been doing this because Metacard's built-in http support won't work with some URLs (something to do with the way aliasing is set up on the server, I think). The script below is a crude first attempt at this. It simply loads the data from the specified URL. (I've removed some stuff that was specific to my situation.) So far, it seems to work, even with previously unreachable URLs. Ideally, I'd like to be able to emulate the built-in http features of Metacard, but using sockets. (I've also had a go at the POST method, and it seems to work, but I need to make a more general solution than what I've done so far.) The scripts may be useful to anyone else wanting to do the same thing. More importantly, I'd appreciate any feedback from the sockets gurus about whether I'm going in the right direction. Two questions foremost on my mind: In order to show progress of the download (progress bar or whatever), is it necessary to do reads in short steps (as in the script below) or is there another way? That's the way but when you get data it comes in chunks anyway. Use repeat only if you have to. How to handle http proxies? Is this just a question of opening the socket to the proxy and carrying on as before, or is it, as I fear, more torturous? Yes, take a look at my ftp client (http://www.cloud9.net/~undo) which handles proxy, it should be the same. It also shows you how I handled the progress bar and others. Any comments appreciated. Cheers Dave Cragg --- local lcSocket, lcPath, lcData, lcHeader on httpLoad pURL ## remove initial "http://" if present if "http://" is char 1 to 7 of pURL then delete char 1 to 7 of pURL end if put offset("/",pURL) into tOff if tOff = 0 then put pURL into lcSocket put "" into lcPath else put char 1 to (tOff - 1) of pURL into lcSocket put char tOff to -1 of pURL into lcPath end if put numToChar(13) numToChar(10) into CRLF CRLF is built in you don't need to do the above. open socket to lcSocket put "GET" lcPath"HTTP/1.1" CRLF into tString put "host:" lcSocket CRLF after tString put CRLF after tString ## blank line is necessary Put an empty space between header item and value = host: host.com write tString to socket lcSocket read from socket lcSocket until CRLF ##line 1 if word 2 of it = 200 then read from socket lcSocket until CRLF CRLF ##get the header put it into lcHeader get lineOffset("Content-Length", lcHeader) if it 0 then put it into tLineNum put word 2 line tLineNum of lcHeader into tLength put 1024 into tStep end if put empty into lcData put 0 into tCount put tLength div tStep into tTimes ## read in small steps in order to show a progress bar or other indication repeat for tTimes add 1 to tCount read from socket lcSocket for tStep put it after lcData ## handle progress bar updating here end repeat read from socket lcSocket until empty ## catch last few dribbles put it after lcData close socket lcSocket ## do something with lcData here (cache it, return it, or whatever) else ## crude error handling put word 2 of it close socket lcSocket end if end httpLoad --- on socketError pSocket, pErr ##crude error handling put pSocket ":" pErr end socketError -- on socketTimeout pSocket ##crude error handling put "Timed out" close socket pSocket end socketTimeout -- _ The LACS Centre (Business English Training Resources) mailto:[EMAIL PROTECTED] http://www.lacscentre.co.uk _ Regards, Andu ___ [EMAIL PROTECTED] Archives: http://www.mail-archive.com/metacard%40lists.best.com/ Info: http://www.xworlds.com/metacard/mailinglist.htm Please send bug reports to [EMAIL PROTECTED], not this list.