473,395 Members | 1,702 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

simple contatenation....or so I thought

122 100+
Can anyone help me see the problem with this string concatenation?

Expand|Select|Wrap|Line Numbers
  1. fileName = "'C:\Documents and Settings\" & myName & "\Desktop\UCAN1021001.xls'"
It should be a simple thing, but it won't add the last section onto the string. I get 'C:\Documents and Settings\Annalyzer and nothing else.
Jun 12 '08 #1
2 1087
Stewart Ross
2,545 Expert Mod 2GB
Hi. The concatenation of the three strings appears to be OK, so you need to look at other possibilities.

* Is the length of string filename adequate for the purpose?

* What type is variable myName? It is not a fixed-width string or somesuch?

* Check what the length of the text in variable myName is (using Len(myName)). Is it what you expect? This is to rule out hidden spaces padding the string.

* Has a newline or any other special character been added to the end of the text in myName?

-Stewart
Jun 12 '08 #2
Annalyzer
122 100+
That was it, thanks! myName had one space padded onto the end of it that was somehow preventing the rest of the string from concatenating.

Now if I can figure out why it gives me the error message "Microsoft Office Access can't save the output data to the file you've requested." I find that screaming "Why the h*** not?" at the monitor isn't helping as much as I had hoped. I'll give it a rest and look at it again later and I still can't figure it out, I may post my code and let the experts take a look.

Thanks for your help!
Jun 12 '08 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

2
by: nephish | last post by:
Hey there, i have been spending some time learning python. i do enjoy it so. Heres the deal. i need some dirrection advice. i have a friend that wants me to set up a customer database for him....
3
by: Patchwork | last post by:
Hi Everyone, Please take a look at the following (simple and fun) program: //////////////////////////////////////////////////////////////////////////// ///////////// // Monster Munch, example...
1
by: Dick Rosser | last post by:
Greetings, I have scanned all the script repositories to no avail trying to find what would be, I thought, a fairly simple script. What I am trying to achieve is as follows, perhaps someone can...
11
by: JKop | last post by:
Take the following simple function: unsigned long Plus5Percent(unsigned long input) { return ( input + input / 20 ); } Do yous ever consider the possibly more efficent:
3
by: KevinD | last post by:
thank you for your helpful explanations. In my first note I forgot to mention that my simple flatfile is a text file with a newline character at the end thus I able to get an entire record . ...
10
by: serge calderara | last post by:
Dear all, I need to build a web application which will contains articles (long or short) I was wondering on what is the correct way to retrive those article on web page. In orther words, when...
18
by: Bob Cummings | last post by:
Not sure if this is the correct place or not. Anyhow in school we were taught that when trying to calculate the efficiency of an algorithm to focus on something called FLOPs or Floating Point...
5
by: Byron | last post by:
I need to create an application that uses primarily a single form rather than an SDI that creates a new form for everythting. However, I don't want an MDI style application since the users I'm...
3
by: Phillip Vong | last post by:
Using VS2005 w/ simple aspx in VB.net I have a simple databound textbox "LastMtgText" in a formview in the Insert template. All I want to do is make the default date of today when someone goes...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.