|
InterKoro-- I cant do that, but intstead i'll post the java:
<title>name of site
function typeo(x) {
if (x.i == null) {
x.i = -1;
x.chri = 0;
x.txt = x.innerHTML;
x.lng = x.txt.length;
x.innerHTML = "";
x.style.visibility = "visible";
x.msg = "";
}
/* still making msg */
if (x.i < x.lng) {
for (x.i = 0; x.i < x.lng; x.i++) {
chr = x.txt.charAt(x.i)
if (chr == "<") {
aTag = "<";
while (chr != ">") {
x.i++;
chr = x.txt.charAt(x.i);
aTag = aTag + chr;
}
aTag = aTag;
x.msg = x.msg + aTag;
}
if (chr != ">") {
x.msg = x.msg + "<span style='display: none' id=" + x.id + "_" + x.chri + ">" + chr + "</span>";
x.chri++;
}
}
}
/* made msg */
if (x.i == x.lng) {
if (x.cmpl == null) {
x.innerHTML = x.msg;
x.cmpl = x.chri;
x.chri = 0;
}
//the number in abl variable controls time between letters
if (x.chri < x.cmpl) {
t = eval(x.id + "_" + x.chri);
t.style.display = "";
x.chri++;
ab1 = window.setTimeout("typeo(" + x.id + ")", 75);
}
}
}
function animatedObject(elementName,loop,speed,steps,endRoutines,route){
this.elementName = elementName;
this.loop = loop;
this.speed = speed;
this.steps = steps;
this.frameIndex = 0;
this.endRoutines = endRoutines;
this.route = route.split(',');
this.animate = animateObject;
this.move = moveObject;
this.show = showObject;
this.hide = hideObject;
animatedObjects[elementName] = this;
}
function stopTimeline(timelineNumber){
animationTime[timelineNumber] = animationTimeline[timelineNumber].length;
}
function startTimeline(timelineNumber) {
animationTime[timelineNumber] = 0;
timelineController(timelineNumber);
}
function timelineController(timelineNumber) {
if (animationTime[timelineNumber] <= animationTimeline[timelineNumber].length - 1) {
animationTime[timelineNumber]++;
if (animationTimeline[timelineNumber][animationTime[timelineNumber]] != null){
eval(animationTimeline[timelineNumber][animationTime[timelineNumber]]);
}
setTimeout('timelineController(' + timelineNumber + ')', 100);
}
}
function showObject(){
eval(layerObj + '["' + this.elementName + '"]' + styleObj + '.visibility = "visible"');
}
function hideObject(){
eval(layerObj + '["' + this.elementName + '"]' + styleObj + '.visibility = "hidden"');
}
function moveObject(left, top){
eval(layerObj + '["' + this.elementName + '"]' + styleObj + '.top = top');
eval(layerObj + '["' + this.elementName + '"]' + styleObj + '.left = left');
}
function animateObject(){
if (this.route.length > 4 && this.frameIndex < this.route.length) {
this.move(this.route[this.frameIndex], this.route[this.frameIndex + 1]);
this.frameIndex += 2;
setTimeout('animatedObjects["' + this.elementName + '"].animate()', this.speed);
}
else if (this.route.length == 4 && this.frameIndex <= this.steps) {
this.move(parseInt(this.route[0]) + (this.frameIndex * ((parseInt(this.route[2]) - parseInt(this.route[0])) / this.steps)), parseInt(this.route[1]) + (this.frameIndex * ((parseInt(this.route[3]) - parseInt(this.route[1])) / this.steps)));
this.frameIndex++;
setTimeout('animatedObjects["' + this.elementName + '"].animate()', this.speed);
}
else {
eval(this.endRoutines + "");
this.frameIndex = 0;
if (this.loop == "yes"){
this.animate();
}
}
}
function initAnimation() {
layerObj = (isNS) ? 'document' : 'document.all';
styleObj = (isNS) ? '' : '.style';
animationTime = new Array();
animationTimeline = new Array();
animatedObjects = new Object();
alvin = new animatedObject('alvinL','yes',100,400,'null','200,0,200,320');
bubble = new animatedObject('bubbleL', 'yes', 300, 25, 'null', '100,500,100,50');
morebubbles = new animatedObject('morebubblesL', 'yes', 300, 25, 'null', '500,500,500,50');
animationTimeline[0] = new Array();
animationTimeline[0][10] = 'alvin.show(); bubble.show(); alvin.animate(); bubble.animate();';
animationTimeline[0][50] = 'morebubbles.show(); morebubbles.animate();';
startTimeline(0);
}
var layerObj, styleObj, totalTime, currTime;
var animationTime, animationTimeline, animatedObjects;
var bon, boff;
var isNS = (document.layers);
var isDHTML = (document.layers || document.all);
can you crack the code?
)
// This is to validate the code. If
// the code is 1234 the mul = 1*2*3*4 = 24
// If your code is 9562 it will be
// usermulcode = 540 (9*5*6*2)
{
window.open("switch.pl/"+code+".shtml",'_top')
fails++
code=0 // Reset values
mul=1
digit=0
}
else
{
fails++ // Increase fails
code=0 // Reset values
mul=1
digit=0
if (fails<6)
{
if (fails<5)
{document.codepad.thecode.value="Try again"}
if (fails==5)
{document.codepad.thecode.value="Last time"}
}
else // To many tries = worp back
{
location="http://name of site/crash.shtml"
document.codepad.thecode.value="Bye!"
}
}
}
}
function keycodepad(mulcode)
{
usermulcode=mulcode
document.write("<form name=\"codepad\">");
document.write("<input type=\"button\" value=\" 1 \" onClick=\"Enter_code(1)\">");
document.write("<input type=\"button\" value=\" 2 \" onClick=\"Enter_code(2)\">");
document.write("<input type=\"button\" value=\" 3 \" onClick=\"Enter_code(3)\"><br>");
document.write("<input type=\"button\" value=\" 4 \" onClick=\"Enter_code(4)\">");
document.write("<input type=\"button\" value=\" 5 \" onClick=\"Enter_code(5)\">");
document.write("<input type=\"button\" value=\" 6 \" onClick=\"Enter_code(6)\"><br>");
document.write("<input type=\"button\" value=\" 7 \" onClick=\"Enter_code(7)\">");
document.write("<input type=\"button\" value=\" 8 \" onClick=\"Enter_code(8)\">");
document.write("<input type=\"button\" value=\" 9 \" onClick=\"Enter_code(9)\"><br>");
document.write("<input type=\"text\" name=\"thecode\" size=10 value=\"\"><br>");
document.write("</form>");
}
// Key-code script by Bart Jellema -->
keycodepad(24)
<bgsound src="music.mid" autostart="true" loop="infinite">
++interkoro++
|
|
|
|
|
this is NOT Java
Its JavaScript light typed language not Java!
"Imagination is more important than knowledge, for knowledge is limited while imagination embraces the entire world."
-Albert Einstein
|
|
|
|
|
I have an applet on my web page and I want it to display like this picture while it is loading -> http://compcom.hypermart.net/loading.gif
Anyone please tell me how can I do that?
Thank you
|
|
|
|
|
Go to www.java.sun.com
Look for javaplugin or /*something*/ you have to link to their plugin!
here is the link!
http://java.sun.com/getjava/intranet.html
"Imagination is more important than knowledge, for knowledge is limited while imagination embraces the entire world."
-Albert Einstein
|
|
|
|
|
Hi.
I'm creating a SMS-mobile sollution and the gateway that we use require us
to write files to an Outqueue for SMS-messages to be sent. The files are
simple text-files. The problem I'm dealing with is that the gateway require
our application to "lock" the file while writing to it, that is, no other
application can have file-permissions on our file. When the file containing
the SMS-message is written, the file-permissions need to change to "full
control" to allow other applications (the Gateway) to access it and delete
it once the message is sent.
Does anyone know how to solve this, or have a link to any useful information
?
Any help would be greatly appreciated !
Best Regards
Eirik Kjølsrud
Apropos Internet, Norway
|
|
|
|
|
Don't you hate it when you work hard on your project, only to find your client isn't so impressed just because of what it looks like on the outside?
If you need help with graphics and user interface layout, Z Web Graphics can help. We specialize in working with developer's to give your project the image it deserves. We know how hard you work behind the scenes, and we will help you reflect that on the surface.
All you have to do is email us at info@zwebgraphics.com, or fill out our customer profile form located on our website at www.zwebgraphics.com. It all can be done via email, by you telling us a little bit about you and your project, then we can begin designing mock up layouts, and sending you graphics via email. It is all very easy, and very inexpensive.
Contact us at info@zwebgraphics.com or visit our website at www.zwebgraphics.com for more information.
Z Web Graphics
a programmer's best friend
|
|
|
|
|
Oh! is this the place to advertise? I didn't realise,
I have a 2nd hand push bike for sale. Got two wheels and handlebars. Wear thick rubber pants and its quite comfortable. £400.95
We do it for the joy of seeing the users struggle.
|
|
|
|
|
Rassman wrote:
Oh! is this the place to advertise? I didn't realise,
I have a 2nd hand push bike for sale. Got two wheels and handlebars. Wear thick rubber pants and its quite comfortable. £400.95
Funny man...
Maybe Chris should add a free adds section...
"An expert is someone who has made all the mistakes in his or her field" - Niels Bohr
|
|
|
|
|
I'm an absolute Java beginner so please forgive me
I've got an applet (written in VisualCafe V4.5) that works fine in an applet viewer, but when I try to view it in a web page (IE6 and NS6.1) all I get is a gray box where the applet should be.
I assume the applet is correct as it's stage two of the tutorial that comes with VisualCafe Expert Edition. I'm also sure the class path name is correct.
The WebGain newsgroups hardly have any posting going on at all, and I know this may be a long shot, but I thought I'd ask this here. Thanks ever so much to anyone that can help.
Jeremy Davis
http://www.astad.org
|
|
|
|
|
The only reason I know for that to happen is that one of the classes used by the applet cannot be found. It might work in applet viewer because it is on the same machine and you set the correct classpath. But the browser is trying to "download" the classes as if they reside on a "remote" machine.
Check the "code=" and "codebase=" values in your html page that hosts the applet. "code=" must be the path of your applet class relative to the "codebase=", and all the other classes (except those came with the java language) used by your applet have to be found under "codebase=".
Hope this helps.
|
|
|
|
|
|
If don't seem to have a CODEBASE parameter. All I've got is...
<APPLET ARCHIVE="customer.jar" CODE="CustomerInfo.class" WIDTH="360" HEIGHT="233" ALIGN="BOTTOM">
</APPLET>
Exactly what is specified in the example as supplied with VisualCafe. All that is in the deployed directory the the HTML web page with <applet> in, and customer.jar
Jeremy Davis
http://www.astad.org
|
|
|
|
|
In that case, does the customer.jar file contain every (I mean EVERY!) class your applet need?
Also, if the browser only supports a lower version of java than your applet code need, then it won't be created.
|
|
|
|
|
Try getting the java console up on IE6. You need to enable it on the advanced options window, restart IE, and click on it on the view window. This will give you a crude java backtrace if any exceptions occur, and will tell you about any missing classes etc..
|
|
|
|
|
I had the same problem in IE6 under WinXP, the new xp runtime environment from sun fixed the problem.
|
|
|
|
|
How can I display an Applet loading status (Such as % complete) while loading large applet?
Thank you for helping me.
|
|
|
|
|
Hi,
At this moment there are 216 Java postings in this forum and over 20,000 postings in the C++ forum. Obviously, codeproject.com is used mainly by VC++ developers but as a VC++ developer that is looking around for another job I was wondering what the big deal is about Java. I’ve never paid much attention to it and I always felt that VC++ or even VB were the way to go when writing an app for most purposes in corporate and consumer environments.
Aside from “Web applications” can you really develop real desktop applications in Java?
What development environments are the most popular? (Obviously, the Visual Studio Java environment isn’t it.)
Does Java really live up to its promise of running in any environment (as long as you have a java runtime engine.)?
|
|
|
|
|
I haven't worked much with Java (only one little project), but here is my humble opinion:
Java is a sort of VB for Unix, at least when it comes to server-side apps. Language itself is pretty nice, but libraries are bad (full of "deprecated" classes and methods). Also, it is very slow comparing to C++. I did some benchmarks, and found out that C++ can be 17 times faster when dealing with big chunks of data. On the other side, for a simple BubbleSort alghoritm, Java was only 25% slower.
As for IDE, I've heard that the best one is Borland JBuilder, but even this one is far from Visual Studio. Personally, I used only UltraEdit.
I don't know any good desktop application written in Java. There are some Java IDE (Forte, etc) but they are very slow.
I vote pro drink
|
|
|
|
|
If you want to browse a larger Java discussion group, try the CodeGuru one at http://codeguru.com/cgi-bin/bbs/wt/wwwthreads.pl?action=list&Board=java.
As a C++/MFC/Windows programmer who has moved to Java, I can tell you that the two languages have different objectives, architectures and environments, and this makes comparisons arguable. However, from my POV, while C++ is more flexible and typically faster to run, it is technically more complex and challenging (which was what I liked about it). Java is simpler, more limited, easier to code, and so is generally far more productive in an appropriate context. It allows you to concentrate more attention on the overall design and architecture because the local technical complexity is reduced. The Java libraries are moving ahead rapidly, and are much better than in the early days, with far more facilities (particularly comms & networking) provided 'out of the box' than for C++, and many 'standard' specialised libraries available free from Sun.
You can write local PC applications in Java, but it comes into its own in the corporate environment where multi-tier client-server systems are developed, and especially where web services and the internet are involved. The JVM (Java Virtual Machine) that allows the same code to run on any platform makes it attractive for developers who can write and test code on an NT box and simply copy it to a production Unix/Linux/Aix/etc. server. I notice Microsoft is taking a similar approach with languages in .NET, where they all compile to a common virtual machine code.
In my experience, corporates that are not committed Microsoft shops are moving en-masse to Java for their client-server needs, because the Java 2 Enterprise architecture makes scalable, distributed, fail-safe, multi-platform, multi-user systems so much easier and quicker to write. For example, using EJB (Enterprise JavaBeans) means that an application server can manage transactions, database access, security, load-balancing, fail-over, caching, etc. on behalf of the programmer who is then free to concentrate on the business architecture and logic.
Of course, the Microsoft world is a cosy, well catered environment for those within it, and Microsoft development tools (for all the criticism) are still, in my opinion, better than the typical Java tools at the same price point. The .NET initiative looks likely to continue the quality support for Microsoft-only developers, and for them, there is little incentive to look elsewhere. However, many corporates want the flexibility of transparent multi-platform development and the other advantages of the Java enterprise architecture, and now that the JVMs are coming of age in performance terms and many do Just-In-Time native code compilation, C++ no longer has such a performance advantage. In fact I have recently heard of device drivers being developed in Java!
If your company isn't a Microsoft-only environment moving strongly into .NET development, it's worth thinking seriously about getting some Java experience.
Dave Lorde
|
|
|
|
|
>>C++ no longer has such a performance advantage
I've been working with both Java and C++/MFC over the last two years. From my experience, Java will never come close to the performance C++ will provide. Even with Suns JVM...if you want performance you develop C++ apps, if you don't need to worry about performance, don't have a GUI and you need to get you product to market quick, go with Java.
Regarding GUI's in Java, don't put your users in the spot where they have to wait a few minutes for the program to load as Java does. I've seen GUI's that are so slow the user keeps clicking on the icon and eventually there are 15 running apps running. Then see how slow your 1g htz machine can go! That can literally bring a user to tears! Bottom line....don't ever do GUI's in Java!
|
|
|
|
|
Excellent analysis Dave.
I concur with what you say, but the problem is that server side portability, which is where Java seems to be going strong these days, is not all that important when your server is a Windows box. Microsoft is counting on more and more servers running Windows 2K/XP so they can more easily sell people on .NET's advantages, which seem to be: (a) performance, (b) tools, and (b) multi-language support.
Regards,
Alvaro
|
|
|
|
|
Alvaro Mendez wrote:
.NET's advantages, which seem to be: (a) performance, (b) tools, and (b) multi-language support.
(b) and (c) definitely, but I'm not so sure about (a). Actually, I find .NET (beta-version) to be pretty much as fast (slow) as Sun's Java (and Sun's VM is not exactly the fastest one).
I vote pro drink
|
|
|
|
|
in a nutshell:
- real desktop applications aren't written in java. (or, to be more precise: for the java platform).
- popular: Jbuilder (borland), Together control center 5.5 (GUI+CASE tool) both for enterprise programming, Sun Forte (netbeans developer) is quite advanced but complicated, it's community edition is for free and very complete (<-> jbuilder comm. edition). all written in java, all real slow. Fast and free (but no debugger, high-end-hyped features): RealJ
- Programms in java run on any JVM environment .. since java is not only a programming language...
Java is a _platform_, it's a programming language, and it is a big class library.
1) It's platform uterly failed on the client / every day app side (and for a reason); I do not have not a single java killerapp software on this java platform, and due to the fact that a big it firm (sun) is pushing java, I am wondering why it did not succeed? Clients will _never_ be java, you can forget about that.
2) Language: the java syntax is so heavily influenced by C++ I must say it is just a rip-off. Even though, not only in detail, practical class design philosophy is differnent (non multi-inheritance, interfaces).
3) class library: big and complete, but its an implementation and this means it has ups and low ... Just look at the way the GUI looks. Yak. I do not care how well designed a GUI is for a *programmer* if the end product just doesn't look professional. (that's why I still use MFC, even though I do not like it's design.. did anyone hear of QT????)
C++ is a philosophy.
So what´s the big deal about java???
1) HYPE: sun is backing it up
2) TRUTH: it has a strong *SERVER* side (J2EE=java 2 enterprise edition and EJB) because even though java is slower, J2EE scales.. This is the single place where java is ruling. But that´s the enterprise edition and it's all about 3-thiered apps. that's why one should bother about java!!
I am a professional C++ coder and as A.Stepanov (STL originator) once said, " [..] I did not find any new insights - for the first time in my life programming in a new language did not bring me new insights. [..]".
I hold courses on Java programming for it students.
|
|
|
|
|
"Clients will _never_ be java, you can forget about that. "
Having implemented 3 of those, i do not think i am sure about THAT.
The first one, quite a big one, did actually expose a very advanced gui interface compared to other business applications in that area (it is a booking application for various transportation).
The reasons for using Java on the client side?, RMI: a quite easy way to do distributed component coding without all the fuzz you have to stand up to when using Corba or DCOM. Also, using AWT (and even, argh, Swing) makes it possible to throw all your energy into designing instead of dealing with billions of implementation details.
Jan
"It could have been worse, it could have been ME!"
|
|
|
|
|
Hi,
I am using Netbeans here quite extensively, and although I enjoy the elegance of java-based gui programming, I am not satisfied with the *result* - (the finished) product.
It just lacks the smoothness and clearness of a standard windows app. And customers not acquainted with the differences of swing/mfc whatsover often want a *real* windows app.
If your customers are satisfied with a java based client, so much the better - for you! You obviously save time and nerves and money using swing / etc.
Java programming never has been unelegant from a designers or programmers view.
|
|
|
|
|