Hi Gina I did save record souce, this is the record souce for the form
that I
insert the pictures into. And the Field is an Image field, I have done
this
before and not had any problems now for some reason I am having
problems.
But if I make that form into a sub form on the main form it works fine.
so
I'm confused. the image is an ole object I guess
SELECT PeopleID, Image, PicID, ParentID FROM AdultPics_tbl
:
Okay, I think I may be asking this incorrectly...
You have a form thru which you insert pictures... How do you insert
the
pictures? The code you show below simply opens the pictures form. If
that
is the form where you recieve the error then THAT form needs to have
it's
RecordSource saved as a query.
--
Gina Whipp
"I feel I have been denied critical, need to know, information!" -
Tremors
II
http://www.regina-whipp.com/index_files/TipList.htm
here is what the command button usese
Private Sub Command439_Click()
On Error GoTo Err_Command439_Click
Dim stDocName As String
Dim stLinkCriteria As String
stDocName = "ClientPictures_fm"
stLinkCriteria = "[PeopleID]=" & Me![PeopleID]
DoCmd.OpenForm stDocName, , , stLinkCriteria
Exit_Command439_Click:
Exit Sub
Err_Command439_Click:
MsgBox Err.Description
Resume Exit_Command439_Click
End Sub
:
Error mesage?
Also, can you copy/paste the code the Command Button is using?
--
Gina Whipp
"I feel I have been denied critical, need to know, information!" -
Tremors
II
http://www.regina-whipp.com/index_files/TipList.htm
it still didnt work, it does work if I make the picture form a
subform
and
enter pictures but it doesnnt work when I access it through a
command
button.
:
desireemm,
Okay now the error message...
This error can occur if the data you are attempting to save is
saving
to
a
Microsoft SQL Server 7.0 or earlier database and the
RecordSource
for
the
subform is using an SQL select statement with fields pulled
directly
from
the
source table, and the table is using an Identity field set as
its
primary
key.
*****To avoid this problem set the RecordSource property of the
subform
to a
table or a query.*****
Because of your version of SQL Server you will need to turn you
SELECT
statement into a QUERY. Make the QUERY the RecordSource of the
form.
To
do
that...
1. Go back to Design View of the Form and return to the
RecordSource
and
click the elipse button [...].
2. Once that window open press the SAVE button and name your
query
and
save. Say "Yes" or "Okay" to all questions and try your insert
picture
again.
--
Gina Whipp
"I feel I have been denied critical, need to know,
information!" -
Tremors
II
http://www.regina-whipp.com/index_files/TipList.htm
message
ok Here is the Record source
SELECT [Parent ID], [Family ID], [Referral Location],
[Referral
Date],
[Registration Date], [Student First Name], [Student SS#],
[Student
Last
Name], [Student Sex], Grade, Age, [Student Date of Birth],
[Event
ID],
TANFreferral, TypeOfParticipant, RequiredHours,
SpecialInstructions,
Adult_Child, State, SSID, PeopleID, TANF, ServiceArea, Weekly,
Month,
ReferralStatus, TanfStaffMakeReferal, Message, Phone,
StateStudentID,
TribalAfflilation, StudentCity, StudentState, StudentZip,
StudentAddress,
DateReleased, StudentRelease, ParentRelease, ScannedDocuments,
EmailAddress,
Enrollmentstatus, MaritalStatus, Vetran, TanfSpouseName,
TanfSpouseSocial,
PntID, Pictures FROM TANFParticipants_view
:
Okay, that s not what I want...
Go to the form which you use to enter the pictures (in the
Access
database)
Go to Design View of that form and pull up the properties
In the Properties section at the top it will RecordSource...
copy
and
paste
that here.
--
Gina Whipp
"I feel I have been denied critical, need to know,
information!" -
Tremors
II
http://www.regina-whipp.com/index_files/TipList.htm
message
I hope I am understanding you. this is the record source
Picture is an Image, PicID is Interget (Identiy/SqL
Autonumber)
only
parent
is nvarchar (50)
SELECT Picture, PicID, PeopleID, [Parent ID] FROM
TanfPictures_tbl
:
And the RecordSoirce of the form?
--
Gina Whipp
"I feel I have been denied critical, need to know,
information!" -
Tremors
II
http://www.regina-whipp.com/index_files/TipList.htm
message
I'm sorry Its Access 2007 with SQL server 2005 as the
engine.
Yes
the
pictures are stored in a table which only stores pics
:
desireemm,
We're going to need a little help here...
Access version?
Are you, in fact, using SQL Server 7.0 or earlier or
another
version?
Are you storing the pictures in the database or rather
trying
to
store
them
in the database?
What is the RecordSource of the form?
....that should get us started.
--
Gina Whipp
"I feel I have been denied critical, need to know,
information!" -
Tremors
II
http://www.regina-whipp.com/index_files/TipList.htm
in
message
Hi all I have a table called Pictures_tbl that has a
one
to
many
relationship
with a parent table called People_tbl. Every time I
enter a
picture
into
the
form where the Pictures_tbl is I get this error
message.
Can
anyone
help.
This error can occur if the data you are attempting
to
save
is
saving
to a
Microsoft SQL Server 7.0 or earlier database and the
RecordSource
for
the
subform is using an SQL select statement with fields
pulled
directly
from
the
source table, and the table is using an Identity
field
set
as
its