Why do two PC's have differences when importing the same data from the clipboard

Posted on 2011-05-12
Last Modified: 2012-08-13
I have written a routine that imports data from the clipboard into a database. I have run the exact same source data on two machines, both running Access 2007 and the data comes in differently. The difference appears to be that one is copying data from data viewed Internet Explorer and the other is using Mozilla Firefox. The difference is the way they handle a few characters. For example in one place i.e. brings in
chr(13) chr(10) chr(13) chr(10)
a pair whereas Firefox only reads
a single set.

In other places i.e. imports chr(32) whereas Firefox imports it as chr(9)

In another place Internet Explorer imports chr(32) chr(13) chr(10)
whereas firefox imports
chr(13) chr(10)

These differences make it difficult to consistently import data. Can anyone suggest how I can get around these problems given I need to substring the data meaningfully to populate fields and tables
Question by:Rob4077
    LVL 29

    Expert Comment

    by:Randy Downs
    make your default browser teh same on both PCs

    Author Comment

    That would fix it but I was hoping to be able to handle both.
    LVL 29

    Accepted Solution

    If you want to cover all bases you will need to determine the default browser and import accordingly. Basically have one import for Firefox and another for IE

    Author Comment

    Thanks. That's basically what I had to do. I was hoping there might be a setting somewhere that made it easy.
    LVL 74

    Expert Comment

    by:Jeffrey Coachman
    <I have written a routine>
    ... Ok, so can you post the code for this "Routine" for us to evaluate?

    <...that imports data from the clipboard into a database.>
    What "Specifically" are you importing...?
    (Give a specific example)

    Using the clipboard is sometimes an unreliable way to transfer data...

    Like Number-1 suggests, if the only thing stopping this from functioning consistently is users using the same browser, ...then tell them to use the same browser...
    (at least when doing this specific transfer).
    Just tell users:
    "In order to do the ____ Transfer, you must be in FireFox"

    Chr(32) is a Space character, so I am not quite sure why one browser would see it and another would not...

    Anything can be done, but without seeing your current code we can't suggest anything specific.
    In an overall sense, you would probably need some If-Then logic:

    If Firefox then
    ElseIf IE then
    End if


    Author Comment

    Hi Jeff,
    Thanks for your clarification. I have now written some code that simply replaces a few character strings to make them consistent across both platforms and then continues processing so its done.

    I am surprised that the same data coming from a server to a client is actually changed (although it appears visibly identical). I would have thought that what the server sends the client displays unchanged. For that reason I asked the question hoping there would be some setting that would fix the problem. At any rate it's all fixed and working on both platforms for now.

    Featured Post

    How to run any project with ease

    Manage projects of all sizes how you want. Great for personal to-do lists, project milestones, team priorities and launch plans.
    - Combine task lists, docs, spreadsheets, and chat in one
    - View and edit from mobile/offline
    - Cut down on emails

    Join & Write a Comment

    Suggested Solutions

    Introduction When developing Access applications, often we need to know whether an object exists.  This article presents a quick and reliable routine to determine if an object exists without that object being opened. If you wanted to inspect/ite…
    Introduction The Visual Basic for Applications (VBA) language is at the heart of every application that you write. It is your key to taking Access beyond the world of wizards into a world where anything is possible. This article introduces you to…
    In Microsoft Access, learn different ways of passing a string value within a string argument. Also learn what a “Type Mis-match” error is about.
    In Microsoft Access, when working with VBA, learn some techniques for writing readable and easily maintained code.

    732 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    22 Experts available now in Live!

    Get 1:1 Help Now