Announcement

Collapse
No announcement yet.

Invalid win32 Application in Windows2000

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Invalid win32 Application in Windows2000

    Hi guys,


    I proudly shipped my latest and greatest only to have the user tell me under win2000 he gets the error message:


    Myapp.exe "is not a valid Win32 Application!"


    Where do i start?

    PS testing the code HTML instruction
    Code:
    FUNCTION PBMAIN
    LOCAL TmpAsciiz AS ASCIIZ*255
    CALL GETMODULEFILENAME(BYVAL 0&, TmpAsciiz, SIZEOF(TmpAsciiz))
    CHDIR LEFT$(TmpAsciiz, INSTR(-1, TmpAsciiz, "\")) ' Change Directory to the one this app resides in
        AppName = " Convert"
        DIALOG NEW 0 , "", , , 200, 100, %WS_POPUP OR %WS_DLGFRAME TO sDlg ' Splash Screen
        DIALOG SHOW MODELESS sDlg CALL SplashScreen
        SLEEP 500
            Wdth = 110 : Hght = 190 : BtnW = 90 : BtnH = 14   : BtnS = Wdth/2-BtnW/2 : FrmS = 4 : FrmW = Wdth-2*FrmS 
            TxtH = 12  : TxtS = 10  : TxtW = Wdth-TxtS-FrmS-2 : Disp = 104 
            DIALOG NEW 0,                       "          Convert Data",   100,      60,  Wdth,  Hght, 0 TO hDlg
            DRAGACCEPTFILES       hDlg, %True 'Registers window to accept dropped files.  
            CONTROL ADD COMBOBOX, hDlg,  99,

    ------------------
    Kind Regards
    Mike

    [This message has been edited by Mike Trader (edited July 01, 2001).]

  • #2
    Mike --

    > PS testing the code HTML instruction

    Click your message's "Edit/Delete Message" icon and change \code to /code.

    -- Eric

    ------------------
    Perfect Sync Development Tools
    Perfect Sync Web Site
    Contact Us: mailto:[email protected][email protected]</A>
    "Not my circus, not my monkeys."

    Comment


    • #3
      Have you tried compiling it on a Win2k system?

      -Nathan.

      Comment


      • #4
        Nathan --
        > Have you tried compiling it on a Win2k system?
        Guess, that this code is not possible to compile on any system

        ------------------
        E-MAIL: [email protected]

        Comment


        • #5
          Nathan --

          I am 99.44% certain that compiling under Windows 2000 would make no difference at all. I am not aware that anybody, anywhere has ever reported a problem that was caused by compiling a PB/CC or PB/DLL program under a certain version of Windows. (I suppose compling with a buggy version of Windows -- or a buggy Windows service pack -- could cause a problem, but the resulting EXE or DLL almost certainly fail to operate on all versions of Windows, not just 2000.)

          -- Eric

          ------------------
          Perfect Sync Development Tools
          Perfect Sync Web Site
          Contact Us: mailto:[email protected][email protected]</A>



          [This message has been edited by Eric Pearson (edited July 01, 2001).]
          "Not my circus, not my monkeys."

          Comment


          • #6
            Thx Eric,
            I wondered how you guys got the code to tab out in your postings


            Now, How do get it to retain the tabs when you copy and paste it into PBEdit?

            Nathan,
            I dont have Win2k. I thought the compiler compiled 32bit clean code that would run on win 98x / win2k / winNT. Am i wrong?

            I have win89SE on a 400Mhz e-machines box. Runs perfectly here.


            I dont know where to start with this. I have quite a few API calls in my program for things like a progress bar, Drag and Drop, open dialog etc. Do I need a new version of "WIN32API.INC" or "Comdlg32.INC" or something?


            ------------------
            Kind Regards
            Mike

            [This message has been edited by Mike Trader (edited July 01, 2001).]

            Comment


            • #7
              Sorry, just a spur of the moment type of thought.

              Comment


              • #8
                Mike, You start your trubleshooting by asking your customer to
                return the exe file to you for investigation.
                Because I am 100,01% sure you have sent him the wrong file.....


                ------------------
                Fred
                mailto:[email protected][email protected]</A>
                http://www.oxenby.se

                Fred
                mailto:[email protected][email protected]</A>
                http://www.oxenby.se

                Comment


                • #9
                  Some mail clients like to insert additional symbols (CRLF, for example).
                  If I am not sure that another side has Outlook Express, I attach files as zip only.


                  ------------------
                  E-MAIL: [email protected]

                  Comment


                  • #10
                    I have a little Programm, which changes the PE Header to make a PE Executable Win2K-compatible. Send me a E-Mail and I mail it to you (but I think, compiling on a Win2K machine would be the best solution).

                    ------------------
                    E-Mail (home): mailto:[email protected][email protected]</A>
                    E-Mail (work): mailto:[email protected][email protected]</A>



                    [This message has been edited by Sven Blumenstein (edited July 01, 2001).]

                    Comment


                    • #11
                      Ok guys, I'll probably get stomp'd on!

                      (I get different symptoms for different situations in win2k)

                      Windows2000 has always'd caused me problems with PowerBasic!
                      I won't go into any extreme details, but let's just say that
                      I have to reboot just about every hour or so, when using
                      PowerBasic with Win2k! TaskManger is the only way out without
                      restarting... Since PB autosaves before compilation, my source
                      is never effected! Sometimes when running the stand-alone exe,
                      after compiling, the program GPF's, or some other symptoms that
                      show that your program has gone hay-wire!

                      Although, I haven't found why or the reasons, I do know that
                      when I first purchased this 1.4Ghz (Dell) about 2 months ago,
                      that PowerBasic worked fine! It was the only program on the
                      new computer. However, since that time, Visual Studio, Delphi
                      5 & 6, Java Compilers etc...the list goes on. About 30GB worth,
                      with (3x40Gb) HD's.

                      So, at the moment (reinstalling is not an option)! Too many
                      activations (controls) and hassels! :rolleys:

                      My solution: I install System-Commander Deluxe, Install Win98 as
                      a second o/s and use it solely for PowerBasic on the same (DELL).
                      All programs I have created with Win98 work perfectly on Win2k
                      without any problems! This was my solution!

                      So, there's something adrift in the Win2k O/S! And service pack
                      2 didn't help any!

                      Later
                      MWM


                      ------------------
                      mwm
                      mwm

                      Comment


                      • #12
                        That has the sniff of yet another Microsoft messup, I still use
                        win95b and get other people to test for me on later versions.

                        There are a few minor differences with code that runs on NT4/win2k
                        with things like return values in dialog procs but I have found
                        that PowerBASIC EXE files generally have no problems running on
                        any version, as long as the API calls in the code are available
                        in the OS version being run.

                        Regards,

                        [email protected]

                        ------------------
                        hutch at movsd dot com
                        The MASM Forum - SLL Modules and PB Libraries

                        http://www.masm32.com/board/index.php?board=69.0

                        Comment


                        • #13
                          Guys, correct me if I am wrong!
                          I think this thread is about a guy, who has a program, compiled on
                          a WIN/9x-system witch run OK on Win/9x systems.
                          ONE USER (or THE USER) says it does not run on WIN/2K
                          The best thing to do, is to get the file back from the user and
                          find out if the file still runs OK on Win/9x systems.
                          Mike dosent say how his "shipping" is done, but I am sure he tested
                          his application before shipment



                          ------------------
                          Fred
                          mailto:[email protected][email protected]</A>
                          http://www.oxenby.se

                          Fred
                          mailto:[email protected][email protected]</A>
                          http://www.oxenby.se

                          Comment


                          • #14
                            Michael,
                            I use Win2K for all my PBDLL/CC work and have never had a problem, altough
                            I use my PBWinADP for an IDE.
                            I get GPF's all the time when I write bad code but it has never brought Win2K down.

                            James




                            ------------------

                            Comment


                            • #15
                              Most likely, file is trashed. Send new file. Not sure if eventual
                              OPTION.. metastatement can have anything to do with it, but should
                              not. If eventual dependency file is missing/old/wrong, there should
                              be another message..?

                              Otherwise - should be enough to see Declares section and PBMAIN
                              to see why this happens, since it must be at startup sequence.


                              ------------------

                              Comment


                              • #16
                                Could it be that a DLL was created with a .EXE extension?
                                Do what Fred recommended...

                                Comment


                                • #17
                                  mike,

                                  now, how do get it to retain the tabs when you copy and paste it into pbedit?
                                  either edit the message containing the code before copying, or
                                  check out semen's utility:
                                  http://www.powerbasic.com/support/pb...ad.php?t=22962




                                  ------------------
                                  bernard ertl
                                  Bernard Ertl
                                  InterPlan Systems

                                  Comment


                                  • #18
                                    There is no real need to get carried away - the "problem" only affects IE users, and the solution is simple:

                                    When you want to copy/paste from a BBS message into PBEDIT, just click the EDIT MESSAGE button in the header of the target message, and highlight/copy the code from the edit window. Finally, paste that into PBEDIT/CCEDIT.



                                    ------------------
                                    Lance
                                    PowerBASIC Support
                                    mailto:[email protected][email protected]</A>
                                    Lance
                                    mailto:[email protected]

                                    Comment


                                    • #19
                                      Lance,

                                      You act like IE isn't the #1 browser on the market? All the
                                      source code provided on MSDN I can copy and paste fine, why
                                      can't you just get ride of UBB and go with something home grown?

                                      Just a suggestion.

                                      ------------------
                                      -Greg
                                      -Greg
                                      [email protected]
                                      MCP,MCSA,MCSE,MCSD

                                      Comment


                                      • #20
                                        I have found that copying code from the BB into Microsoft Word will format
                                        it correctly, then copy that into PBedit.

                                        Thank you Lance for pointing out the Edit Post method

                                        -Nath

                                        ------------------

                                        Comment

                                        Working...
                                        X