/    Sign up×
Community /Pin to ProfileBookmark

Sending an email from javascript (non web)

Hello,

My application has nothing to do with Web development, so there are no forms to be filled in.

I’m using JS to control a Windows application via its Component Object Model.
I invoke the application through its COM using a simple DOS batch script. The application generates a file which contains the date in its filename, that I want to send by email to a pre-determined email address (myself).

My first approach was to use blat, the freeware DOS smtp emailer, from the DOS script, on exit from the JS, but the problem is that I don’t know the filename, since it is date-dependent. I thought of returning the filename on exit from JS back to the invoking DOS script, and then executing blat. Is this possible?

The other option I explored was to execute blat from JS, either directly or via a DOS script. Is it possible to invoke a DOS program + parameters directly from JS?

Can I do any of this?

Many thanks,
Paul

to post a comment
JavaScript

0Be the first to comment 😎

×

Success!

Help @ppmoore spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.5,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,

tipper: @Samric24,
tipped: article
amount: 1000 SATS,
)...