home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.lang.visual.basic      MS Visual Basic discussions, NOT dot-net      10,840 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 9,801 of 10,840   
   Jack Sadie to George Bashore   
   Re: Very Newbie needs Windows start up r   
   28 Dec 05 20:57:24   
   
   From: jacksadie@btinternet.com   
      
   Right George, some success but not quite there yet.   
      
   First I managed to figure out that it would be no good trying to use the   
   Word Visual Basic Editor which is all I ever had experience of previously;   
   somehow it didn't look right !   
   Eventually I went to the Microsoft website and sussed out that I probably   
   needed to download a program called Visual Basic - (you didn't realise how   
   very very very new a newbie I am).   
      
   Managed to do that including registering my copy and then followed your   
   instructions as I thought.   
   When I pressed F5 however a message flashed up :-   
   There were build errors.  Would you like to continue and run the last   
   successful build?   
   I chose "No" because there had not been any "successful build" !   
   Then a section opened at the bottom listing 4 errors :-   
   1-3 each read "Statement not valid in a namespace" for  Lines 2, 5 and 7   
   respectively.   
   4 related to Line 29 and read "Statement cannot appear within a method body.   
   End of statement assumed.   
      
   I am a little foxed because there does not appear to be a line 29 !!  On my   
   count   
   Line 27 is "End Sub"   
      
   Are you still there or have you given up?   
   I'd like to think not.   
   --   
   VERY SINCERE  Regards, Jack Sadie   
   jaxalad-buying@yahooREMOVE.co.uk   
      
   "George Bashore"  wrote in message   
   news:7PadnegjLpn7eCzenZ2dnUVZ_tidnZ2d@comcast.com...   
   > Jack   
   > Start a new project   
   > Go to View, select Code   
   > Paste code into code window from "Option Explicit" through to "End sub".   
   > Make sure Option Explicit isn't showing twice.   
   > Change the PathAndFileName to your file for each day.   
   > Click F5 and todays tune should play.   
   >   
   > George   
   >   
   > "Jack Sadie"  wrote in message   
   > news:q82dnQavYL2QfSzenZ2dnUVZ8qKdnZ2d@pipex.net...   
   >> George   
   >> You are a dream come true !!!   
   >> Thank you very much for the trouble you have taken.   
   >> It looks great to me but I still need to understand where to lodge it.   
   >> Presumably I copy from "Option Explicit" through to "End sub" to   
   >> the clipboard and then paste it into somewhere.   
   >> But very sorry - I don't know where !!!   
   >> Am I a bit thicker than even you thought?   
   >> Big ideas but only a little   
   >> knowledge and that's a dangeropus thing.   
   >> I shall create a restore point first.   
   >> --   
   >> Regards, Jack Sadie   
   >> jaxalad-buying@yahooREMOVE.co.uk   
   >>   
   >>   
   >> "George Bashore"  wrote in message   
   >> news:TsidnW1d_KzcEC3eRVn-ig@comcast.com...   
   >>> Jack try this.   
   >>> Replace PathAndFileName with the path and file name to your wav file for   
   >>> each day of the week.   
   >>> example Call sndPlaySound("C:\sounds\startup.wav", 1)   
   >>> HTH   
   >>> George   
   >>>   
   >>>   
   >>>   
   >>> Option Explicit   
   >>> Private Declare Function sndPlaySound Lib "winmm.dll" Alias _   
   >>> "sndPlaySoundA" (ByVal FileName As String, _   
   >>> ByVal Flags As Long) As Long   
   >>> Dim myDate As String   
   >>>   
   >>> Private Sub Form_Load()   
   >>>   
   >>>    myDate = Format(Now, "dddd")   
   >>>    Debug.Print myDate   
   >>>    Select Case myDate   
   >>>    Case "Monday"   
   >>>       Call sndPlaySound("PathAndFileName", 1)   
   >>>    Case "Tuesday"   
   >>>       Call sndPlaySound("PathAndFileName", 1)   
   >>>    Case "Wednesday"   
   >>>        Call sndPlaySound("PathAndFileName", 1)   
   >>>    Case "Thursday"   
   >>>        Call sndPlaySound("PathAndFileName", 1)   
   >>>    Case "Friday"   
   >>>        Call sndPlaySound("PathAndFileName", 1)   
   >>>    Case "Saturday"   
   >>>        Call sndPlaySound("PathAndFileName", 1)   
   >>>    Case "Sunday"   
   >>>        Call sndPlaySound("PathAndFileName", 1)   
   >>>    End Select   
   >>> End Sub   
   >>>   
   >>>   
   >>>   
   >>> "Jack Sadie"  wrote in message   
   >>> news:bt6dnWQNkYlavi3enZ2dnUVZ8qmdnZ2d@pipex.net...   
   >>>>I have found out how to substitute my own wav sound for the Microsoft   
   >>>>default sound, but now I want to go a step further.   
   >>>>   
   >>>> I want to create 7 different wave files and have a different one open   
   >>>> according to the day of the week - the "monday.wav" opening on Mondays   
   >>>> and the "tuesday.wav" on Tuesdays and so on.   
   >>>>   
   >>>> It looks to me as if I need to have a routine created which I don't   
   >>>> have   
   >>>> the expertise to do. And if I had a vb routine I wouldn't know how to   
   >>>> employ it on my computer.   
   >>>>   
   >>>> Can any kind person assist or point me in the right direction if this   
   >>>> is   
   >>>> the wrong ng.   
   >>>> Thanks so much   
   >>>> --   
   >>>> Regards, Jack Sadie   
   >>>> jaxalad-buying@yahooREMOVE.co.uk   
   >>>>   
   >>>   
   >>>   
   >>   
   >>   
   >>   
   >   
   >   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca