|
You are correct. I just had to set the size to arbitrary values (10,10,10,10) and show it. Then getinsets returned the proper info. I then just hide it, size it correctly and carry on.
Thanks,
sbl
|
|
|
|
|
Hi
I have tried to put som images on my applet. This works fin in the appletviewer but when i try to view it in a Browser no images i shown. Can someone tell my why ?
Best regards Lars
|
|
|
|
|
Hei
it might be because appletviewer is configured to use the vertual machine , which sun ships with the JAVA interpriter .
However the browser (i think u using internet explorer)has inbuild virtual machine,JVM 1.0 .
Ur code uses Newer classes , i.e. java 1.2.0 and above.
solution :
1. use older classes
2. use java pluggin .
if u have any doubts , mail me at
pushp_i@hotmail.com
and put subject as 'codeproject'
i am pushpi from india
|
|
|
|
|
Not Prety Sure Why?,
Check your ""Codebase"" property of the Applet tag
|
|
|
|
|
how do i open a bitmap?
it would seem that java doesn't recognize the file format.
is there another way of getting the information besides getting the pixel colors one by one from the file, possibly an existing class that does that for me? if there isn't can anybody help me out?
|
|
|
|
|
I have written a Zip program on Java which has a main function.
public static void main(String[] args)
Once I compile and run it it works fine.
It zips up a folder's content and uses the name of the folder to name the zip file.
ex:
c:\jdk1.3.1\bin\java Zip temp
The program works fine, However, I've tried to use this program on ASP.
How do I call the main function on the Java program from the ASP?
<%
Dim objZip
// Create an instance of the Java Object
Set objZip=GetObject("java:Zip")
????? How do I call the main function ???????????????
//Destroy the object
Set objZip = Nothing
response.write "end of file"
%>
Thanks
Jorge
|
|
|
|
|
Hello!
Read this article...http://support.microsoft.com/support/kb/articles/Q167/9/41.ASP
Ullas Dastakar
|
|
|
|
|
In the code of the ActiveX control, an instance of a MFC DLL component is created. Moreover, this ActiveX control passes its IDispatch interface using CCmdTarget::GetIDispatch( ) to the DLL component instances it creates. Likewise, in the code of that DLL component, an instance of this ActiveX control is created. Upon receiving the IDispatch interface of the calling ActiveX control, the DLL component will use COleDispatchDriver::AttachDispatch( ) to attach this IDispatch interface to the ActiveX control instance it creates. This way, a 2-way communication channel can be created between the caller ActiveX control and the callee DLL component -- the caller ActiveX control instance can access those various methods/properties of the callee DLL component instance and the callee DLL component can also access those methods/properties of the caller ActiveX control.
Now it comes to JavaBean, I have already succeeded in creating an instance of that DLL component in Java and it should not be a problem for the DLL component to create an instance of my JavaBean component. But I don't know how to find the equivalent mechanism for passing and attaching the IDispatch interface of the ActiveX control? Does JavaBean also have a similiar stuff? If not, is there any way to achieve the same result with JavaBean?
|
|
|
|
|
Hello everyone,
Well I m a novice into this JACOB API. I downloaded
the software which acts as a bridge b/w Java and COM.
Its downloaded from the website -
http://users.rcn.com/danadler/jacob/
Can anyone lend me a helping hand please ?
But the main problem is that there is no
API DOCUMENTATION of JACOB to b precise apart frm MSDK
for Java/ Sun SDK for Java.
So if i want to know vich functions have to b used
and all how am I goin to find it out.
Can anyone please help me reg. this.
Also I downloaded this for I wanna call and use
functions of a COM dll viz. Win Media Player's DRM
API.
Its windows platform based. I wanna use that in java.
Anyone who has worked on that ? To give a brief intro
abt tht its basically a Digital rights manager for
securing streaming media in a B2B framework. I wanna
do tht urgently so please i request anyone to come out
with a helping hand for how to use JACOB and that API.
I wud b very grateful.
Thanking You,
Shamant. - Java Developer.
|
|
|
|
|
Hello everyone,
Well I m a novice into this JACOB API. I downloaded
the software which acts as a bridge b/w Java and COM.
Its downloaded from the website -
http://users.rcn.com/danadler/jacob/
Can anyone lend me a helping hand please ?
But the main problem is that there is no
API DOCUMENTATION of JACOB to b precise apart frm MSDK
for Java/ Sun SDK for Java.
So if i want to know vich functions have to b used
and all how am I goin to find it out.
Can anyone please help me reg. this.
Also I downloaded this for I wanna call and use
functions of a COM dll viz. Win Media Player's DRM
API.
Its windows platform based. I wanna use that in java.
Anyone who has worked on that ? To give a brief intro
abt tht its basically a Digital rights manager for
securing streaming media in a B2B framework. I wanna
do tht urgently so please i request anyone to come out
with a helping hand for how to use JACOB and that API.
I wud b very grateful.
Thanking you,
Yours faithfully,
Shamant Ayyar,
Java Developer.
Thanking You,
Shamant.
|
|
|
|
|
I have a javascript with a drop-down list from which the user
may select one from a number of options. I would like to be able
to have an external app perform the same selection under certain
conditions. Is there a way to communicate with a javascript.
Also I should also note that this javascript is operating within the context of an HTA. Thank you.
|
|
|
|
|
hi out there,
i've the following problem. i wrote an image-wrapper (awt.image), using the class pixelgrabber to access the pixels within the image. netscape (4.7) seems to change all colors to different gray-values instead of the real color while ie 5 is doing all work fine. does anyone know a solution to this problem...
thx 4 help,
pHreak.
|
|
|
|
|
Hello,
i need to design and generate reports dynamically in java application. How do i do it..please help.
Pooja
pooja_rajdev@hotmail.com
|
|
|
|
|
Hello everyone!
In order to monitor the progress of the reading/downloading of a file/html & do some checking at the same time, which stream should be used?
Which method is for checking the file/html size?
Thanks in advance.
|
|
|
|
|
Can you guys help me with the following?
I'm writing a program that asks the user to enter the name of the text file, it then scan the content and extract numbers from that file. The problem is I want it to filter out the non-digit elements using Stream Tokenizer. So with the following text:
I wish I can earn $1,000,000 a year!
The program will return 1000000
Thanks...
|
|
|
|
|
Your problem is that the stream tokenizer isn't going to recognise "," as part of a number. There are two approaches I'd consider.
- Clear the tokenizer, then set 0-9 and , as "word" characters. Ignore every token but words, then, when you get a word, check that there are digits in it amongst the commas.
- Forget the tokenizer, read character by character and write a state based lexical analyser. This needn't be very complicated, the states are just "I'm in a number" and "I'm not in a number".
The lexical analyser would look something like this.
InputStreamReader is ...
boolean isInANumber;
int theNumber;
int ch;
do {
ch = is.read();
if(isInANumber) {
if(Character.isDigit(ch))
theNumber = theNumber * 10 + Character.digit(ch, 10);
else if(ch != ',') {
.... do something with theNumber
isInANumber = false;
}
}
else if(Character.isDigit(ch)) {
isInANumber = true;
theNumber = Character.digit(ch, 10);
}
}
while(ch != -1);
|
|
|
|
|
Assuming u have already tokenized the sentence using
StreamTokenizer st=new StreamTokenizer(ursentence);
while(st.hasMoreElements())
{
String dollarValue=(String)st.nextElement();
if(dollarValue.charAt(0)=='$')
{
String s="";
int i=0;
while(true)
{
if((dollarValue.charAt(i)>='0'&& dollarValue.charAt(i)<='9'))
{
s=s+dollarValue.charAt(i);
}
else if(dollarValue.charAt(i)=='.')
{
s=s+dollarValue.charAt(i);
}
else if(dollarValue.charAt(i)==' ')
{
System.out.println("invalid number format");
System.exit(1);
}
i++;
if(i==dollarValue.length())break;
}
System.out.println("This is ur number"+Integer.parseInt(s));
}
}
I.The above function assumes that there is $ sign at first position of the value and there are no spaces after $ sign.
II.The above program assumes that u r using integers for double values.
If the value is double use Double.parseDouble instead of Integer.parseInt
Cheers
Koundinya
|
|
|
|
|
hi there,
You forgot to include one class file TestObj in XYObjectArray.zip. Otherwise please let me know how can i create that object which you used in ArrayTest program.
thanks
saurabh
|
|
|
|
|
Why I need the UDP ?
i want to create something (Like OCX or DLL) to let the server send a message to the client(s) inform them to refresh ,redirect ,there is new email, XXX is logged on.
how i'm thinking to solve this problem?
create client OCX (without using the WinSock.OCX) to wait and manage the server message. and create an DLL on the server that will send the message to the Client OCX. (i think this is a good solution ?! do you think that ????!! )
What i want ?
i do not know how to write a code deal with UDP ?!
if you have another idea ?? i'll be pleased to you if you send it to me
Note : I’m talking about intranet.
Can any one there help me ? or give and any article(s) that could help ?!
web programmer.
|
|
|
|
|
Hi, I am Yohan. I am thinking of making screen mate using Java swing. But problem is that I couldn't find any solution of hiding jwindow while displying the image only in the desktop when the program launced and that moves when mouse cliked on it , so that I can show visual effects as same as that of scree mates made of C. if anyone know how to hide jwindow but show and move image, please let me know
|
|
|
|
|
I've heard that Microsoft has not planned to implement a higher version of Java than 1.1 in it's Internet Explorer. What programming technique should I use if I want to get the same functionality that I got with Java Applets? (For example common dialog controls; platform independence)
|
|
|
|
|
Well. Users can download Java Runtime plugin's and your Java Applet's should just work fine with the plugin in any browser.
---------------
Dan Ammasai
---------------
|
|
|
|
|
activex controls are an option.
they allow you to run native code inside a web browser, so you can do whatever you want (VB, C++ etc)
they are not secure though, so some peoples security settings may not let them run.
-Jack Mott
jackm@scalablesoftware.com
|
|
|
|
|
hi
Alternative to the older VM hmmm !,
U may use java plugins instead ,
but for that u will have to use
OBJECT tag instead of APPLET tag(internet explorer).
EMBED tag in netscape communicator.
and good thing is u can always download newer vertual machine and configure ur pluggin for that.
Ur HTML would also run swing object provided u configure client plugin for that and use above mentioned tag ..
If u have any further queries ,mail me at pushp_i@hotmail.com and metion 'codeproject' in subject
Pushpi from india
|
|
|
|
|
Hi! I've got a problem. I would like to write Java applets with swing components.
But Microsoft's Internet Explorer is not able to show them. Is there a possiblity to include the swing classes in my project manually so that a user of IE can download this classes together with my project?
If you cannot answer this question. Do you know a discussion place where I may get any help?;)
Thanks.
Gregor Mitsch
E-Mail: abacus-@gmx.de
|
|
|
|