Thanks! I'm having problems getting the js.jar I need through our
firewall at work, but I'll try it out at home later.
David
On Mon, 27 Dec 2004 13:44:48 -0800 (PST), Ivan Ivanov
<[EMAIL PROTECTED]> wrote:
> David, yes it is possible by using javascript:
>
> <project>
> <scriptdef name="filesize" language="javascript">
> <attribute name="file"/>
> <attribute name="property"/>
> <![CDATA[
> importPackage(Packages.java.io);
> f = new File(attributes.get("file"));
>
> project.setNewProperty(attributes.get("property"),
> f.length());
> ]]>
> </scriptdef>
> <filesize file="filesize.xml"
> property="filesize"/>
> <echo>$${filesize} is ${filesize}</echo>
> </project>
>
> HTH Ivan
>
> --- David Kavanagh <[EMAIL PROTECTED]> wrote:
>
> > I'm using ant for a J2ME project and I need to get
> > the jar file size
> > into my .jad file. So, I was looking for something
> > in Ant that might
> > let me read the size of a file into a property. I
> > couldn't find
> > anything! I have no problem writing a custom task,
> > but I really hope
> > there is something existing that will do this for
> > me. Any ideas?
> >
> > David
> >
> >
> ---------------------------------------------------------------------
> > To unsubscribe, e-mail:
> > [EMAIL PROTECTED]
> > For additional commands, e-mail:
> > [EMAIL PROTECTED]
> >
> >
>
> __________________________________
> Do you Yahoo!?
> Jazz up your holiday email with celebrity designs. Learn more.
> http://celebrity.mail.yahoo.com
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]