Hmm...
I ran your code snippet and it worked fine on my compy, so you do seem to have some issue.
(Although, if I wanted to nit-pick, your code would work better thusly)
ctr as integer
y as integer = 0
dim colors(7) as string
colors(0) = "Red"
colors(1) = "Green"
colors(2) = "Blue"
colors(3) = "Purple"
colors(4) = "Yellow"
colors(5) = "Orange"
colors(6) = "White"
colors(7) = "Black"
for ctr = 0 to 7
text 0,0, "This is a list of the contents of the color array:"
text 0,30+y,colors(ctr)
y=y+15
next ctr
wait key
end
So...
You have the newest DBP beta.
You are not using Avast.
You tried disabling UAC and it still failed.
Do me a favor and humor me on this one:
Open DBP and click through 'Help > About DarkBasic Professional...'
Make sure that it says 'Version 1.077'
Sometimes, the installers grab the wrong install path, and your problem really sounds exactly like the pre-hotfix from 7.7rc2.
Just to clarify:
Does Darkbasic Pro itself crash, or does the program that you just compiled crash? If the executable program that you are running crashes, but DBP appears to create the exe okay, then I've assumed properly.
The answers I listed above fix the vast majority of issues like yours that I've seen here.
There have been people who have had issues with DX9.0c.
I think I would try running the install program for DX 9.0c first to make sure that your DirectX is doing what it should be doing.
You can grab the official DX 9.0c that we need for DBP here:
http://www.microsoft.com/downloads/en/details.aspx?FamilyID=2da43d38-db71-4c1b-bc6a-9b6652cd92a3&displaylang=en
Make sure that your video drivers are up to date.
Also, if you have any other add-ons installed, either store bought from TGC or free ones, uninstall them and make sure that their DLL's are gone from your Compiler folder. If you got a corrupt download or if you're using an out of date add-on, that can cause conflicts in DBP and programs created with it.
I assume that your computer meets the minimum specs for DBP (It's old enough that it's hard to find a compy that can't run it...)
If none of that helps, I may be out of ideas.
If you want me to take a closer look, follow these steps exactly.
1:
Create a new folder on your desktop
2:
Create a new project in DBP
3:
Copy/paste my code snippet (Above) into DBP
4:
Save the project to the new folder on your desk top
5:
Click on the 'Compile and Run' button
6:
Assuming it fails to run, zip or rar the entire folder on your desk top. It should have the dba, dbpro, and exe (If it managed to compile)
7:
Upload the zip to your next post here
That can give me a few more clues.
The dbpro file can be opened with notepad so that I can make sure that the settings appear normal.
I can see if the exe will run on my pc. (Pre 7.7 rc2, the exe's wouldn't run on any Win7 SP1 machine)
And any other random details that I may get lucky and notice...
EDIT:
One of the things listed in the dbpro file is the location of the folder on your computer.
If your Windows account name is your real name and you don't want to accidentally share that, open the dbpro file with Notepad and scroll through it (It's a short file). If you find any references to personal info such as your Win account name that you don't want public, just replace that word with 'XXXX' and save it before you zip it.
Bonus EDIT:
You can also try compiling and running it in step through debugging mode. That'll tell you exactly where it crashes, although my guess is that it's crashing at the first line...
You can get step through mode by hitting F7, or via the Compile button in the top bar.