Search:

Type: Posts; User: andbin

Page 1 of 19 1 2 3 4

Search: Search took 0.33 seconds.

  1. Replies
    7
    Views
    143

    Re: Compiling on the command line on my mac

    Strings must use the basic ASCII double-quotes character " ... " . Not “” (the special Unicode quotation marks with code U+201C / U+201D).

    I also suspect you have used some kind of "word...
  2. Replies
    7
    Views
    143

    Re: Compiling on the command line on my mac

    Please, show your full code. And also the commands you have used.
  3. Re: swing application where does startup code belong

    Without other informations it's hard to tell. You should clarify what are those files and the general architecture of your application. Are those files "configuration"? Or user "data"?
    What is sure...
  4. Replies
    3
    Views
    111

    Re: Client Server Chat Code

    What do you use to compile/run? JDK version? Eventual IDE and which?

    On JDK 8 your code compiles correctly. There is only a warning because you have not used the ArrayList with "generics". I have...
  5. Re: how to convert socketdatagram to Serversock?

    TCP sockets (in Java Socket/ServerSocket) are very different from UDP sockets. TCP is a "connection" oriented protocol. Once a connection is established between two end-points, that connection...
  6. Re: how to convert socketdatagram to Serversock?

    No, I didn't mean this in a strict sense. I repeat the question: do you know the difference between TCP and UDP ("datagrams")?
    Can you google or check on Wikipedia about these two? I may explain you...
  7. Re: how to convert socketdatagram to Serversock?

    Did you understand the difference between TCP ("connection" oriented) communications and UDP ("connection-less" oriented) communications?
    For real time communications (e.g. voice/video), UDP (that...
  8. Replies
    3
    Views
    135

    Re: html string from resource

    As stated before, I am not Android expert. For what I know, the TextView doesn't know anything about HTML, Html.fromHtml returns a Spanned (a kind of "styled" text) suitable for and understood by the...
  9. Replies
    4
    Views
    226

    Re: Problem with the exception

    Indeed, printStackTrace has a void return type. It prints somewhere (here on stdout), it doesn't return a string. You can't get the stacktrace in that way.

    If you really want a String with the...
  10. Re: Algorithm for calculating lines for paragraph

    Apart this, you should tell us what are you trying to do and for which reason. Do you need to generate bitmap images of paragraphs? Do you need this algorithm to draw the single words on a JavaSE...
  11. Replies
    3
    Views
    135

    Re: html string from resource

    I don't know much about Android development (very little) but ... the question is at XML level. I guess that the parser of XML resource files is more interested in the text content and doesn't know...
  12. Replies
    4
    Views
    226

    Re: Problem with the exception

    You should verify (and tell us) the exact point of the error. If you are unsure how to do this, try smaller parts of that long concatenation. The error says that there is something of void type, that...
  13. Replies
    4
    Views
    166

    Re: Arrays with length > Integer.MAX_VALUE

    Hi, if you don't need a true, real Java array directly in your hands, you can have a "collection". It's perfectly possible to implement a "list" collection (and not necessarily tied to the...
  14. Thread: frame issues

    by andbin
    Replies
    3
    Views
    282

    Re: frame issues

    Please, describe and/or show the code you have used. We can't know at this moment .... are you moving a component at absolute locations? are you using custom painting in an your component? are you...
  15. Re: I think one class is over riding the other one?

    The content pane of JFrame has, by default, a BorderLayout. A BorderLayout subdivides the space in only 5 areas and only one component can be shown in each area.

    Doing:
    frame.add(xyz);
    is...
  16. Replies
    3
    Views
    377

    Re: TCP Java Socket Server

    The main point: you are not overriding the run() of Thread. ;)

    But there is also other you should understand and improve ....
  17. Replies
    4
    Views
    303

    [SOLVED] Re: Printf not working?

    See the word "Argument". You are missing an argument. printf/format methods make use of the varargs feature since Java 5.

    printf("format string", arg1, arg2 .............. );

    In your case:
    ...
  18. Replies
    2
    Views
    208

    Re: Finding the binary of negative numbers

    First, at binary level, there is no "negative" or "positive". Binary is 0s and 1s. Stop.
    The knowledge of "negative" is given by a specific representation (on a word of N bits), that is mainly...
  19. Thread: Reference type

    by andbin
    Replies
    2
    Views
    224

    Re: Reference type

    Yes. Was this your question or doubt?
    setValue receives a copy of the reference to the Person object instantiated in main. This means that setValue cannot change the value of the 'p' variable in the...
  20. Replies
    5
    Views
    405

    [SOLVED] Re: Graphics2D Exception

    And (besides Norm answer) I add another important issue: the mouseClicked (or any other event handling method) is not the appropriate moment/location where you can make a draw (except situations...
  21. Replies
    2
    Views
    258

    Re: java networking in wireless sensor network

    First, at programming level there is no difference between a cabled network and a wireless network. In other words, there isn't a code for cabled communication and a code for wireless communication....
  22. Thread: Calculator app

    by andbin
    Replies
    14
    Views
    950

    Re: Calculator app

    No, not necessarily. It's just only one possible option. And it's not even easy because a string like that must be parsed/interpreted. There are apposite libraries for this. If you want to do this...
  23. Replies
    2
    Views
    444

    Re: Desktop Notifications using JEE

    A web application is normally executed on a server machine and then the results (HTML plus other) are viewed/executed typically by a browser on the client machine.


    At server side, being on...
  24. Replies
    3
    Views
    290

    Re: Date and SimpleDateFormat Class

    The initialization to null is not really necessary in this case, because d1/d2 are assigned by format.parse before any use of these variables.


    The main concept behind Date class is that it...
  25. Thread: Calculator app

    by andbin
    Replies
    14
    Views
    950

    Re: Calculator app

    Your code is certainly a starting point. There are some things you can improve, for example instead to use java.awt.Frame, you can and should use javax.swing.JFrame (AWT is "old" nowadays). Another...
Results 1 to 25 of 458
Page 1 of 19 1 2 3 4