Alpha Software Mobile Development Tools:   Alpha Anywhere    |   Alpha TransForm subscribe to our YouTube Channel  Follow Us on LinkedIn  Follow Us on Twitter  Follow Us on Facebook

Announcement

Collapse

The Alpha Software Forum Participation Guidelines

The Alpha Software Forum is a free forum created for Alpha Software Developer Community to ask for help, exchange ideas, and share solutions. Alpha Software strives to create an environment where all members of the community can feel safe to participate. In order to ensure the Alpha Software Forum is a place where all feel welcome, forum participants are expected to behave as follows:
  • Be professional in your conduct
  • Be kind to others
  • Be constructive when giving feedback
  • Be open to new ideas and suggestions
  • Stay on topic


Be sure all comments and threads you post are respectful. Posts that contain any of the following content will be considered a violation of your agreement as a member of the Alpha Software Forum Community and will be moderated:
  • Spam.
  • Vulgar language.
  • Quotes from private conversations without permission, including pricing and other sales related discussions.
  • Personal attacks, insults, or subtle put-downs.
  • Harassment, bullying, threatening, mocking, shaming, or deriding anyone.
  • Sexist, racist, homophobic, transphobic, ableist, or otherwise discriminatory jokes and language.
  • Sexually explicit or violent material, links, or language.
  • Pirated, hacked, or copyright-infringing material.
  • Encouraging of others to engage in the above behaviors.


If a thread or post is found to contain any of the content outlined above, a moderator may choose to take one of the following actions:
  • Remove the Post or Thread - the content is removed from the forum.
  • Place the User in Moderation - all posts and new threads must be approved by a moderator before they are posted.
  • Temporarily Ban the User - user is banned from forum for a period of time.
  • Permanently Ban the User - user is permanently banned from the forum.


Moderators may also rename posts and threads if they are too generic or do not property reflect the content.

Moderators may move threads if they have been posted in the incorrect forum.

Threads/Posts questioning specific moderator decisions or actions (such as "why was a user banned?") are not allowed and will be removed.

The owners of Alpha Software Corporation (Forum Owner) reserve the right to remove, edit, move, or close any thread for any reason; or ban any forum member without notice, reason, or explanation.

Community members are encouraged to click the "Report Post" icon in the lower left of a given post if they feel the post is in violation of the rules. This will alert the Moderators to take a look.

Alpha Software Corporation may amend the guidelines from time to time and may also vary the procedures it sets out where appropriate in a particular case. Your agreement to comply with the guidelines will be deemed agreement to any changes to it.



Bonus TIPS for Successful Posting

Try a Search First
It is highly recommended that a Search be done on your topic before posting, as many questions have been answered in prior posts. As with any search engine, the shorter the search term, the more "hits" will be returned, but the more specific the search term is, the greater the relevance of those "hits". Searching for "table" might well return every message on the board while "tablesum" would greatly restrict the number of messages returned.

When you do post
First, make sure you are posting your question in the correct forum. For example, if you post an issue regarding Desktop applications on the Mobile & Browser Applications board , not only will your question not be seen by the appropriate audience, it may also be removed or relocated.

The more detail you provide about your problem or question, the more likely someone is to understand your request and be able to help. A sample database with a minimum of records (and its support files, zipped together) will make it much easier to diagnose issues with your application. Screen shots of error messages are especially helpful.

When explaining how to reproduce your problem, please be as detailed as possible. Describe every step, click-by-click and keypress-by-keypress. Otherwise when others try to duplicate your problem, they may do something slightly different and end up with different results.

A note about attachments
You may only attach one file to each message. Attachment file size is limited to 2MB. If you need to include several files, you may do so by zipping them into a single archive.

If you forgot to attach your files to your post, please do NOT create a new thread. Instead, reply to your original message and attach the file there.

When attaching screen shots, it is best to attach an image file (.BMP, .JPG, .GIF, .PNG, etc.) or a zip file of several images, as opposed to a Word document containing the screen shots. Because Word documents are prone to viruses, many message board users will not open your Word file, therefore limiting their ability to help you.

Similarly, if you are uploading a zipped archive, you should simply create a .ZIP file and not a self-extracting .EXE as many users will not run your EXE file.
See more
See less

Sending Individual Emails

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Sending Individual Emails

    Hi, I have been asked to design a table and form which someone will sit at the pc and phone each person in the table and ask if it's ok to email them.

    I have designed the form and used the email link on the email address field which opens up the email facility. I have saved the email document in drafts and I hoped I would be able to open the saved email document automatically which doesn't appear to be an option, the bigger problem is each time I open the email document I have to retype the subject line. I have tried entering an expression in the subject line and when I tested the email it showed the condition expression rather than the result, can anyone tell me why this would happen?

    Regards
    Judith

    #2
    Re: Sending Individual Emails

    Take a look at email templates in the webhelp.
    There can be only one.

    Comment


      #3
      Re: Sending Individual Emails

      Not sure why you're seeing expression instead of result. Perhaps posting an example or your code will help get you helped.:)

      I do something similar to what you're describing. I have a form which contains an email address field. When an email address is entered in that field, the OnDepart event gathers 2 variables, the email address just entered (veNow), and the record number for that client (veCurrentRecord). It saves the record, then it generates an email to that client. This automatically enters the email address as the recipient's address. It enters the subject line and it includes a message in the body of the email. It also attaches a report that is personalized to that client.

      I did all this with action scripting (I suck at code) but I've converted it to xbasic because I don't know how to send you the action scripting:

      'Get 'Value' property of 'Email0' in Form 'Mktg_Current_Agents' .
      DIM GLOBAL veNow AS c
      veNow = parentform:Email0.value
      'Get 'Value' property of 'Record_number' in Form 'Mktg_Current_Agents' .
      DIM GLOBAL veCurrentRecord AS n
      veCurrentRecord = parentform:Record_number.value
      'Save record in current form at parent level.
      topparent.commit()
      'Send a report, label, letter, form or browse layout as an attachment to an e-mail message. You can specify which records to send.
      'Check to see if you are running the script from within a Form
      dim flag_error as l
      flag_error = .f.
      if is_object(topparent.this) then
      p = topparent.this
      if p.class() = "Form" then
      DELETE Parameter1
      'Set the Parameter variable to the object's .value property
      Parameter1 = eval("P:Record_number.value")
      else 'Not in a Form. This is an error condition.
      flag_error = .t.
      end if
      else
      flag_error = .t.
      end if
      if flag_error then
      ui_msg_box("Error","You can only run this script from within a Form",UI_STOP_SYMBOL)
      end
      end if

      filter = "Record_number = [varN->parameter1]"
      query.filter = replace_parameters(filter,local_variables())
      query.order = ""
      to_param = a5_eval_expression("=EMAIL0.value",local_variables())
      cc_param = a5_eval_expression("",local_variables())
      bcc_param = a5_eval_expression("",local_variables())
      subject_param = a5_eval_expression("=alltrim(Agent_First_Name)+\", \"+\"here's your new fax form\"",local_variables())
      message_param = a5_eval_expression("=alltrim(Agent_First_Name)+\", "+chr(13)+chr(10)+"\"+\"Attached is a new fax form I personalized to you. I created it in Word so you can quickly and easily change it to suit your individual or specific needs. Please keep it on file and feel free to update it whenever your needs or personal info changes."+chr(13)+chr(10)+"Thanks,"+chr(13)+chr(10)+"Bill\"",local_variables())

      :Report.Send("agent fax form","RTF",query.filter,query.order,"default",to_param,subject_param,message_param,cc_param,bcc_param)


      Hope this helps or gives you other ideas.

      Comment


        #4
        Re: Sending Individual Emails

        Thank you for your help, I have had a go using Action Scripting which I haven't used before and I have put a button on the form which brings up the email complete with the subject line BUT now I have to fill in the TO field on the email.

        Bill, I looked at the xbasic you sent and I have picked out the line below:

        param_to = alltrim(a5_eval_expression(em.send_to_temp))

        Would I be right in guessing that somewhere in that line I could put the field name of the email address and it would automatically fill with the email address of the current record. Or am I being too optimistic :)

        Comment


          #5
          Re: Sending Individual Emails

          I don't see what you're referencing from my code, but what you need to do is capture the email address as a variable and insert that result into the to_param = a5_eval_expression("=EMAIL0.value",local_variables()) part of the code. In my case that is the EMAIL0 variable.

          Comment


            #6
            Re: Sending Individual Emails

            Judith, did you figure this out? I'm an Alpha rookie, and I was able to make it work this summer. I will have to dig to remember how, so if you got it, I won't. It's a very useful feature, as you can imagine.

            Hang in there.

            --Rob

            Comment


              #7
              Re: Sending Individual Emails

              Stan Mathews was kind enough to send me the following message privately. I assume Stan was trying not to embarrass me publicly. Thanks Stan.

              I believe you might be mistaken. EMAIL0 would seem to be a form field rather than a variable, hence the need to use the syntax EMAIL0.value.

              Despite Stan's valiant and considerate effort, I am an idiot.
              Email0 is a field on my form. The variable is called veNow. Course I can't remember anything about either; naming conventions, how variable was created or where it is stored, etc., but I hope this helps.

              Thanks again for your kindness Stan, but I'm OK with being a doofus, as long as I learn something from having it brought to my attention.:D



              Comment


                #8
                Re: Sending Individual Emails

                Originally posted by Bill View Post
                Despite Stan's valiant and considerate effort, I am an idiot.
                WRONG! Idiots are the one's who can't figure out that they could be wrong. We've all met them. They were the ones centuries ago that were running around saying the world was flat even after it was proven to be round. Today they're the ones saying we never actually made it to the moon. And, unfortunately, many, many, many other lesser "offenses to intelligent life." Of course, their solution to the problem is to just ignore all logic and continue insisting they are right. (I don't put myself in that category because I readily admit that I made a mistake once.:D)

                Comment


                  #9
                  Re: Sending Individual Emails

                  Sorry I haven't replied before now, it was a day off yesterday. Still trying to get my head around this, so will wade through my other work and then give my action scripting another go this afternoon. Because what I have just tried this morning didn't work

                  Comment


                    #10
                    Re: Sending Individual Emails

                    Hi,

                    Well I have spent a good 40 minutes trying things out on xbasic, I have included the following line:
                    param_to = alltrim(a5_eval_expression("=director_email.value",local_variables()))

                    When I try to run it, I get the following error message

                    Script:secondtest line:28
                    param_to = alltrim(a5_eval_expression("=director_email.value",local_variables())
                    Too many parameters

                    I can't see what the problem is in that line, any suggestions gratefully accepted.

                    Comment


                      #11
                      Re: Sending Individual Emails

                      Judith,

                      I'm sure I didn't use xbasic to do this - just action scripting; I'll check tonight and I'll get back to you on it.

                      Thanks!

                      --Rob

                      Comment


                        #12
                        Re: Sending Individual Emails

                        Originally posted by Judith View Post
                        I can't see what the problem is in that line, any suggestions gratefully accepted.
                        You can often check this sort of thing in the interactive editor window. Your construction seems sound.

                        Code:
                        EMAIL0.value = "Tom Smith"
                        
                        to_param = a5_eval_expression("=EMAIL0.value",local_variables())
                        ? to_param
                        = "Tom Smith"
                        
                        director_email.value = "Tom Smith"
                        
                        param_to = alltrim(a5_eval_expression("=director_email.value",local_variables()))
                        ? param_to
                        = "Tom Smith"
                        There can be only one.

                        Comment


                          #13
                          Re: Sending Individual Emails

                          Hi Its me again!!!! Sorry but:

                          I have used action scripting and I am nearly there (I think). I have managed to produce an email complete with subject line and message text, but the Send to:field doesn't fill in, if I were to put an expression in the Send to line would that make it pick up the email from the current form, and if that is right can someone give me a clue as to what I should type in for the expression.

                          I have attached a print of the screen shot, were I'm thinking the expression should be put.
                          I am sorry to be such a pain, but I really am right at the bottom of the learning curve.:(

                          Comment


                            #14
                            Re: Sending Individual Emails

                            Experimenting here I think all you need is

                            clcik the x-y button at the right of the Send To: box
                            enter or choose the field holding the email address (no equals sign)
                            ok out of the expression builder and you should see Alpha has filled in the equals in front of the field name

                            Should be good to go.
                            Last edited by Stan Mathews; 10-10-2008, 10:40 AM.
                            There can be only one.

                            Comment


                              #15
                              Re: Sending Individual Emails

                              Hi Stan,

                              The Expression Builder doesn't seem to like field names I only have the option of selecting from Function, Variable or Library Entry.

                              Comment

                              Working...
                              X