Expiring Today—Celebrate National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

popup advertisements

Posted on 2004-04-22
5
Medium Priority
?
337 Views
Last Modified: 2010-04-17
what i m trying to do is like a popup , which means , i will put a file into the user's computer , i will write it on my way
<!--
open url http://www.yahoo.com after 20 minutes
open url http://www.hotmail.com after 40 minutes
if Os = 2000 , 2003, or xp then
execute some code lines
--!>
but this script must be exe , no maro in which langage it must be.
and when the execution finishs , it must reload again
thanks
0
Comment
Question by:skynoc
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
5 Comments
 
LVL 28

Expert Comment

by:peakpeak
ID: 10890335
You're actually trying to plant an executable file on someone else's computer? (or execute something of YOUR choice on someone else's computer?)
That is exactly what virus writers (try to) do ....

Regards
Peter
0
 

Author Comment

by:skynoc
ID: 10891724
actually i m not planning to make a virus
but some advertisements for a local workgroup
i will install this file manually into each computer
that's all
it is a netcaffe
0
 
LVL 28

Expert Comment

by:peakpeak
ID: 10891758
Ok
0
 
LVL 2

Accepted Solution

by:
funvill earned 2000 total points
ID: 10895983
In MFC its easy

in the OnInitDialog() function put your timers

      SetTimer(1, 1000*60*60*30, NULL); // 30 min
      SetTimer(2, 1000*60*60*60, NULL); // 60 min
      SetTimer(3, 1000*3, NULL); // 3 sec

int the OnTimer() function put your urls

      if( nIDEvent == 1 ) // every 30 min
      {
            ShellExecute(NULL, "open", "http://www.yahoo.com", NULL, NULL, SW_SHOWNORMAL);
      }
      else if ( nIDEvent == 2 ) // every 60 min
      {
            ShellExecute(NULL, "open", "http://www.hotmail.com", NULL, NULL, SW_SHOWNORMAL);
      }
      else if  ( nIDEvent == 3 ) // every 3 sec
      {
            ShellExecute(NULL, "open", "http://www.funvill.com", NULL, NULL, SW_SHOWNORMAL);
      }



Hope this helps.
0
 
LVL 8

Expert Comment

by:rajaloysious
ID: 10896464
VB is still easier as it is a RAD.
You can use timers.
Also the development time would be fast.
Use Shell command to execute anything you do from the command prompt.
Timer control is there for your use.

Also you will not get GPFs or any crashes especially if you are new to MFC.

VB is the best tool in my opinion. Thanks
0

Featured Post

New benefit for Premium Members - Upgrade now!

Ready to get started with anonymous questions today? It's easy! Learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Make the most of your online learning experience.
What do responsible coders do? They don't take detrimental shortcuts. They do take reasonable security precautions, create important automation, implement sufficient logging, fix things they break, and care about users.
Simple Linear Regression
Six Sigma Control Plans

730 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question