+ Reply to Thread
Results 1 to 9 of 9

Issue with programming.

  1. #1
    Registered User
    Join Date
    06-02-2008
    Posts
    5

    Issue with programming.

    Hi guys,

    I am doing a function in MS Excel, the function should concatenate e-mail adrresses separated by semicolons. I will put The e-mails in the column A from a worksheet named BDD. The VB code does not work properly, because when I tried to put the whole string on the content of the cell using either one of the following statements, I get an error message 1004 in execution.
    Please Login or Register  to view this content.
    Cadena_de_correos() is a string type function that creates a string with all the e-mails separated by semicolons and will return it.
    Last edited by royUK; 06-04-2008 at 01:21 AM.

  2. #2
    Forum Expert
    Join Date
    01-15-2007
    Location
    Brisbane, Australia
    MS-Off Ver
    2007
    Posts
    6,591
    Hi

    Can you please edit your post to (a) have a more meaningful title and (b) to wrap your code.

    Regarding your question, can you please post your code for the function, and perhaps an example file so we can see where your variables are being filled, and what your code is doing.


    rylo

  3. #3
    Registered User
    Join Date
    06-02-2008
    Posts
    5

    Enclosed is the code and the whole Worksheet

    Here it is:

    Enclosed is the worksheet and its code and examples. If you debug it you see that the concatenate is working all right but the issue is in that statement, I do not know why, because it works in other functions that I have created previously.

    I could not upload the file, because it exceeds the limit for the forum. So I add further information to understand the code enclosed here.

    There are two sheets, the first one is named "BDD" and the second one is named "GENERADOR DE LISTAS DE CORREO" where there is a button that executes the private sub CommandButton2_Click(). Finally, you should put in the column A from the worksheet "BDD" all the e-mail addresses in the differente rows starting from row 1 to n consecutively. If you click on the button on execution, you can see the error. If you debug it and brake on the specific line, you can see that everything is being done properly but assigning the value to the cell.

    Please let me know if there is any question.

    Please Login or Register  to view this content.
    Last edited by royUK; 06-04-2008 at 01:22 AM.

  4. #4
    Valued Forum Contributor mudraker's Avatar
    Join Date
    11-10-2003
    Location
    Melbourne, Australia
    Posts
    3,983
    alejojauregui

    Please do not ignore a moderators request

    rylo asked you to do 3 things. You have done 1 of them.
    Ignoring rylo's other 2 requests may see your thread closed

    Your reply also breaks one of the rules that you were asked to fix in your 1st posting

    Now Please take a couple of minutes and read the Forum Rules then wrap your VBA code (Rule 3)
    Please Read Forum Rules Before Posting
    Wrap VBA code by selecting the code and clicking the # icon or Read This
    How To Cross Post politely

    Top Excel links for beginners to Experts

    If you are pleased with a member's answer then use the Scales icon to rate it
    If my reply has assisted or failed to assist you I welcome your Feedback.

  5. #5
    Registered User
    Join Date
    06-02-2008
    Posts
    5
    Quote Originally Posted by rylo
    Hi

    Can you please edit your post to (a) have a more meaningful title and (b) to wrap your code.

    Regarding your question, can you please post your code for the function, and perhaps an example file so we can see where your variables are being filled, and what your code is doing.


    rylo
    Rylo,

    Sorry, but I didn't understand what is that you are asking me to do. Your are going to have to excuse me but this is my first time using forums for help. Please let me know what do I have to do, and I will sure do it.

    Regards.

  6. #6
    Registered User
    Join Date
    06-02-2008
    Posts
    5
    Quote Originally Posted by mudraker
    alejojauregui

    Please do not ignore a moderators request

    rylo asked you to do 3 things. You have done 1 of them.
    Ignoring rylo's other 2 requests may see your thread closed

    Your reply also breaks one of the rules that you were asked to fix in your 1st posting

    Now Please take a couple of minutes and read the Forum Rules then wrap your VBA code (Rule 3)
    Sorry,

    It seems like I did something wrong, but I just tried to do all I could. I am probably not understanding everything I should do. If you could please let me know, I would appreciate your assistance.

  7. #7
    Forum Expert
    Join Date
    01-15-2007
    Location
    Brisbane, Australia
    MS-Off Ver
    2007
    Posts
    6,591
    Hi

    1) Your post title is "Issue with programming". This doesn't really give indication as to what your problem may be. Please edit your post to change the title to be more descriptive of your problem. Other posters can then use the title in their search requests.

    2) Code has to be wrapped for ease of use and to make it stand out from your text. If you highlight your code, then press the # icon (not the # button on your keyboard) the code will be wrapped with tags to make it stand out. If your editor doesn't show the #icon, then manually type the tags {code} and {/code} where {} are really [].

    Please go back to your earlier posts and make the requested changes.

    rylo

  8. #8
    Registered User
    Join Date
    06-02-2008
    Posts
    5
    Thank you. I will try to do what you just told me.

    Regards,

    Alejandro J.

  9. #9
    Forum Expert royUK's Avatar
    Join Date
    11-18-2003
    Location
    Derbyshire,UK
    MS-Off Ver
    Xp; 2007; 2010
    Posts
    26,200
    Quote Originally Posted by alejojauregui
    Thank you. I will try to do what you just told me.

    Regards,

    Alejandro J.
    I have edited your posts because you can no longer do so. Please read the Forum Rules which explain the correct format of Thread Titles & the use of Code Tags
    Hope that helps.

    RoyUK
    --------
    For Excel Tips & Solutions, free examples and tutorials why not check out my web site

    Free DataBaseForm example

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1