CodeCharge Studio
search Register Login  

Web Reports

Visually create Web Reports in PHP, ASP, .NET, Java, Perl and ColdFusion.
CodeCharge.com

YesSoftware Forums -> CodeCharge Studio -> ASP

 Parsing forms for sending as email

Print topic Send  topic

Author Message
Sergeant Pepper
Posted: 08/01/2005, 11:23 AM

dear all,

i am using CCS 2.3, ASP, Oracle 9.2.
I have a kind of order detail forms, which I want to send as an html email.
In CS there is a function which parses a form. The output could be stored
in an ASP variable.
How can I do this in CCS?

The email should be send to a person for an approval and the person should
see all header and all details.

Sending an email after inserting is not the question. But how to get the
html output of these two forms in an ASP variable?

Many thanks in advance
Stephan
DonB
Posted: 08/01/2005, 1:04 PM

For a Record form, there is no single variable/array containing all the form
data that was POSTed, although ASP provides the Request.Form collection that
does have all of the data. It is indexed by field name. You can Google
"Request.Form AND ASP" to find out all the details or just go to
msdn.microsoft.com and look there.

For cases where you want data from a specific field, just ask for it with
the CCGetFromPost() function. No need to do anything more complex to access
the values.

--
DonB

http://www.gotodon.com/ccbth


"Sergeant Pepper" <serpep@gmx.de> wrote in message
news:1m2q2cr114b5q.qyaij5fzssq$.dlg@40tude.net...
> dear all,
>
> i am using CCS 2.3, ASP, Oracle 9.2.
> I have a kind of order detail forms, which I want to send as an html
email.
> In CS there is a function which parses a form. The output could be stored
> in an ASP variable.
> How can I do this in CCS?
>
> The email should be send to a person for an approval and the person should
> see all header and all details.
>
> Sending an email after inserting is not the question. But how to get the
> html output of these two forms in an ASP variable?
>
> Many thanks in advance
> Stephan

Walter Kempees
Posted: 08/01/2005, 2:09 PM

I think I read somewhere that the whole form could be used as the body of an
email, data + layout using the whole template.
I have to dive into the post, but will give it a shot.
I'll be back.

Walter
"DonB" <~ccbth~@gotodon.com> schreef in bericht
news:dclv7k$or3$1@news.codecharge.com...
> For a Record form, there is no single variable/array containing all the
> form
> data that was POSTed, although ASP provides the Request.Form collection
> that
> does have all of the data. It is indexed by field name. You can Google
> "Request.Form AND ASP" to find out all the details or just go to
> msdn.microsoft.com and look there.
>
> For cases where you want data from a specific field, just ask for it with
> the CCGetFromPost() function. No need to do anything more complex to
> access
> the values.
>
> --
> DonB
>
> http://www.gotodon.com/ccbth
>
>
> "Sergeant Pepper" <serpep@gmx.de> wrote in message
>news:1m2q2cr114b5q.qyaij5fzssq$.dlg@40tude.net...
>> dear all,
>>
>> i am using CCS 2.3, ASP, Oracle 9.2.
>> I have a kind of order detail forms, which I want to send as an html
> email.
>> In CS there is a function which parses a form. The output could be stored
>> in an ASP variable.
>> How can I do this in CCS?
>>
>> The email should be send to a person for an approval and the person
>> should
>> see all header and all details.
>>
>> Sending an email after inserting is not the question. But how to get the
>> html output of these two forms in an ASP variable?
>>
>> Many thanks in advance
>> Stephan
>
>

Sergeant Pepper
Posted: 08/01/2005, 10:53 PM

Am Mon, 1 Aug 2005 23:09:27 +0200 schrieb Walter Kempees:

> I think I read somewhere that the whole form could be used as the body of an
> email, data + layout using the whole template.
> I have to dive into the post, but will give it a shot.
> I'll be back.
>
> Walter

Walter,

that's exactly what I need.
@Don: Sorry for my broken english but I want to use the output after
parsing with all the layout and data to be send as an email body.

many thanks
Stephan
KK
Posted: 08/01/2005, 11:48 PM

Hi,

I wrote similar thing earlier. I used HTMLTemplate global variable to retrieve HTML produces when showing some form. For instance if you want to use HTML produced by showing articles grid contents use:
HTMLTemplate.GetVar("Grid articles")

This retrieves HTML of a grid called articles. This is only available after grid has been shown, so for instance you may put code using this HTML in some later form's BeforeShow event, for instance:
NewRecord2.TextArea1.Value = HTMLTemplate.GetVar("Grid articles")

To retrieve form's contents in different event (for instance OnClick) you will have to add few "magic" rows to initialize templates:
  
Set HTMLTemplate = new clsTemplate  
Set HTMLTemplate.Cache = TemplatesRepository  
HTMLTemplate.LoadTemplate ScriptPath & TemplateFileName  
articles.Show HTMLTemplate.Block("main")  

now

HTMLTemplate.GetVar("Grid articles")

will retrieve grid's HTML which you may use when constructing your email body.

Good luck!
KK
Sergeant Pepper
Posted: 08/02/2005, 10:21 PM

@all:
Many thanks for excellent tipps.

@KK:
I've just tested your solution and it works great.
Many thanks

Best Stephan
mramirez18

Posts: 56
Posted: 11/10/2005, 9:15 PM

Can you email me your example to look at what you did, I am looking for something similar.

Cheers
View profile  Send private message
KK
Posted: 11/11/2005, 7:33 AM

Basically the whole example is just composed of the code above.
I've just created a prototype to prove it's feasible.

Add new topic Subscribe to topic   


These are Community Forums for users to exchange information.
If you would like to obtain technical product help please visit http://support.yessoftware.com.

MS Access to Web

Convert MS Access to Web.
Join thousands of Web developers who build Web applications with minimal coding.

CodeCharge.com

Home   |    Search   |    Members   |    Register   |    Login


Powered by UltraApps Forum created with CodeCharge Studio
Copyright © 2003-2004 by UltraApps.com  and YesSoftware, Inc.