Mahmoud Hadad

Ranch Hand
+ Follow
since Jan 09, 2006
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Mahmoud Hadad

hi evreyone,
guys i have this problem, when i try to use the method calendarObj.getDisplayName(calendarObj.get(Calendar.DAY_OF_WEEK), Calendar.LONG, new Locale("ar"));
this does return null. the method implementation is said to have localized names for Calendar fields that DateFormatSymbols API have. anyway when i have run the following code:
DateFormatSymbols dfsObj = DateFormatSymbols.getInstance(new Locale("ar"));
String[] days = dfsobj.getWeekDays();
when i printed out the contents of the days array, i have seen the day names in arabic. so how come the Calendar method returns null and the DateFormatSymbols API return the names in arabic?
[ October 17, 2006: Message edited by: Mahmoud Hadad ]
17 years ago
ok the problem is solved by using the method jTableObj.prepareEditor but still the text gets an orientation from left to right and not getting from right to left although i used the method textField.applyComponentOrientation(ComponentOrientation.RIGHT_TO_LEFT) in the getTableComponent method, any hints?
[ October 09, 2006: Message edited by: Mahmoud Hadad ]
17 years ago
hi evreyone,
i want to know how can i change the Orientation of my text from LEFT_To_RIGHT to RIGHT_TO_LEFT in JTable Cell's when editing. i have extended AbstractCellEditor and implemented TableCellEditor
and when i implemented getTableCellEditorComponent i used the method textField.setComponentOrientation in it, the text when editing is at right but the cell is not getting edited that is after i press F2 in the cell being edited. i have extended DefaultCellEditor and overrided setClickCountToStart and getClickCountToStart to zero but the cell is not getting edited till i press F2 too. i want to have my text in any cell in JTable to be right aligned when editing without pressing F2 to start editing, any hints?
i did implement my own Cell Editor and have extended JTextArea

[ October 09, 2006: Message edited by: Mahmoud Hadad ]
[ October 09, 2006: Message edited by: Mahmoud Hadad ]
17 years ago
hi evreyone,
when i try to delete a record or records using JDBC:ODBC bridge the record does not get deleted till i make a duplicate of that statement(as i think it might be because Access makes a confirmation before it deletes any record ) and the executeUpdate method returns the row count of the selected records. anyway when i was deleting from my JTable i first deleted the record from my resultset that was obtained by a SELECT statement in my java pp then deleted it from the DB so it got deleted right away iside my java application, so does deleting record(s) from a resultset that is retrieved using a Statement object generates a DELETE SQL Statement to the db ?
[ October 07, 2006: Message edited by: Mahmoud Hadad ]
thanks for the reply, well when i made a connection to my sql server 2005 db it gave an error which was ClassNotFoundException No Suitable Driver Found, the solution was to enable something called SQL Server Browser inside the Configuartion Manager in SQL Server 2005 and enabling TCP/IP in the Network Configuration so all of these things were done inside SQL Server 2005 so i can get a Connection object from the DriverManager and as i understood from a post from someone from Microsoft that JDBC connects to SQL Server 2005 DB via TCP/IP only. so should my users install the whole SQL Server 2005 in order to use my App?
my Application does not connect to a remote DB ,it connects to a DB that comes with my App only.
[ September 29, 2006: Message edited by: Mahmoud Hadad ]
i have an SE application that will be connecting to a SQL Server 2005 DB. At first a problem about the Driver arised when using Microsoft JDBC Driver( the problem was solved by enabling SQL Server Browser and enabling TCP/IP under Network Configuartion).the fix was inside SQL Server 2005 so does my user's need to install the whole SQL Server 2005 in order to use my App which will only be connecting to a SQL server 2005 DB on their local machines ?
[ September 29, 2006: Message edited by: Mahmoud Hadad ]
sorry i need to understand this well because the decision to learn UML will take some time. so you are telling me to UML diagram my Application's (the key concepts logic behind it without diagramming code specific actions, i mean i should not diagram evrey class with it's attributes and methods and the way they work in sequence)? and as for writing code and diagramming what should i do exactly (do both in a spearate controlled way so i don't get lost in either UML diagrams nor code, i should code and do UML diagrams in a separate way)?
thanks again for the reply
[ September 28, 2006: Message edited by: Mahmoud Hadad ]
my experience was that once i have coded a whole project alone, anyway after a while when i wanted to make an update of it i took a week or less to remember how it used to work so i've done similar diagrams that looked like UML on paper.this is why i'm learning UML frankly. as for documenting my code it was not easy too to remember how my methods should work in sequence. and i do prefer thinking about the whole project before typping code then after i start coding i go back and change my idea about the application analogy(i think evreyone does that?), but isn't there a better way to visualize the whole project before wasting time between reverse feedback and re-design?
thanks for the reply, i have seen some hands-on labs for UML and netbeans so i'm trying to get use of them, anyway what i'm looking for is UML code generators and reverse enginiering UML model (source-code to UML?), i awnt to start plotting the whole project in diagrams before starting to write code. i couldn't understand what is whiteboard-capture tools, UML-specific drawing tools, printing tools, document repository and versioning tools is about?
i've been trying to learn UML from an O'Reily book called Learning UML anyway i have found the book is all about teaching the standard without putting concepts into a real use using a sepcified tool. anyway i want a name for a book that handles UML and java using a specified tool or any other good recomendation (i use netbeans as my IDE)
[ September 26, 2006: Message edited by: Mahmoud Hadad ]
well i have changed Regional Options in Regional Settings in Control Panel to match an arabic country and an arabic prefrences and it made the JVM render the arabic characters correctly but what if my user will be outside an arabic country and he does not wish to change his regional settings, is there anyway i can render the arabic text for example although he have pre-installed arabic in his os but his regoinal and language settings are not set to any arabic matching country
17 years ago
my operating system has an arabic command prompt window, it's not an MS-DOS problem or an operating system problem i think as the DB problems was in GUI mode, although i have arabic installed in my system but the JVM is working in a mysterious way, i have used Arabic Transperent font in my GUI App but my data was not rendered correctly
17 years ago
hi evreyone,
i had alot of problems in displaying arabic text either when getting them from a DB query, storing them and even printing some arabic text to the console.the problem was that i could write arabic using netbeans in my code but when i try to System.out.printlnt(arabicStrObj) it prints ???.after trying many siviral times it showed the text while i did not change anything neither in my system nor in my coce.the system default is english but i have arabic installed, i'm using Windows XP sp2
the default encoding printed is Cp1256
when i tried to print a Greek letter the JVM rendered it as ?, what does it mean that the JVM supports Unicode and my system(Windows xp sp2) has the installed fonts for representing the glyp of those Unicode Characters but they do not get rendered correctly?
17 years ago
don't know i'm enrolled in a SQL Server 2005 course and i'm not so sure that SQL Server 2005 is what i will be looking at if i wanna make something related to Decision Support Systems and RFID devices.so i'm really confused with these DBMS products :
DB2 and Oracle .
so can anyone who have done something related to Descision Support Systems or anyonw experienced with the above products tell me about their experience .
i will be interfacing my DB from any java framework.probablly SE.
thanks.
[ August 17, 2006: Message edited by: Mahmoud Hadad ]
17 years ago
i have the number of characters that i got from making a comparison between some String objects on which one of them have the biggest characters but i do not have the original String .what i want to do originally is to resize my JTable columns automatically to fit to my field's text automatically ,so how this is done in java ?i think i tried to keep my approach simple but things got complicated by time.
thanks for the reply.
17 years ago