User Profile

Collapse

Profile Sidebar

Collapse
robtyketto
robtyketto
Last Activity: Apr 2 '08, 12:01 AM
Joined: Nov 23 '06
Location:
  •  
  • Time
  • Show
  • Source
Clear All
new posts

  • robtyketto
    started a topic Flash MX: Date conversion from String to Date

    Flash MX: Date conversion from String to Date

    Greetings,

    I'm using MDMZinc to insert/update records into an MSAccess database, many headaches have been caused by dates.

    Apparently the best method to avoid complication is to record date stamp as a numeric value, which i have done using the flash getTime() function (see below):-

    Code:
    var my_date:Date = new Date();
    var quiznumberdate = my_date.getTime();
    
    mdm.Database.MSAccess.runQuery("INSERT
    ...
    See more | Go to post

  • robtyketto
    started a topic Jsp: Exception handler issues
    in Java

    Jsp: Exception handler issues

    Greetings,

    I'm a newbie to jsp/java so apologies if this request seems trivial.

    I have two forms (separate .jsps) which are used to manipulate database records, one adds a record the others update an existing record.

    As all fields on the HTML form are text I need to ensure those fields that should be integer values are validated, therefore I include an errorpage (The form action is used to call .jsps needed...
    See more | Go to post

  • SOLVED.

    Used the alert component.

    Cheers
    Rob
    See more | Go to post

    Leave a comment:


  • robtyketto
    started a topic Flash Mx Pro 2004: Message box "Yes/No" prompt

    Flash Mx Pro 2004: Message box "Yes/No" prompt

    Greetings,

    For my DESKTOP application I have more than one exit button where I would like the user to be prompted to confirm they really wish to exit.

    Much like in VBA with msgbox VbYesNo functionality.

    I haven't got a message box within my installed components at the moment. I've seen fscommand("mess agebox") functionality mentioned to, I assume this is more webpage/server side orientated though....
    See more | Go to post

  • Bump, any advice (I've use this method before for connections choices) ?
    See more | Go to post

    Leave a comment:


  • JSP: Differing Prepared statements based on if/else logic

    Greetings,

    Im struggling with the very simple task of having TWO different prepated statements based on a string value (code below)


    Code:
    if(userSelectedCategory != null) {
    
    		PreparedStatement myFAQStatement = null, myFAQStatement1 = null, myFAQStatement2 = null;
    
    		if (userSelectedCategory == "ALL categories") 
    		{ 
    			PreparedStatement myFAQStatement1 = conn.prepareStatement("SELECT
    ...
    See more | Go to post

  • robtyketto
    replied to Access/Jet SQL: Date/time issues
    Heres where I am right now with the problem and hopefully a clearer explanation of the current problem:-

    I've written an application which stores the users name and current date.

    In flash I've formatted a STRING with the date format of "mm/dd/yyyy hh:mm:ss" i.e. American Format

    This STRING is then stored into the database without problems in a DATE/TIME field as "dd/mm/yyyy hh:mm:ss' as...
    See more | Go to post

    Leave a comment:


  • robtyketto
    replied to Access/Jet SQL: Date/time issues
    Thanks for the speedy reply.

    When I was storing the dates in UK format in the database I could run the update query in Access with UserName and Date parameters without ANY problems with SINGLE QUOTES or #.

    Since I changed the textDate within Actionscript and printed it out to american format "mm/dd/yyyy hh:mm:ss" I assumed it would be stored in the database in this way as I simply insert this String as is to...
    See more | Go to post

    Leave a comment:


  • robtyketto
    replied to Access/Jet SQL: Date/time issues
    Thanks for the reply.

    I amended my actionscript code and now the date is stored as "mm/dd/yyyy hh:mm:ss" which populates the DATE/TIME field (QuizDate) in the access database.

    TextDate is a string in actionscript which is used to successfully insert the QuizDate into the table as "mm/dd/yyyy hh:mm:ss"

    When I want to update the table based on field Username and Date it goes horribly...
    See more | Go to post

    Leave a comment:


  • robtyketto
    replied to Access/Jet SQL: Date/time issues
    It appears ok with UK dates it doesnt like the time format for some reason.

    Code:
    mdm.Database.MSAccess.runQuery("UPDATE UserOverallResults SET Results = 10 WHERE UserName = 'Rob' AND quizDate = #19/02/2008# ");
    That code above runs without errors, when introducing time hh:mm: or hh:mm:ss it all goes wrong :-(
    See more | Go to post

    Leave a comment:


  • robtyketto
    started a topic Access/Jet SQL: Date/time issues

    Access/Jet SQL: Date/time issues

    Greetings,

    I'm using Flash MX connecting to an MS Access database via JET.

    I've stored dates using Flash/Jet into my database as 'dd/mm/yyyy hh:mm:ss' into a DATE/TIME field.

    However I can't update because of the WHERE clause as I am not specifying the date correctly. I believe syntax wise I need to use # and specify it in american format mm/dd/yyyy hh:mm:ss.

    I have the code below working...
    See more | Go to post

  • robtyketto
    started a topic JSP - Setfocus on HTML controls
    in Java

    JSP - Setfocus on HTML controls

    Greetings,

    From googling it appears JSP cannot allow you to setfocus on HTML controls, I just wanted to check on this forum if this was the case or not?

    Thanks by the way for everyone who's helped me over the last few days, All the functionality I required is working great and now am spending time to review my code (add comments, formmating etc..,)

    Thanks again
    Rob
    See more | Go to post

  • Ok Ok I now have all my jsp working.

    I will now take the time to add appropriate comments, naming and formatting conventions.

    Deadlines for uni meant I had to cut corners, but now I have time to sit down and properly review my code.

    Your advice hasn.t fallen on deaf ears.

    Thanks
    Rob...
    See more | Go to post

    Leave a comment:


  • Thanks for the reply I've fixed the code errors.

    The code offers very little functionality at the moment as Im trying to build it up piece by piece so I can understand whats going on.

    I was advised that the OnChange event would pass in the users selection and not re-populate the Option box.

    I didnt see how this would work as I thought the Onchange would simply run all of the JSP again, Is this the case...
    See more | Go to post

    Leave a comment:


  • Code:
     if (request.getparameter("OptionCategoryValue") == null)
    should be getParameter

    Now I get error message :-



    Can any assist or offer advice, is it clear what I want to achieve overall?...
    See more | Go to post

    Leave a comment:


  • JSP - Onchange Event - Logic problems refreshing selection

    Greetings,

    I'm slowly building up code to do the following:-
    • Display TWO selection option boxes (cascading).

    • If the FIRST selection option box changes then reload the jsp using onchange event (not changing the option box value on relaod i.e. not re-running the SQL query).

    • ONLY on initial entry should the form FIRST selection option box should be populated using JDBC SQL.

    • The SECOND selection option box can
    ...
    See more | Go to post

  • I dont BELIEVE IT !!!

    I didnt execute my query thats why there was no visible results.
    Code:
    mystatement.executeUpdate();
    Point taken if i enter GJGJ on the form though, I will look at adding better error handling in.

    Thanks
    Rob
    See more | Go to post

    Leave a comment:


  • Ahh I was thinking that, Ive seen quite a few examples on the web that contradict each other regarding INPUT type but assumed it was always TEXT.

    Ok, should this code pass the value of Id as an Int now though?

    Code:
    java.sql.Statement statement = conn.createStatement();
                String myquery ="DELETE * FROM FAQ WHERE Id = ? ";
                PreparedStatement mystatement = conn.prepareStatement(myquery);
    ...
    See more | Go to post

    Leave a comment:


  • JDBC SQL: No errors, but problems with string to Integer conversions

    Greetings,

    I'm a newbie to Java and I cant quite get my head around why it seems most integers appears to be formatted as strings and then later have to be parsed.

    The code below, passes in the autonumber table field Id value named faqId which in the HTML code the Input type is "Int"

    Code:
    <FORM NAME ="deletefaqs" ACTION="wk465682DeleteFAQbean.jsp" METHOD="POST"><PRE>
    ...
    See more | Go to post

  • robtyketto
    replied to Prepared statement setup incorrectly?
    in Java
    Thanks BigDaddyLH !!!!!

    I'm getting my head round it all now.

    Resolved my problem :-)
    See more | Go to post

    Leave a comment:

No activity results to display
Show More
Working...