Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
Database Servers
DB2InformixIngresMS SQLOraclePervasive.SQLPostgreSQLProgressSybase
Desktop Databases
FileMakerFoxProMS AccessParadox
General
General DB TopicsDatabase Theory
Related Topics
Java Development.NET DevelopmentVB DevelopmentMore Topics ...

Database Forum / FoxPro / Forms / July 2008

Tip: Looking for answers? Try searching our database.

Form Textbox

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Rosie - 28 Jul 2008 03:14 GMT
Hi everyone,

I have this form which is just to enquire the data of the staff and display
it on the screen. In the form, there is a textboxt to keyin the staffid.

Then I will check the id as below :

The staff will keyin the id which is the staffid.
The fstaffid is the one found in the familyview

store staffid to value1

use familyview &&to check the family members of the staff
select * from familyview where value1 = fstaffid into cursor famtest

do while '&value1' $fstaffid
   display the data
skip
enddo

The thing here is the fstaffid is pointing to record 1 in the familyview. You
would not believe it when I took out the cursor famtest, the whole list of my
required data is there but my pointer is pointing to the familyview but I do
want my pointer to go to the select statement where I've found the data.
What could be the issue here....as i'm still a novice to foxpro 9.

Thanks for the assistance.
Dan Freeman - 28 Jul 2008 16:56 GMT
I'm guessing you have a grid on your form displaying the view familyview.
The grid will select that workarea at every opportunity.

Set focus to some control OTHER than the grid on your form.

Dan

> Hi everyone,
>
[quoted text clipped - 25 lines]
>
> Thanks for the assistance.
swdev2 - 29 Jul 2008 16:56 GMT
I think your sql select statement is backwards - ie.. you have
where value1 = fstaffid
and I think you want
where fstaffid = value1
or
where fstaffid = ?value1

Give it that small change, see if you have a difference.

Usually, you want <<column name >> ||math condition|| <<variable name>>
and you have
<<variable name>> || math condition || <<fieldname>>

Mondo Regards [Bill]

--
===================
William Sanders / EFG  VFP / mySql / MS-SQL
www.efgroup.net/vfpwebhosting
www.terrafox.net  www.viasqlserver.net

> Hi everyone,
>
[quoted text clipped - 26 lines]
> --
> Message posted via http://www.dbmonster.com
Rosie - 31 Jul 2008 01:20 GMT
Hi swdev2,

Did as you suggested and it works fine. I need to check the record column
against the input.

Thanks a lot for the help and assistance.

Bye.

>I think your sql select statement is backwards - ie.. you have
>where value1 = fstaffid
[quoted text clipped - 22 lines]
>> --
>> Message posted via http://www.dbmonster.com
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.