Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
HardQuestionPossibly ?!
#1
Me and my friend are working on a project where we are using two computers to communicate via QM by sending messages through email!

Im able to make a hot key that when a person enters info into the " edit " boxes, i can have it send those ' Variables ' directly to a " NotePad "

with out any problem at all!

How ever! My problem im trying to figure out is how to get those " Variables " from the " edit " boxes into a email and have that email go to

the emailers address that they have programmed in there! I hope this makes sense and if not, i will try my best to give a better description

but i think i explained it pretty well! If there is a code that this can be done on? Would someone be as kind enough to post it for me!

Perhap's: To use it as a reference!

Thanks, Bob
#2
Look into the floating toolbar, Files/web menu.
#3
Would it be possible to have a view of what that would look like Gintaras so that away, i could use it as a reference and build upon it!

I have an idea of how to make it ,but to save the headaches and troubles, i'd admire ur expertise of a description if possible.

I just need a clear view because im only using 2 variables, for example:

Name: Oranges
Last Name: Apples

And i want to send those variables to an email !

Thanks alot! I appreciate your help!
#4
Macro Macro1182
Code:
Copy      Help
;variables
str Name="Oranges"
str Last_Name="Apples"
;format text
str s.format("Name: %s[]Last Name: %s[]" Name Last_Name)
;the following inserted by the dialog
_s=s; _s.escape(9)
run _s.from("mailto:[email protected]?subject=hello" "&body=" _s)
#5
Alright that wasnt quite what i was expecting to see as a code but im willing to know and understand on how to accomplish this!

Alright, so far i got this as the Main Dialog i've made to work with the code you gave me! Well attempted at that!


ViaComp ( Is the main Dialog Name to it )


Quote:\Dialog_Editor
function# hDlg message wParam lParam
if(hDlg) goto messages
str controls = "3 4"
str e3 e4
if(!ShowDialog("ViaComp" &ViaComp &controls)) ret

BEGIN DIALOG
0 "" 0x90C80A44 0x100 0 0 223 94 "-ViaComp-"
2 Button 0x54030000 0x4 144 56 64 24 "Cancel"
3 Edit 0x54070080 0x200 24 14 96 14 ""
7 Button 0x54032000 0x0 144 8 64 24 "Start"
4 Edit 0x54070080 0x200 24 60 96 14 ""
12 Static 0x54000011 0x20000 192 26 1 40 ""
11 Static 0x54000011 0x20000 62 16 1 53 ""
10 Static 0x54000010 0x20000 74 66 92 1 ""
9 Static 0x54000010 0x20000 70 20 92 2 ""
8 Static 0x54000011 0x20000 160 24 1 39 ""
6 Button 0x54020007 0x0 14 46 118 36 "Last Name:"
5 Button 0x54020007 0x0 14 2 118 36 "Name:"
END DIALOG
DIALOG EDITOR: "" 0x203000D "" "" ""

ret
messages
sel message
case WM_INITDIALOG
case WM_DESTROY
case WM_COMMAND goto messages2
ret
messages2
sel wParam
case 7
mac "ViaEmail"
case IDCANCEL
ret 1




ViaEmail ( Is the mac "ViaEmail" name )


Quote:;variables
str Name="Oranges"
str Last_Name="Apples"
;format text
str s.format("Name: %s[]Last Name: %s[]" Name Last_Name)
;the following inserted by the dialog
_s=s; _s.escape(9)
run _s.from("mailtoConfused[email protected]?subject=hello" "&body=" _s)





I can subsquently get the variables from the " Name and Lastname " to where i want them but when to have them sent in an email, im stumped on how to write it!



Where it says, ' Name: ' Im trying to have what ever is written in there and what ever is written in ' Lastname: ' having them sent automatically ONCE you click the " Start " button!

I noticed the code you gave me, opens " Outlook Express ". I forgot to mention that instead of using something visible like that! What im trying to make is something that is not visible BUT is still sends the info in the email of what ever is written in " Name & Lastname variables ".


I just need some help because this is alittle more advanced than i was reckoning for. lol


I thank you so much for taking your time to read and help me! Thank You !!
#6
To pass text from dialog to ViaEmail: use getwintext to get text from the controls, and then pass the variables to ViaEmail as arguments.

To send email without an email program, use SendMail function. A dialog for it available in the floating toolbar.


Forum Jump:


Users browsing this thread: 1 Guest(s)