Connecting Tech Pros Worldwide Forums | Help | Site Map

2003 and Long Binary Data

Randy
Guest
 
Posts: n/a
#1: Nov 13 '05
I have heard that access 2003 has functions for dealing with Long
Binary Data. Does anyone know if this is true?
Background:
I am using 2000 with a table linked to a SQL server. One of the fields
is of type OLE Object. This table is populated from a website where
excell spreadsheets are uploaded. But in the linked Access table
instead of saying Excell spreadsheet in that field it says Long Binary
Data, which can not be opened. My users on this end to open or export
that file preferably as .xls but .txt, or .csv format would work.

Marc
Guest
 
Posts: n/a
#2: Nov 13 '05

re: 2003 and Long Binary Data


randy.welker@hughessupply.com (Randy) wrote in message news:<86a11b2a.0411190719.3f06968c@posting.google. com>...[color=blue]
> I have heard that access 2003 has functions for dealing with Long
> Binary Data. Does anyone know if this is true?
> Background:
> I am using 2000 with a table linked to a SQL server. One of the fields
> is of type OLE Object. This table is populated from a website where
> excell spreadsheets are uploaded. But in the linked Access table
> instead of saying Excell spreadsheet in that field it says Long Binary
> Data, which can not be opened. My users on this end to open or export
> that file preferably as .xls but .txt, or .csv format would work.[/color]


randy,
I'm not an expert on this, but I think the data at the SQL-server-side
should be of the image-datatype to be accessed from Access as
OLE-object. i found some info on
(http://msdn.microsoft.com/library/de...designeff.asp).

Marc
Stephen Lebans
Guest
 
Posts: n/a
#3: Nov 13 '05

re: 2003 and Long Binary Data


Have you tried saving the contents of the field to a disk file and then
trying to load the file in Excel. I say this because the original Excel
file may have been inserted as binary data.

Create a form with an OLE Frame control bound to the field in question.

Private Sub cmdSave_Click()
On Error GoTo Err_cmdSave_Click

Dim a() As Byte
Dim lTemp As Long
Dim sl As String

lTemp = LenB(Me.olePicture.Value)
ReDim a(0 To lTemp) ' should be -1

' Copy the contents of the OLE field to our byte array
a = Me.olePicture.Value

sl = "OLEfieldTestExcel" & ".xls"
Open sl For Binary Access Write As #1
Put #1, , a
Close #1

Exit_cmdSave_Click:
Exit Sub

Err_cmdSave_Click:
MsgBox Err.Description
Resume Exit_cmdSave_Click

End Sub

--

HTH
Stephen Lebans
http://www.lebans.com
Access Code, Tips and Tricks
Please respond only to the newsgroups so everyone can benefit.


"Randy" <randy.welker@hughessupply.com> wrote in message
news:86a11b2a.0411190719.3f06968c@posting.google.c om...[color=blue]
> I have heard that access 2003 has functions for dealing with Long
> Binary Data. Does anyone know if this is true?
> Background:
> I am using 2000 with a table linked to a SQL server. One of the fields
> is of type OLE Object. This table is populated from a website where
> excell spreadsheets are uploaded. But in the linked Access table
> instead of saying Excell spreadsheet in that field it says Long Binary
> Data, which can not be opened. My users on this end to open or export
> that file preferably as .xls but .txt, or .csv format would work.[/color]

RANDY
Guest
 
Posts: n/a
#4: Nov 13 '05

re: 2003 and Long Binary Data


Thank You very much!
It works perfect!



*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Closed Thread