Excel Chess

termeric

Board Regular
Joined
Jun 21, 2005
Messages
245
Hello,

i was just wondering if any one had put together a good chess game using excel.

im currently just using a shared workbook with letters that represent the pieces and lowecase vs uppercase letters as teams. its crude but works fairly well.


thanks,

christian.
 

Some videos you may like

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK

TrippyTom

Well-known Member
Joined
Nov 16, 2004
Messages
587
height = 50
width = 12

conditional format the area to color the squares:
=MOD(COLUMN(),2)=MOD(ROW(),2)

* This pattern is incorrect (it's the inverse of what it should be) so color the conditional formatted cells white and then color the entire area manually a darker color to get the proper placement of the black to white setup - each player should have a black square on the left bottom when they face the board

I'm sure you could get graphics of chess pieces on google and just place them on your workbook.

This will get you started... To go further, you could setup a named range for each square and use that in VBA code if you wanted to program a history of moves and such.
 

erik.van.geit

MrExcel MVP
Joined
Feb 1, 2003
Messages
17,832
Hello,

I've got a chessboard in Excel with autoshapes, but never continued to programm it. Could give you some ideas. Feel free to email me, I'll send you the file.

kind regards,
Erik
 

just_jon

Legend
Joined
Sep 3, 2002
Messages
10,473
Ah, but one of the true pleasures of chess is the sight and feel of the wooden board and the contours of the pieces.
 

erik.van.geit

MrExcel MVP
Joined
Feb 1, 2003
Messages
17,832

ADVERTISEMENT

just_jon said:
Ah, but one of the true pleasures of chess is the sight and feel of the wooden board and the contours of the pieces.
YES!! fully agree (that's why I never finished the Excelchessboard)

BUT
for some - me included - one of the true pleasures of Excel is to create needless applications on the screen within the contours of the cells :LOL:
 

Oorang

Well-known Member
Joined
Mar 4, 2005
Messages
2,071

ADVERTISEMENT

Making a chess AI would be quite a challange. Not only that, in a language as slow as VBA I'm sure the calculation time would be prohibitive. Although it probably would doable if you just made it for humans to play each other hotseat.
 

termeric

Board Regular
Joined
Jun 21, 2005
Messages
245
i whole heartidly agree that a wooden pieces and a face to face confrontation is the best way to play the game.

i ended up just sharing a workbook and used CAPS vs lowercase until a friend went out and got pictures of the pieces. it works pretty good on slow days.
 

gingerafro

Active Member
Joined
Mar 23, 2005
Messages
448
If you PM me your e-mail address, I'll send you what I created about 6 years ago, back when I was foolish and all macros were recorded (hence why I know when it was created).

It runs off a dialog box (not even a userform) so you can see it is quite basic, but works quite nicely for a human v human match. I'm in agreement with Oorang that AI in VBA would probably be impossible.
 

Oorang

Well-known Member
Joined
Mar 4, 2005
Messages
2,071
You know whose opinion I'd like to get on this topic? Aladdin Akyurek. I know he is a LISP programmer, which makes me think he could offer a quite qualified response on the feasibility of using VBA for a Chess AI.
 

Watch MrExcel Video

Forum statistics

Threads
1,118,112
Messages
5,570,259
Members
412,314
Latest member
yazanwael
Top