Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations waross on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

Balloon Note macro 3

Status
Not open for further replies.
Sylvia,

Thanks for your response. It looks like you have already figured out a good routine for using this macro. Everybody will be a little different. Adding the parentheses to the Quantity Text type was not easy. Maybe I'll be able to clean it up in the future.

Also thank you very much for noticing my spelling error. You have found one of my weaknesses :) . I left out the "c" about 40 times throughout the code. It's been fixed for the release version.

One thing I was curious about - If you were to start Balloon Note and, while leaving it open, you pick on different Item Balloons - does the Quantity Box update to the proper quantity for that balloon?

Thanks Again


Tobin Sparks
 
Tobin –
The qty. does update with the note open, but it seems to be hanging onto the previous distance.

Procedure:
Place balloons.
Open note. All distances are zero.
Click 1st balloon, qty = 5, .385, .446 (should be .342)
Click 2nd balloon, qty = 20, .385, .342 (should be .446)
Click 3rd balloon, qty = 5, .385, .446
Click 4th balloon, qty = 10, .385, .342

I also tried to add a sub-assy to the assy and it updated perfectly.
Sylvia
 
Howdy All,

Sylvia - thank you so much for your input. You are right of course. It wasn't functioning the way it was designed. There is so much going on in this code sometimes I'm watching for one thing to work and don't notice something else that suddenly isn't. Your help is very much appreciated.

Attached is the latest "working" copy of the Balloon Note macro.

I would appreciate any comments you may have after looking this over.

Thanks Again

Tobin Sparks
www.nov.com
 
 http://files.engineering.com/getfile.aspx?folder=4d3a9b2b-9450-40df-8edb-edabb4e534a7&file=BalloonNote.zip
Tobin
Sorry it took so long to check out the final macro. I have uploaded my observations. Something seems to have happened between the 7/15 & 7/16 macros with the beginning parenthese.
Also, is there something I can tweak in the macro to get a default of .300 on the left side or must I change it each time?
Something else I stumbled onto, that perhaps was already known by others, if you hold down the alt key you can move the parts separately if they get out of whack.
Again, thanks for making this macro.
Sylvia
 
 http://files.engineering.com/getfile.aspx?folder=51e8cdd3-8fd7-4f48-85e2-6012c75e4c6c&file=Assem3.pdf
Howdy!

Thanks Sylvia and Matt for your comments regarding the Balloon Note macro.

I've been using it too and noticed it doesn't recognize the Balloon as a Note or a Balloon if I try to use it on a Balloon that has a leader with a jog point added. I'll have to work on that. It's also not as consistent as I would like. I'll need to work on the code for version 2. :)

Sylvia - your PDF is an excellent visual explanation of your findings. Thanks for your effort. You are right about the space between the left parenthesis and the number. If I remember right ( :) that doesn't happen often) I did reduce the space so the user could adjust it better. The setting for that space is on the Options page. Pick the Options button from the main macro page, then the Quantity Text (Auto) radio button and the (With Parenthesis) check box. Notice the "Add Space Between left Parenthesis and Quantity" box becomes active. The default 0.00394 may be excessive and 0.00000 may not be enough. 0.002 might work for you - you'll have to experiment a little. Don't forget to save your setting. The macro will remember your last saved setting even after you close the macro.

Now - as far as the other Space setting - how comfortable are you with opening the macro with the macro editor and making changes to the code just for your particular use? The really hard thing about this macro was trying to make it work for so many different possible font types and sizes. A calculation for the font Width has to be created based on the font height. What works for one font may be close but just not quite right for another. Let me know how you feel about changing your code.

Thanks

Tobin Sparks
 
Tobin-
After check the Option page, I found that I had changed that setting to .003 for the 7/15 macro. By rechecking default for the 7/16 macro the parenthese did reset itself, but I did play around with it and no matter what other spacing (.002, .006, .009) it remained the same as what was shown in the pdf. I'm satisfied, so you don't have to fix it for me. Just thought you'd like to know.

I have looked at the code, but didn't know where to start. I use 12pt-regular-Century Gothic. If you can point me in the right direction I can hopefully make the adjustment.

I know that this must have taken alot of work to make it compatible for everyone, so thanks again. Sylvia
 
Sylvia,
Thanks for getting back to me. I was at home on Tuesday because of what turned out to be a Kidney Stone :-( .

Anyway - I forgot to comment on something you wrote earlier: <if you hold down the alt key you can move the parts separately if they get out of whack> WOW - that's really handy - you know this better than I do :) . I'll have to include that handy hint in the revised description. THANKS!

You wrote <I did play around with it and no matter what other spacing (.002, .006, .009) it remained the same as what was shown in the pdf>. Since you mentioned it I did some more experimenting with this my self and noticed something else I have to fix in version 2. This is something to watch out for. If the Default Parenthesis Space check box is checked the user can still enter a different Space in the box. It appears that the user has entered a new Space but if the Default Parenthesis Space check box is checked it will NOT save the new Space the user has entered. OOPS.
I’ll have to fix that. Thanks for pointing that out.

Following are instruction for you to change your code:
(This might work better for your 12pt-regular-Century Gothic)
First make a copy of your macro so you can get back to where you are now just incase my instructions are not clear.
Open a Solidworks .slddrw file – maybe something you use to experiment with that has Balloons.
From the pull-down menu select Tools->Macro->Edit…
Select BalloonNote.swp. This should open the Macro Editor with a bunch of windows in it. Try to find the one that says “BalloonNote – frmBalloonNoteText (Code)” on the title bar at the top. Make this window highlighted or bring it to the front of all the other windows.
From the Microsoft Visual Basic pull-down menu select Edit->Find. The Find dialog box should appear.
On the Find dialog box select the Replace… button. The title of the box should change to Replace instead of Find and there should be a place to enter text for “FindWhat:” and “Replace With:”
In the “FindWhat:” box enter [.85] without the brackets.
In the “Replace With:” box enter [.65] without the brackets.
In the Search frame select Current Module.
All the other boxes should be Un-Checked and the Direction can be set to All.
Select the Replace button ONE time. You should get a line of code that looks like this: QCharOffset = (QCharCnt * swNoteFntmm * 0.85) with the .85 highlighted.
Select the Replace button four more times. You should notice the .85 being changed to .65. After the fourth change you should get a Visual Basic Notice that says “The specified region has been searched.”
Select OK, Save your work and Cancel the Replace box.
You should be able to experiment on the .slddrw that you originally opened.
If [.65] doesn’t quite make to for you – you can follow the above instructions and substitute anything you might think will work for the .65.

Thanks Again for you input – I hope this helps


Tobin Sparks
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor