Alpha Video Training
Page 3 of 3 FirstFirst 123
Results 61 to 78 of 78

Thread: Form change when copying from one computer to a second computer

  1. #61
    "Certified" Alphaholic Tim Kiebert's Avatar
    Real Name
    Tim Kiebert
    Join Date
    Jul 2004
    Location
    Geelong, Victoria, Australia
    Posts
    2,785

    Default Re: Form change when copying from one computer to a second computer

    We always do that when you post Mike.

    Sure edit your post. Now no one knows what I am talking about. But that may be normal anyway. :-)
    Last edited by Tim Kiebert; 11-09-2014 at 10:57 PM.
    Tim Kiebert
    Eagle Creek Citrus
    A complex system that does not work is invariably found to have evolved from a simpler system that worked just fine.

  2. #62
    "Certified" Alphaholic Mike Wilson's Avatar
    Real Name
    mike wilson
    Join Date
    Apr 2005
    Location
    Grand Rapids, Michigan
    Posts
    4,200

    Default Re: Form change when copying from one computer to a second computer

    Ha, Tim.... I snuck in and changed "ignore" to what's there now. But thanks for the confidence booster anyway.
    Mike W
    __________________________
    "I rebel in at least small things to express to the world that I have not completely surrendered"

  3. #63
    "Certified" Alphaholic MoGrace's Avatar
    Real Name
    Robin
    Join Date
    Mar 2006
    Location
    Los Angeles
    Posts
    3,698

    Default Re: Form change when copying from one computer to a second computer

    Quote Originally Posted by Mike Wilson View Post
    I think a screenshot of your code tab on the control panel would satisfy Robin's question.
    You'd think! Something is wrong here for sure, could be the shortcut, a typo or some setting or preference. It would take a phone call to help him figure it out...and perhaps a dozen screenshots in the meantime!
    Robin

    Discernment is not needed in things that differ, but in those things that appear to be the same. - Miles Sanford

  4. #64
    Member
    Real Name
    adcooke
    Join Date
    Feb 2008
    Posts
    47

    Default Re: Form change when copying from one computer to a second computer

    Robin: Re naming of script – definitely named “ autoexec ” (all lower case, no extension).
    Arthur

  5. #65
    Member
    Real Name
    adcooke
    Join Date
    Feb 2008
    Posts
    47

    Default Re: Form change when copying from one computer to a second computer

    Hi guys,

    After Ray’s message (#56) yesterday (around 6-7pm my time), I bit the bullet and went into Debug for the first time ever. Had purchased the day before and downloaded from Liberty Manuals, Susan Hussey Bush’s manual on A5ver11 and XBasic Toolkit. If there’s something better, please let me know.

    So jumped in and followed the instructions therein to implement Debug – ie put debug(1) at start and debug(2) at end of current autoexec script. Closed A5 and restarted, and the autoexec obviously ran because it started and opened the Debug window/program. I then added each line to the watch window, but what it produced didn’t mean much to me so couldn’t really interpret what was going on. I closed and reopened a few times to the same debug window, and again added each line to the watch window, and each time it produced different info re the same line in the watch window from previous attempts. So that completely lost me. It did though correctly pick up and show “ADC-TOSHIBA-PC” as “machname” when I stepped or traced through.

    I then printed out Debug from the A5 Help file. But after what by then had been a day of it, my brain just refused to go anymore, and couldn’t face reading it, so I just shut down and went to bed.

    Its now 2:30pm next day and I had to work this morning, and just now checked the message board again and saw all the messages after Rays, and on into page 3. So please excuse my not replying to those later messages till now. I will now reply to each one.

    Many thanks again to all
    Arthur

  6. #66
    Member
    Real Name
    adcooke
    Join Date
    Feb 2008
    Posts
    47

    Default Re: Form change when copying from one computer to a second computer

    Hi Preston (message #57), will try that and let you know.
    thanks
    Arthur

  7. #67
    Member
    Real Name
    adcooke
    Join Date
    Feb 2008
    Posts
    47

    Default Re: Form change when copying from one computer to a second computer

    Thanks Dave (message 58), I've reset both Startup Form, and Display Control Panel prefereneces to YES.

    Later Edit - made no difference - still went straight to CP

    Will also try you other suggestions and let you know.

    Arthur

  8. #68
    Member
    Real Name
    adcooke
    Join Date
    Feb 2008
    Posts
    47

    Default Re: Form change when copying from one computer to a second computer

    Further reply to Preston (message #57)

    Created new autoexec with your suggested script as follows:

    'Date Created: 10-Nov-2014 03:08:50 PM
    'Last Updated: 10-Nov-2014 03:24:04 PM
    'Created By : ADC
    'Updated By : ADC
    'Set variables
    dim global vc_startform as c
    dim global machname as c
    'Get Machine Name
    machname = API_GETMACHINENAME()
    'Set startup form
    if machname = "ADC-TOSHIBA-PC" then
    vc_startform = "CWSmall Clnt Simple set"
    else
    vc_startform = "CWSmall set for eMachine"
    end if
    'Open startup form
    form.view(vc_startform,"","","","","")
    'Hide the Control Panel.
    ':controlpanel.hide()

    Unfortunately still went straight to control panel, wheter starting from icon or Programs>Alpha.exe.
    Also blocking out with leading ' the 3rd last line "form.view", produced the same result - straight to CP

    thanks
    Arthur

  9. #69
    "Certified" Alphaholic DaveM's Avatar
    Real Name
    Dave Mason
    Join Date
    Jul 2000
    Location
    Hudson, FL
    Posts
    6,026

    Default Re: Form change when copying from one computer to a second computer

    zipped. try this? It works excellent on my computer and v12.

    alltesting.zip
    it is complete with alltesting folder.

    I subbsituted your computer name after I tested my own computer name. "ADC-TOSHIBA-PC"
    Last edited by DaveM; 11-10-2014 at 01:40 AM.
    Dave Mason
    dave@aldausa.com
    Skype is dave.mason46

  10. #70
    Member
    Real Name
    adcooke
    Join Date
    Feb 2008
    Posts
    47

    Default Re: Form change when copying from one computer to a second computer

    Hi All.

    Just after my most recent posts, a message came through from Al Buckholtz to
    hook up with him right then and there (11:30pm his time), so I took up his
    offer. We talked plus he took control of my computer and worked on it
    remotely.

    I also had messages offering direct phone help from Tim (also here in Australia), and Mike in US.

    After almost an hour of working on it, Al finally found the problems, and got things working as expected.

    The final autoexec ended up being this:

    'Date Created: 09-Nov-2014 04:14:08 PM
    'Last Updated: 10-Nov-2014 05:11:54 PM
    'Created By : ADC
    'Updated By : ADC
    controlpanel.Maximize()
    dim global machname as c
    machname = API_GETMACHINENAME()
    if "ADC-TOSHIBA-PC" $ machname then
    :form.view("CWSmall_Clnt_Simple_set")
    else
    :form.view("CWSmall_set_for_eMachine")
    end if


    However prior to ending up with the above, he went to the Workspace Properties Startup panel, and deselected the “Maximise the control panel (within the Alpha Five window), which I had set to ‘selected’ (ie ‘on’).

    He then placed the “controlpanel.Maximize()” command at the start of the autoexec.

    He also took all spaces out of the form name titles, and replaced with “ _ “ underscore.

    He also added colons in front of the “form.view” commands.

    Plus we upgraded A5 on the Toshiba to the latest available patch/build for ver 11.

    Restarted A5 from Icon on Toshiba, and it opened up right through to the right form.

    WHEW!!

    Then to complete the picture, upgraded A5 on the eMachine (second computer) to latest patch/build, plus restored database onto the eMachine, obviously including new autoexec and other settings.

    Restarted A5 from Icon on emachine, and it opened up right through to the right form ie the shrunk/smaller form for that computer/screen – which caused all this in the first place!!! - ??? ***@@@###.


    So - HALLELUJA – SUCCESS - thank God its over !! What an incredible journey!!


    So a very big sincere THANKS to you all who spent so much time racking their brains, offering incredible assistance, and spending so much of your personal time to help me. What a saga it turned out to be !!!

    But what an amazing amazing community of A5 people!!!

    Many many thanks again to all.

    Arthur

  11. #71
    Member
    Real Name
    adcooke
    Join Date
    Feb 2008
    Posts
    47

    Default Re: Form change when copying from one computer to a second computer

    Many thanks Dave for zip file (message 69), but as you can see from my previous post, all now fixed.
    Best regards
    Arthur

  12. #72
    Volunteer Moderator
    Real Name
    Alan Buchholz
    Join Date
    Oct 2000
    Location
    Delavan, Wisconsin
    Posts
    9,626

    Default Re: Form change when copying from one computer to a second computer

    Arthur

    Thank you for your patience with this.

    Triage was a little slow after a Packer/Bear game.

    I first noticed that while the controlpanel was in focus and the form was open in the background.

    The ultimate problem was a timing issue with the autoexec opening a form and the database properties maximising the controlpanel.

    By moving both of the processes to the autoexec the issue was resolved. Possibly by hiding the controlpanel the opened form would have been in focus too.

    Then to switch up completely, I had previously(post 17 of 70 some) recommended that you consider the floating objects concept found here. http://wiki.alphasoftware.com/~alpha...+with+the+Form - maybe for the next form

    Yes we have quite a good group in our community here. Many distributed brains result in most problems getting solved.
    Al Buchholz
    Bookwood Systems, LTD
    Weekly QReportBuilder Webinars Thursday 1 pm CST

    Occam's Razor - KISS
    Normalize till it hurts - De-normalize till it works.
    Advice offered and questions asked in the spirit of learning how to fish is better than someone giving you a fish.
    When we triage a problem it is much easier to read sample systems than to read a mind.

  13. #73
    Member
    Real Name
    adcooke
    Join Date
    Feb 2008
    Posts
    47

    Default Re: Form change when copying from one computer to a second computer

    Hi Al and all,

    Al also noticed that the form name tag at the bottom of the screen when the forms were displayed, had underscores "-" between the words (CWSmall_Clnt_Simple_Set), whereas the form names when viewed on the control panel did not have underscores, and just had spaces between the words(CWSmall Clnt Simple Set). So he changed the latter to include underscores and took out the spaces - which could have been creating a problem or not, but we don't really know, but changed it anyway just to be safe.

    So Unless one were looking at the screen to notice, such a problem would likely never be picked up or considered - especially if it was creating a problem. Good spotting Al.

    Many thanks again to all
    Arthur
    Last edited by adcooke; 11-10-2014 at 07:11 PM.

  14. #74
    "Certified" Alphaholic DaveM's Avatar
    Real Name
    Dave Mason
    Join Date
    Jul 2000
    Location
    Hudson, FL
    Posts
    6,026

    Default Re: Form change when copying from one computer to a second computer

    Naming conventions say: No spaces in names. That in part is to prevent "possible" errors in execution. That goes for field names, file names and any other name in MY personal book.
    Last edited by DaveM; 11-10-2014 at 09:30 PM.
    Dave Mason
    dave@aldausa.com
    Skype is dave.mason46

  15. #75
    "Certified" Alphaholic MoGrace's Avatar
    Real Name
    Robin
    Join Date
    Mar 2006
    Location
    Los Angeles
    Posts
    3,698

    Default Re: Form change when copying from one computer to a second computer

    Quote Originally Posted by Al Buchholz View Post
    Arthur

    Thank you for your patience with this.

    Triage was a little slow after a Packer/Bear game.

    I first noticed that while the controlpanel was in focus and the form was open in the background.

    The ultimate problem was a timing issue with the autoexec opening a form and the database properties maximising the controlpanel.

    By moving both of the processes to the autoexec the issue was resolved. Possibly by hiding the controlpanel the opened form would have been in focus too.

    Then to switch up completely, I had previously(post 17 of 70 some) recommended that you consider the floating objects concept found here. http://wiki.alphasoftware.com/~alpha...+with+the+Form - maybe for the next form

    Yes we have quite a good group in our community here. Many distributed brains result in most problems getting solved.
    Good catch on the timing issue!

    It only goes to show that great minds think alike post 6
    Robin

    Discernment is not needed in things that differ, but in those things that appear to be the same. - Miles Sanford

  16. #76
    "Certified" Alphaholic Mike Wilson's Avatar
    Real Name
    mike wilson
    Join Date
    Apr 2005
    Location
    Grand Rapids, Michigan
    Posts
    4,200

    Default Re: Form change when copying from one computer to a second computer

    Interesting. I did think about normalizing all the names using remspecial() to relieve any of the possible issues that these hyphens, underscores and space might be introducing. That and alltrim() are sometimes a life savers for uncovering value disconnects that you believe should absolutely be true.
    Mike W
    __________________________
    "I rebel in at least small things to express to the world that I have not completely surrendered"

  17. #77
    Member preston2's Avatar
    Real Name
    Preston
    Join Date
    Nov 2011
    Posts
    764

    Default Re: Form change when copying from one computer to a second computer

    Quote Originally Posted by adcooke View Post
    Further reply to Preston (message #57)

    Created new autoexec with your suggested script as follows:

    'Date Created: 10-Nov-2014 03:08:50 PM
    'Last Updated: 10-Nov-2014 03:24:04 PM
    'Created By : ADC
    'Updated By : ADC
    'Set variables
    dim global vc_startform as c
    dim global machname as c
    'Get Machine Name
    machname = API_GETMACHINENAME()
    'Set startup form
    if machname = "ADC-TOSHIBA-PC" then
    vc_startform = "CWSmall Clnt Simple set"
    else
    vc_startform = "CWSmall set for eMachine"
    end if
    'Open startup form
    form.view(vc_startform,"","","","","")
    'Hide the Control Panel.
    ':controlpanel.hide()

    Unfortunately still went straight to control panel, wheter starting from icon or Programs>Alpha.exe.
    Also blocking out with leading ' the 3rd last line "form.view", produced the same result - straight to CP

    thanks
    Arthur
    Looking at the code you posted, you commented out the :controlpanelhide() so it would not have run that command. Not sure if I posted it that way or not.

    Also, I never use the "Startup Form" settings. I always specify which form to start up with in the autoexec script. This is especially true if you are needing to use different startup form based on conditions.

  18. #78
    "Certified" Alphaholic Mike Wilson's Avatar
    Real Name
    mike wilson
    Join Date
    Apr 2005
    Location
    Grand Rapids, Michigan
    Posts
    4,200

    Default Re: Form change when copying from one computer to a second computer

    I thought I would throw this script out for folks to see that I worked from a beginnings from Peter Wayne. It is not exactly the solution desired here but might resolve someones screen size issues by having an efficient and dynamic way to change screen resolution.
    Attached Files Attached Files
    Mike W
    __________________________
    "I rebel in at least small things to express to the world that I have not completely surrendered"

Similar Threads

  1. V11 and 10.5 on the same computer and copying a project
    By ssmoore1 in forum Application Server Version 11 - Web/Browser Applications
    Replies: 1
    Last Post: 09-28-2012, 03:47 PM
  2. Replies: 2
    Last Post: 10-11-2008, 11:20 AM
  3. New Computer
    By Jim Lightburn in forum Alpha Five Version 5
    Replies: 3
    Last Post: 09-01-2005, 03:24 PM
  4. Have new computer, am I doing this right?
    By Daniel Earley in forum Alpha Five Version 5
    Replies: 2
    Last Post: 06-14-2003, 10:16 AM
  5. Forum Change! Or is it my Computer?
    By Bob Elliott in forum Alpha Five Version 4
    Replies: 5
    Last Post: 03-04-2002, 08:24 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •