Author Topic: Problem whith install in windows 10 Home  (Read 7369 times)

0 Members and 1 Guest are viewing this topic.

Offline Juanjogomez

  • Forum Regular
  • Posts: 117
    • View Profile
Re: Problem whith install in windows 10 Home
« Reply #15 on: June 08, 2020, 01:04:40 pm »
As soon as I got home I tried it, but I understood that after the functions connect, open database
and close database you should not put chr $ (0), and has always worked

Offline SMcNeill

  • QB64 Developer
  • Forum Resident
  • Posts: 3972
    • View Profile
    • Steve’s QB64 Archive Forum
Re: Problem whith install in windows 10 Home
« Reply #16 on: June 08, 2020, 01:47:56 pm »
I would guess it's a permission issue for file access.  Make certain the programs are installed in a directory with inherited permissions (or make a root directory such as C:\QB64, instead of C:\Program Filesx86\QB64), and that the anti-virus has the chosen folder whitelisted so it doesn't give false positives for viruses and screw stuff up.
https://github.com/SteveMcNeill/Steve64 — A github collection of all things Steve!

Offline Juanjogomez

  • Forum Regular
  • Posts: 117
    • View Profile
Re: Problem whith install in windows 10 Home
« Reply #17 on: June 08, 2020, 04:40:27 pm »
In several places you call mysql_* functions without null-terminating your strings. This is potentially a problem.

Hello
I can't find any string that doesn't end with chr $ (0). There are no strings in the functions - or I don't see them - . Can you tell me which ones are wrong and how should I write them?
Thanks

Offline Juanjogomez

  • Forum Regular
  • Posts: 117
    • View Profile
Re: Problem whith install in windows 10 Home
« Reply #18 on: June 08, 2020, 04:45:17 pm »
I would guess it's a permission issue for file access.  Make certain the programs are installed in a directory with inherited permissions (or make a root directory such as C:\QB64, instead of C:\Program Filesx86\QB64), and that the anti-virus has the chosen folder whitelisted so it doesn't give false positives for viruses and screw stuff up.

The programs are outside the windows folders and work perfectly on the other computers. The funny thing is that in some other computers some work and others do not. (As I have commented previously, it is a billing and warehouse management program that consists of a total of 32 programs).
Thanks

Offline luke

  • Administrator
  • Seasoned Forum Regular
  • Posts: 324
    • View Profile
Re: Problem whith install in windows 10 Home
« Reply #19 on: June 09, 2020, 04:26:36 am »
Hello
I can't find any string that doesn't end with chr $ (0). There are no strings in the functions - or I don't see them - . Can you tell me which ones are wrong and how should I write them?
Thanks
You're just not seeing them.

For instance, line 33 calls mysql_real_connect() without NULL-terminated strings. Line 563 and 602 pass a query to basedato which gets passed straight through to mysql_query, no terminator added.

This may not be the cause of the failure, but it sure isn't a good thing.

Offline Juanjogomez

  • Forum Regular
  • Posts: 117
    • View Profile
Re: Problem whith install in windows 10 Home
« Reply #20 on: June 09, 2020, 08:43:39 am »
You're just not seeing them.

For instance, line 33 calls mysql_real_connect() without NULL-terminated strings. Line 563 and 602 pass a query to basedato which gets passed straight through to mysql_query, no terminator added.

This may not be the cause of the failure, but it sure isn't a good thing.

Sorry but I still don't understand how to put chr $ (0) in a function,
Could you tell me, for example, how would you write this line?

connection = mysql_real_connect (conn, servidor$, usuario$, clave$, bdatos$, puerto, 0, 0)

Or would I have to end servidor$, clave$ and bdatos$ with chr$(0)?

Thank you

Offline Juanjogomez

  • Forum Regular
  • Posts: 117
    • View Profile
Re: Problem whith install in windows 10 Home
« Reply #21 on: June 09, 2020, 10:48:33 am »
OK. I just saw the two lines, 562 and 601 that are missing the null character, although that would make the data not be saved when leaving the MENU.
I am going to try to add a NULL character to the server name, database, and password and test it on the client's computer, which being at the beginning of each of the programs could make it not work (although I do not understand that they work in some computers and not others)

Offline Juanjogomez

  • Forum Regular
  • Posts: 117
    • View Profile
Re: Problem whith install in windows 10 Home
« Reply #22 on: June 10, 2020, 01:45:52 am »
I brought the client's computer home so I could test it.
 I've gone through all the database accesses to see if there were more strings without finishing the chr$(0) and recompiled all the programs.
 It still doesn't work on this computer.
 The last test I have done is to install QB64 1.3 32 bits on the client computer (the one I use) and I loaded the progrqama from the MENU, but removing the lines that access the database and all the routines included in the $INCLUDE (I removed the $INCLUDE). The lines that accessed the routines I have converted them into comments so that they do not fail to find them. I mean, I'd just paint the different options on the screen without doing anything else.
 I hit F5, it gets dark while it's all right - and when it's over, the show won't start. and the EXE does not work.
As I said further back, and you can see it by the code, I don't access graphics or anything weird. Just paint the MENU windows on the screen. Any ideas?

Offline Juanjogomez

  • Forum Regular
  • Posts: 117
    • View Profile
Re: Problem whith install in windows 10 Home
« Reply #23 on: June 10, 2020, 02:49:40 pm »
I have found the problem by chance, after having installed several operating systems and only some of the programs work (with no apparent explanation).
The customer's computer, which has a Realtek High Definition sound card on the motherboard, turns out that if no speakers are connected, the card is disabled.
The programs that didn't work were the ones that had a BEEP command placed somewhere in it, when there was an error, to warn the user.
As soon as I connect some speakers, the program works correctly. If I unplug them, the programs that carry the BEEP command stop working.
It is rare that the program does not start because on line 1,320 (to say any one) there is a BEEP command.
Thanks to everyone who has tried to help me, and I hope this information is useful to others who may have a similar error.
Tonight I can sleep peacefully !!

Offline bplus

  • Global Moderator
  • Forum Resident
  • Posts: 8053
  • b = b + ...
    • View Profile
Re: Problem whith install in windows 10 Home
« Reply #24 on: June 10, 2020, 04:56:22 pm »
Man what an amazing story, through persistence you blunder your way into a big discovery!

Where have I heard that before? :)

Glad you can get some sleep now.