Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Run Time Primaey index corrupts.
Message
From
29/11/2002 06:22:23
James Hill
Jim Hill Productions
Halifax, Nova Scotia, Canada
 
 
To
All
General information
Forum:
Visual FoxPro
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Run Time Primaey index corrupts.
Miscellaneous
Thread ID:
00728134
Message ID:
00728134
Views:
37
I am caught between a rock and hard place, with only 24 hourse to find a resolution. I have also posted this Microsoft Fox Programmer exchange, but so far received no replies.
Here is the problem.......
I have, as part of an application, an 'Auction' module. When compiled and
run as an executable it works perfectly, but when it is run as part of a
'Run Time' created by Install Shield Express it corrupts the Primary Key
index (cidAuct).
The concept is simple. An entry is made into the 'Auction' table, given an
Item Number and description. If there is no 'Reserve' value placed on the
item at the time of entry, the value is set at zero. The program will only
accept bids greater than the current bid (anything equal or less is
rejected). All the user can do is to update the bid amount and enter the name and
phone number of the bidder. The user's name and the time of the bid is
automatically entered.
The user cannot alter or add any further items. The code for the update is
below. I surely need some help in solving this problem.
TIA

(update code)
LOCAL m.lcOriWA
m.lcOriWA = _SCREEN.ACTIVEFORM.primarytable
SELECT &lcOriWA
LOCAL lcNaTable, lcNaCurKey, lcNewKey
PUBLIC nAmount, cName, cCode, cPhone
m.lcNaTable = ALIAS()
m.lcNaCurKey = "cIDAuct"
m.lcNewKey = oApp.incrid( m.lcNaCurKey )
IF !EMPTY( m.lcNewKey )
DELETE
SET CARRY TO nitem_num, citem
INSERT INTO &lcNaTable (&lcNaCurKey,nitem_num,citem,nAmount, ctime) VALUES
(m.lcNewKey,nitem_num,citem,nAmount, TIME())
=TABLEUPDATE(.T.)
_SCREEN.ACTIVEFORM.REFRESH()
ELSE
=MESSAGEBOX("Record not added")
ENDIF
THISFORM.pgf2base1.page1.txtnBid.SETFOCUS
Next
Reply
Map
View

Click here to load this message in the networking platform