If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > Database Server Software > Informix > UniData and Visual BASIC

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 05-11-04, 13:53
carmojos carmojos is offline
Registered User
 
Join Date: Nov 2003
Posts: 1
UniData and Visual BASIC

I am currently writing a program to update a file in a UniData database.. When I attempt to write to a field I get a Type mismatch error. Here is the code that I am working with.

Dim NewRecord As Object
Dim DRECORD As Object
Set DRECORD = Nothing

Set GLAdminFile = UVSession.OpenFile("BUDGET.MAN")
'Set NewRecord = CreateObject("UniVerse.DynamicArray.1")
GLAdminFile.recordid = lstUsers.Text
GLAdminFile.Read
Set DRECORD = GLAdminFile.RECORD
If chkAdmin Then
DRECORD.Field(1) = "Y" 'Happens here
Else
DRECORD.Field(1) = "N" ' or here
End If
For Index = 0 To lstUsrUnits.ListCount
If units <> "" Then
units = units & "ý" & lstUsrUnits.list(Index)
Else
units = lstUsrUnits.list(Index)
End If
Next Index
GLAdminFile.RECORD = "Y" & units
Set DRECORD = GLAdminFile.RECORD


Any help would be appreciated.

Please respond to my e-mail address.
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On