Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Replica does not recognize formated text boxes

Status
Not open for further replies.

tbac

Technical User
Jun 16, 2003
59
US
I have a replicated database with several formatted text boxes that work well on the design master but not on the replica. Example 1: On Reports where I inserted a Date text box in the footer. When you open the report on the replica, you get a message, 'Enter Parameter Value' for Date. Example 2: On a form I have a text box with Control Source: ="R" &Right(Year(Now())-0,2). On the design master it shows '09' but in the replica it shows 'NAME?'. Has anyone else had this problem?
 
Often when string functions do not work
right, left, len, instr etc it has to do with a bad visual basic reference.
Try some basic string functions in the immediate window of the replica and tell us what happens.
However, what is this ""R" &Right(Year(Now())-0,2)? I do not get it.
How about

format(now(),"\RYY")
if you want R09
 
I think you are right that I have a reference problem but it seems like it would be a common problem and there would be a way around it, and I wasn't sure if it was the reference to VBA or the reference to DAO: The Design master is on my laptop and the replica is on a shared drive on our server, G:\Database... Everything works fine with VBA code for On Event routines, but the Text Box controls like Dates inserted into reports and others, do not work on the replica.
 
I have seen this where the VBA reference is older on the system than the the machine it was created on. It requires the user to open the db. Remove the reference to VBA and then recheck it. One solution is to use late binding on all your vba string functions (which is a pain).

See if the replica on the user machine can run any string functions. See if you reset the reference to VBA.
 
The references are there on the replica and the files they reference are the same version. What I am wondering is if there is something about the replica being on a network server while the design master is on my laptop. They synchronize fine but I wonder if there is a way that I can get the date function to work on the replica
 
Did you remove and then re apply the reference to vba?
Did you verify it is a string problem issue throughout the db not just the query (that was a guess)?
If it is vba issue then explicitly call vba out i.e VBA.Right(.._
 
The replica will not let me remove the reference to VBA and the format(now(),"\RYY") function acts just like the original string I had in the text box, that is it works on the design master but not on the replica. I wasn't sure what you mean by explicitly call vba, would I put VBA.Right(... into a text box?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top