Easiest RowHeader?

Hi,I'm not good at programming and English.
But I find a way to make RowHeader in JTable,so i'll try.
if it has already sugegsted,I'm sorry.
I cant find this method anyother website.
Jtable has ColumnHeader,but not RowHeader.
So,
1. "get Renderer at Some JTable"
DefaultTableCellRenderer rhrenderer = (DefaultTableCellRenderer)table.getTableHeader().getDefaultRenderer();
2."get first Column at JTable "
TableColumn column0 = table.getColumnModel().getColumn(0);
3."set Renderer at first column "
column0.setCellRenderer(rhrenderer);
This method will make JTable, like a Excell.
I think RowHeader with JScrollPane is not good at other work.
This method can add new Row ,only do"table.addRow()".(humm..bad English..)
And,Even if JTable or Header,Cell do not have some Listener,
row's cell are all selected with rowHeader clicked.
Additionally,easy to cusutom border,height,width,and anyother.
I confirmed it on Windows Vista.
So,CellRenderer show "ClassicStyle".this is one of problems.
RowHeader is not VistaStyle.
Doesn't depend on OS is good point,but If you want to get some good design JTable,
you have to customize Renderere or UI.
thank you for reading.
Ah..I think some people already find this way .but Im grad to find it..
I hope to "Sun"make rowheader system soon.

In the future, Swing related questions should be posted in the Swing forum.
[Row NumberTable|http://www.camick.com/java/blog.html?name=row-number-table] show my attempt at a row header for tables.

Similar Messages

  • Web - What is easiest way to implement User Security and User Profiles

    Hi, I am new to these forums and kind of new to Java. Sorry if this is in the wrong forum!
    Bit of background to my experience with java
    I have been playing about with java for a number of years and have created a few basic programs such as a screen shot tool that allows you to capture to default locations and look at previews first etc. I am now venturing into web related stuff. I work in IT doing systems testing and have done bits of basic development on various things.
    What I've done so far
    I am using Netbeans IDE 6.7 and MySQL 5.0
    I am trying to learn more complex java and have decided to try build a basic web / database system that basically implements adding / amending / deleting data from a MySQL database through web pages. I am now trying to implement basic user access and profiles. I have so far got the following:
    - MySQL table with user info - username / password
    - JSP page with usual login stuff
    - Servlet that validates the username and password - if correct forwards to main menu page.
    Its as simple as that - there is nothing stopping you just typing in the URL of the main menu page and going from there.
    What I want
    I am wanting to eventually get the following:
    - User authentication so that you have to logon before you can access anything else
    - User profiles that determine what each user can or can't do, restricting the pages / services / options available (i.e. normal user can't delete etc)
    - Would it need some sort of session manager to allow multiple users etc?
    I appreciate this is a fairly open question but what is the easiest way to start implementing this? Not after specific code as I would prefer to try figger things out myself, but a point in the right direction would be great. It doesn't have to be extremely secure as this is just for me at the minute.
    I have spent all day looking at things like session data / url rewriting / security settings in web.xml / bespoke servlets and am now in java overload!

    Hi everyone,
    I've now actually gone back to the tutorial that I linked to above and implemented that using form login and j_security_check.
    Agree with Saish, and although I don't know enough about the other options to give a good reason, using realms and j_security_check just seems to be a bit cluncky and messy. I would also prefer something a bit more generic, that doesn't rely on setting users in glassfish, hence why I started with my own user table.
    Anyway, I will leave it as is for now and maybe come back and try one of the other options.
    The only problem I can see now is that to add users i will need to go through all the steps of adding users in glassfish and web.xml... Is there a way to do this through a servlet or something so I can have a jsp page to add users that also creats all the other bits for it to work?
    Thanks everyone for your help

  • Easiest way to sync 2 audio tracks - detect beats?

    I record bands using a camcorder and simultaneously record hi quality audio using a multi-track recorder.  My previous software automatically recognized that the audio tracks were similar and sync'ed them for me.  So far...  trying to sync my hi fidelity MP3 with the camcorder audio/video has been difficult.  I tried using "beat detect" but I don't see how to use that on 2 different audio tracks to sync them.  Once they are synched, I delete the camcorder audio and I am left with the same video with awesome audio.  What is the easiest/fastest way to sync 2 virtually identical audio tracks? 

    Thanks for the WAV file tip.  I zoom in as far as I can (unless I'm missing something) and I rarely see the waveform.  The attached graphic shows one of the tracks as a very "low resolution" waveform (I see no way to accurately line up tracks using this waveform).  I hoped to use "detect beats" on both tracks to, at least, get close.  Is there a way to expand the waveforms vertically so I can actually see the waves and align them?  I'm trying to align Audio 1 and Audio 2.  This is what I see:

  • I am using Iphoto 11 ver 9.4.3 on mac using oxs 10.8.5 i want to export calendar projects to an external hard drive. what is the easiest way to do this? i have tried export and import but it didn't seem to work.

    I am using Iphoto 11 ver 9.4.3 on mac using oxs 10.8.5 i want to export calendar projects to an external hard drive. my goal is to store them in an external hard drive so it doesn't use up memory on the mac hard drive. is it possible to copy the specific projects without copying the entire library? what is the easiest way to do this? i have tried export and import but it didn't seem to work.

    What do you not understand?
    You can duplicate the iPhoto library (command - D ) and delete everything except the project and its photos from the copy and move that
    Or
    However the calendar takes very little space - it is simpy database entries - it is the photos in the calendar that take space - and for most people you would wnat to keep those photos in your library
    you can use a photo in 50 calendars and it still is only one photo in your library - as I explained calenders do not exist as such - they are simply database entries telling iPhotop how to display the calendar - they take almost no space at all
    LN

  • Easiest (and best) way to stream video from iMac to TV

    All,
    Trying to look for the highest quality, easiest & least expensive ways to get HD video from my iMac to my TV.
    I could run wire - but that's sloppy, and a pain in the butt. Probably least expensive though.
    Could get a Mac mini - but that's expensive.
    Looking into getting a USB device (they sell them on TigerDirect.com) that beams the signal to a receiver - but they seem to be Windows based.
    I do have a PS3 & XBOX360, and I know there are some programs out there to do this, but I've never been satisfied with the quality - major stalling or streaming issues gumming up the entertainment.
    Can you folks weigh in with your tips, tricks or suggestions?
    Thanks.

    spidermains wrote:
    I could run wire - but that's sloppy, and a pain in the butt.
    how about *powerline adapters* _*such as these*_ ?
    Could get a Mac mini - but that's expensive.
    how about an TV ? there should even be refurbished units available from your local Apple online store.
    JGG

  • What is the easiest way to check for internet connection in C#?

    Hi!
    I searched a lot but I didn't get my answer. I'm looking for the easiest way to check for internet connection. Can you help me?
    Thanks a lot.

    Hi Pouya Ebrahimzadeh,
    I suggest you could connect a site to check if it can be opened.
    Public Shared Function CheckForInternetConnection() As Boolean
    Try
    Using client = New WebClient()
    Using stream = client.OpenRead("https://msdn.microsoft.com/")
    Return True
    End Using
    End Using
    Catch
    Return False
    End Try
    End Function
    If you have any other concern regarding this issue, please feel free to let me know.
    Best regards,
    Youjun Tang
    We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
    Click
    HERE to participate the survey.

  • What is the easiest way to create and manage very big forms?

    I need to create a form that will contain few hundred questions. Could you please give me some advise on what is the easiest way to do that? I mean for example is it easier to create everything in Word (since it is easier to manage) and than create a form based on that?
    My concern is that when I will have a very big form, containing different kinds of questions and with many scripts, managing it during work will be slow and difficult, for example adding a question in the middle of the form which would require moving half of the questions down which could smash the layout etc.
    What is the best practise for that?
    Thanks in advance

    Try using Table and Rows for this kind of forms. These forms will have the same look throught with a question and and answer section..
    In the future if you want to add a new section, you can simply add rows in between..
    Thanks
    Srini

  • What is the easiest way to open an application from Labview?

    I need to open an application from labview and depending on a user's selection, load one out of a group of files for the application that is opened. I need to know what is the best or easiest way to open an application and load a file that is used by the application based on a selection.

    Here is the response that I got from Cognex when I asked them about how to do this. Do you understand what they are talking about?
    In order to do something like this you will probably want to look into the Display Control/SDK for In-Sight. The Display Control gets installed along with In-Sight Explorer and includes a control that can be used in an environment like Labview to communicate with In-Sight sensors while the SDK is an enhanced version of the Display Control that gives you more control and functionality. I am not very familiar with the Labview environment so I will give some code snippets in VB.Net and hopefully you can adjust them as necessary. Specifically I see 3 possible avenues to do this:
     1) Using the Display Control you have access to many of the dialog boxes that are used in In-Sight Explorer including the Load Job dialog box. You can spawn this dialog box through a line of code similar to cvsInSightDisplay1.Edit.OpenJob.Execute(). I am not certain if the Labview environment will be able to spawn and display this dialog though. 2) With the addition of the SDK (additional purchase) you can directly access sensor properties including the job. There is a method called LoadJobFile to load jobs from on the sensor and LoadJobFileLocally to load jobs from the host machine. A typical line of code might be cvsInSightDisplay1.InSight.File.LoadJobFile("myjob1.job").3) If Labview cannot handle the dialogs and the SDK is not an option for you then you may still be able to do this using Native Mode commands. Native Mode commands are sent through a socket on the telnet port (typically port 23). Keep in mind that you will need to handle the username/password prompt and response when you first open the socket before issuing any Native Mode commands. The command to load a job file from the sensor would be the Load File command which would be a string similar to "LF myjob1.job". The Native Mode commands are documented in the In-Sight Explorer help file. 

  • Easiest and/or best methods for generating XML output (not with a report)

    Hi, several of our EBS customers (11.5.10) are converting their PDF reports to use XML/BI publisher to produce output. The data stream comes from a report that generates the XML output, and then the XML template is applied. This works great ... no problems, etc. From what I have read, however, Oracle intends to treat the traditional Forms and Reports Developers as legacy tools (although still supporting them, of course).
    My question is if I wanted to ditch using Reports to generate XML output, what, in your opinion or in your current usage, is the easiest way of getting this data? In Reports, the data modeler is excellent in providing a method to write your queries, split them into different repeating groups, write formula and summary columns, link multiple queries, etc, etc. If one were to become Reports Developer free, what comparable tools are available to take its place? I would expect this tool to handle a mix of GUI and coding like the Reports data modeler. Please note that I'm not looking for an EBS-specific solution -- say for a custom application using regular Oracle 10g DB and iAS, with BI Publisher for reporting.
    Thanks for your feedback,
    Ryan

    What I'm looking for is to not use Oracle Reports to generate the XML data output since Oracle's statement of direction is pushing BI Publisher rather than Oracle Reports as the preferred tool for reporting. That said, the data modeler in Reports provides a very flexible tool to construct and link multiple queries and to manipulate the queries into several levels of a master/detail relationship. Further, the mix of GUI and coding makes setting up the data model a lot more efficient. What I'm looking for (and I don't know if anything exists) is something comparable that can be used to generate XML output from the DB -- the idea being that I wouldn't use legacy tools, like Reports, for this task. I hope that is clearer.
    Really, another way of answering my question is, aside from Reports and the APIs mentioned so far, what are my fellow developers using, if anything, to extract XML data in a way that handles the features i list above?

  • I want to use 1 itunes account but with 3 different iphones 2 for the kids and one for me, what is the easiest way to do that?

    I want to use 1 itunes account but sync 3 different iphones, 2 for the kids and 1 for me.  So I would like to have different programs, songs, apps etc for each phone.  What is the easiest way to do that

    Agreed heather. Also, if you have three users on the same account how do you keep phone calls and messages from going to all three phones?

  • I created two iTunes libraries on my mac mini and would like to merge them into one library. What is the easiest way to do this?

    I created two iTunes libraries on my mac mini back in the day. I would like to consolidate them into one iTunes library. What is the easiest method to do this? I do use i-Match to access all my music from  iCloud, if that makes any difference.  Thanks. Mark

    Thanks for the reply. When I created the 2 libraries years ago I would hold down the options key and had 2 library names to choose from. Now it just shows a lot of files when I do that, With over 7,000 songs I think I will just look for the few songs from the original library I used to use that still interest me, if they don't show up in my default current library. Thought there would be any easy was to integrate all my music files into one library. I am definitely not going to spend days manually doing this, but thanks again.

  • I have a new laptop and want to transfer my itunes music across from the old one. What's the easiest /quickest method?

    I have a new laptop and want to transfer my itunes music across from the old one. What's the easiest /quickest method?

    Refer to this article:
    iTunes: Back up your iTunes library by copying to an external hard drive
    http://support.apple.com/kb/HT1751

  • I have a mid year 2007 24 inch iMac and will be purchasing a new 27 inch Retina iMac, what is the easiest way to transfer the data and files from my old machine to the new one?

    I have a mid year 2007 24 inch iMac and will be purchasing a new 27 inch Retina iMac, what is the easiest way to transfer the data and files from my old machine to the new one?

    Following up on this thread,
    I have a new iMac on the way and my current is from 2008, never had a problem but I am sure there are internal issues that I would prefer not to transfer.
    I have no issues other then the slowness in certain programs and that is the main reason to buy a new one.
    Programs like numbers and pages seem to take a longer time to open after I update to Yosemite.
    I only use 272GB of 500 GB, my memory is 4GB and I am upgrading to 8Gb and bought the 4.0 processor.
    Question:
    Is there a way to manually transfer items or would that be a waste of time in that if there are issues they could be anywhere and would transfer anyway?

  • What is the easiest way to burn imovies onto DVD's.   I want to burn more than one movie onto DVD as I create.    Can I continue to burn onto the same DVD as the movies are created?

    What is the easiest way to burn my imovies onto DVD's?    I want to burn movies as I create them and then continue to add more movies to the same DVD as the years go by -- until the DVD is full!    Is this possible?

    You might also want to post this in the iMovie forum https://discussions.apple.com/community/ilife/imovie

  • What is the easiest way to transfer a large imovie project from one computer to another in a different location.

    What is the easiest way to transfer an faairly large HD imovie project from one computer to another in a different location. Can you export to drop box? Will the other computer need the exact imovie version?

    OK it depends.
    If you have a finished movie, you can SHARE/EXPORT MOVIE and create your final movie. Then, depending on the size of the finished movie, you can transfer via dropbox or similar service. Ninety minutes is a very long movie for iMovie, but it may work for you. I would suggest 720P to keep the size down.
    If you need to transfer the entire iMovie Project so it can be edited in iMovie at the other end, then you need to transfer the project and event assets to an external hard drive and get the hard drive to the other location.
    Directions are here. Follow the directions for 1) Moving or copying Project to external drive. Then 2) Consolidate Media.
    https://discussions.apple.com/docs/DOC-4141

Maybe you are looking for

  • ECC 6.0 Purchase Order Smartforms

    Dear all,   I know the standard PO smartform and print program are:   Smartforms: /SMB40/MMPO_L   Print Program: /SMB40/FM06P But i can't find them in my ECC 6.0 system.  Any suggestion?? Regards, Kit

  • CM 5.2.1 upgrade

    Tride to do the 5.2.1 upgrade tonight. Had shut down all services and ran the update. But it failed with Services still locked. Canclelled the upgrade but the logs do not show the files which are locked. Has any one experienced a similar issue. Thank

  • Why am I Unable to Wipe gifted iPhone 4?

         I gifted my iPhone 4 to my granddaughter. Prior to gifting, I removed the Passcode option to allow her to use it freely. I then began to remove all personal information manually, which made me realize there had to be another way. I researched ot

  • Setting Destination URI of a Pie Chart Graph Programatically-OA Framework

    Hi All, I have created a OF Page with the following Regions one under the other: 1. PageLayoutRN 2. HideShowHdr1 - Hide/Show Header 3. TblLayout1RN - Table Layout 4. Tbl1RowLayout1RN - Table Row Layout 5. Row1CellFormat1RN - Cell Format 6. Row2CellFo

  • Missing controls in Develop module - crop etc

    They were there a couple of days ago but for the last few sessions the group of controls (including crop etc) that sit under the main image in the Develop module have gone missing. I've been playing with the 'view' options without success and it seem