Posts by JimmyB

    Hi.

    I'm having issues with deleting a line of code in my ThisWorkbook Workbook open event. it worked at one time then suddenly it stopped working. It doesn't give me an error when I run the program, but it just doesn't delete the line of code, like it should. When I open the sub and step through it I get the error code "Can't enter break mode at this time." I've checked to make sure the line number matched & I want to delete only that line.
    Your help will be greatly appreciated
    If I step through the file and get the error then hit continue or end it deletes the code like it should... but does not go to "End With"
    I tried to input the line "On Error Resume Next" to try to override the error...well that line of code doesn't work on anything that I've tried.


    i've cross-posted on 2 forums. Plenty of traffic but no suggestions

    https://www.excelforum.com/exc…his-time.html#post5248130

    https://www.excelguru.ca/forum…r-break-mode-at-this-time


    If I'm doing anything that doesn't fit in with Ozgrid forum, please explain to me. The moderators are great and I want to get things right.:S

    Thanks a ton


    Here is the code:

    Yeah...still the same. anyway the problem has been solved with logits post. Sorry I didn't mean to create a peeing contest. don't want to cause any more grief...thanks for your help. I know you are acting with best intentions...signing off for now

    Thanks

    JimmyB

    Well Roy, I'm not trying to be impossible but the link that you sent me locked up my computer and i needed to reset it in task manager (I just tried it again) with the same results. The url that you just sent me, comes up with "Page not found".

    The reason that I started a new thread is because you threatened to delete my posts (Post #6) and I still needed help on the issue. (Post #5)

    Just sayin'

    Have a great day

    Sorry we can't seem to get on well

    The link is PASSWORD-FORM-7.xlsm. Tried on 2 different computers and locked up both...just dings when clicked anywhere...had to disable it with task manager

    This link opens up the page that I've attached which mentions "if I need help with the project pleas contact sales&excel-it.com" for a quotation"

    I thought that it was driven by you... Sorry my mistake.

    Anyway I really need my simple question answered that I posted in the thread post to 'Logit'. You advised that you're deleting my posts, so should I just start a new thread?

    Lot of confusion here today...sheesh


    Maybe you can help me?


    I need to delete the line "call inputbox2" on my workbook event. I found the sub to delete that line of code but I get error "Object Required" on the line...Can you please help? When it says object required I draw a blank...(my Nemesis


    Thanks so much...Sorry for the confusion. I just don't want to offend anyone


    Code
    Sub DeleteCodeLines()
    ActiveWorkbook.VBProject.VBComponents("ThisWorkbook").CodeModule.DeleteLines 42,1
    End Sub

    THANKS Roy

    JimmyB

    Hey Roy. I forgot to mention that I'm a senior on a govt pension and can't afford your recommendation to hire someone to help with the userform. I guess that is why I check on the forums for help...LOL. (just trying to keep the mind active with these projects). You said you want to delete my posts. Why is that? I really need a bit more help on this issue.

    btw. The link you sent me locked up my computer. I had to go to task manager to dump it. Anyway please let me know if I've done something to offend you. That was not my intent whatsoever

    Thanks JimmyB

    On second thought...I can't delete the sub while I'm standing in it. Right?

    I'm calling the sub Inputbox2 in my workbook open event, and actually need to delete it, directly after it has run, so It doesn't show up for a second go-round

    If that makes sense

    HELP please with the syntax

    Thanks Jimmy

    Hi. I have a program where I have an inputbox in the 'Workbook event', that prompts me to assign a password to access the file, without going through the tedium of opening the file, going through the disclaimer sheet and various hoops to get to the password area. That part works fine.

    Now what I need, is to delete this inputbox as soon as the password is inserted, otherwise anyone will get the inputbox on the "Sign In" sheet, when they open the file...then change the password to whatever.

    Here is what I have for the code. Just one line with syntax problem...I think


    Thanks so much

    Jimmy

    Ok Thanks Roy. I'm really having a hard time with this. There are sheets stated for deletion before sending. Instead of using the 'Call' feature I put the lines in the actual program. Here is the code as it stands. right now I'm getting a subscript error and the 'debug' text doesn't show as an option, so I can't say for sure where that error is. GRRRR

    Thanks again for your help.

    Hi Roy

    It's been 8 days since I last heard from you. If you read my last post, you'll see that we're so very close to solving my problem. I feel like we're one line away from ending this thing. I really need to finish this aspect of the program, before i go on much further. I just can't seem to figure it out. You've worked on this extensively and know what I'm after here. If you don't have time to look at this, please just let me know with a quick reply. It'll be like reinventing the wheel but I will need to cross-post this on a different forum...if you or no one else in this forum can help me.

    Thanks JimmyB

    Hi Roy. Hope you aren't too swamped. I'm so close to getting my program right. One problem still haunting me and I need some help. When I run the program I get the error (line just before the SEND. error= The process cannot access the file because it is being used by another process

    It is converted to xlsx as it should be and all else seems good except for this. Here's the code:

    Any help will be greatly appreciated

    THANKS Jimmy

    Well. I've been trying for a few hours to make the code work that you provided to no avail. I understand that it is hard for you to go at this, kind of blindly, but the program is about 25 or so worksheets long and interactive amongst each other, so I'm giving you information the best that I can, without creating too much fog. I did although, combine a few lines from yours to mine and have made some progress. Almost there but still a minor problem. The code now converts the file to xlsx. and deletes the sheets that I need deleted, but stops at the last second before sending. I get the error code: "Filename, Directory Name or volume label Syntax is Incorrect". This pops up just at the bottom, highlighting ".Add Attachment FilePath & FileName". I know that you can help improve to streamline the code but I really need it to work (first) LOL. Below is the adjusted code:

    Your usual patience & help will be greatly appreciated

    Thanks so much Jimmy

    (Hitting the sack. Will check back tomorrow)

    Sorry Allan,

    actually I originally posted in this forum and had no replies in the first couple of days earlier on, so I posted in The Excel F?rum. There, I'd advised them that it was cross posted, and didn't succeed with figuring out my problem, with the help that they provided, so I came back here to check if anyone responded and Roy had. In the confusion I forgot to advise Roy that I had cross posted. Sorry JimmyB

    Hi

    My CDO works fine to send my file macro enabled, but I want to convert my file to disabled macros as it is being prepared to send with the CDO. Below is the code that I used:

    I need to make this process for the user as simple as possible as my target audience that will be sending the file will be seniors sending data to their doctor. Therefore some information must be automatically deleted when the patient activates the SEND button. The program has about 25 pages each interactive and hard to explain.

    I'm getting errors in the SAVEAS area. I've tried different variations but can't figure out the syntax


    Any help will be appreciated.

    Thanks JimmyB


    Hi Roy.
    I've been digging deeper and giving a lot of thought to your recommendation. I have to agree that it would be much better, for the user to create a modified sheet before emailing it out. Now in saying that I have no idea of the path that the patient will use, I need to create code that acknowledges and saves the path chosen by the patient. I've created the code below:
    Unfortunately it is not quite working. It creates the new workbook with the name "Guest" and in xlsx format, like I want, but I get error messages that advises type mismatch
    Your usual great help will be appreciated
    Thanks Jimmy

    Hi Roy
    Sorry but that option is not what I'm looking for . I'm making this app as simple as possible for seniors that may not be computer savvy, I already am deleting certain cells with data and certain worksheets, by way of the Workbook Open event. That isn't the problem. I just need the syntax to either delete or disable all of the form control buttons, as they are not necessary (for the end user), and cause errors when the person hits them.
    Any help will be appreciated
    Jimmy