<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Message Box in Inventor Programming Forum</title>
    <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865720#M155973</link>
    <description>Actually after I posted, it dawned on me that you would probably want to &lt;BR /&gt;
have all the image boxes turn on all at once and then change the back color &lt;BR /&gt;
as it progresses.  That way the user would see how far from the end he is. &lt;BR /&gt;
Same basic concept though.&lt;BR /&gt;
&lt;BR /&gt;
-- &lt;BR /&gt;
___________________&lt;BR /&gt;
Kent Keller&lt;BR /&gt;
www.kwikmcad.com</description>
    <pubDate>Tue, 23 Jan 2007 17:35:50 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2007-01-23T17:35:50Z</dc:date>
    <item>
      <title>Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865707#M155960</link>
      <description>Hi All, &lt;BR /&gt;
&lt;BR /&gt;
I have an application that takes a couple of seconds to run (approx. 30-40 seconds, it has a lot of code to iterate thru) (plus i'm not the best programmer) what I want to do is have a msgbox up on the screen stating to wait a second then have it automatically switch off at the end of the process. Is there a way to do this? right now the code stops for me to hit the "OK" button. I was also trying to avoid making another userform and firing it.Any help would be appreciated...&lt;BR /&gt;
&lt;BR /&gt;
Thanks, &lt;BR /&gt;
Bill</description>
      <pubDate>Wed, 17 Jan 2007 23:01:27 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865707#M155960</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-17T23:01:27Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865708#M155961</link>
      <description>You'll need to make another form.  A message box is modal, which means &lt;BR /&gt;
everything stops and waits for it to be dismissed.  For your own forms you &lt;BR /&gt;
can choose whether they're modal or modeless.  You'll want a modeless form.&lt;BR /&gt;
-- &lt;BR /&gt;
Brian Ekins&lt;BR /&gt;
Autodesk Inventor API&lt;BR /&gt;
&lt;BR /&gt;
&lt;BKLINE&gt; wrote in message news:5455201@discussion.autodesk.com...&lt;BR /&gt;
Hi All,&lt;BR /&gt;
&lt;BR /&gt;
I have an application that takes a couple of seconds to run (approx. 30-40 &lt;BR /&gt;
seconds, it has a lot of code to iterate thru) (plus i'm not the best &lt;BR /&gt;
programmer) what I want to do is have a msgbox up on the screen stating to &lt;BR /&gt;
wait a second then have it automatically switch off at the end of the &lt;BR /&gt;
process. Is there a way to do this? right now the code stops for me to hit &lt;BR /&gt;
the "OK" button. I was also trying to avoid making another userform and &lt;BR /&gt;
firing it.Any help would be appreciated...&lt;BR /&gt;
&lt;BR /&gt;
Thanks,&lt;BR /&gt;
Bill&lt;/BKLINE&gt;</description>
      <pubDate>Thu, 18 Jan 2007 07:50:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865708#M155961</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-18T07:50:49Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865709#M155962</link>
      <description>Or how about changing the mouse pointer to an hourglass while the iteration is running?</description>
      <pubDate>Thu, 18 Jan 2007 11:39:39 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865709#M155962</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-18T11:39:39Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865710#M155963</link>
      <description>Why not use a progress bar?&lt;BR /&gt;
&lt;BR /&gt;
-- &lt;BR /&gt;
T. Ham&lt;BR /&gt;
CAD Automation &amp;amp; Systems Administrator&lt;BR /&gt;
CDS Engineering BV&lt;BR /&gt;
&lt;BR /&gt;
HP xw4300 Workstation&lt;BR /&gt;
Dual Pentium XEON 3.6 Ghz&lt;BR /&gt;
4 GB SDRAM&lt;BR /&gt;
NVIDIA QUADRO FX 3450/4000 SDI (Driver = 8.4.2.6)&lt;BR /&gt;
250 GB SEAGATE SATA Hard Disc&lt;BR /&gt;
3Com Gigabit NIC&lt;BR /&gt;
&lt;BR /&gt;
Windows XP Professional SP2&lt;BR /&gt;
Autodesk Inventor Series 10 SP3a&lt;BR /&gt;
--</description>
      <pubDate>Thu, 18 Jan 2007 12:49:48 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865710#M155963</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-18T12:49:48Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865711#M155964</link>
      <description>I keep meaning to try one of those but have never got round to it..</description>
      <pubDate>Thu, 18 Jan 2007 14:23:40 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865711#M155964</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-18T14:23:40Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865712#M155965</link>
      <description>Thanks for the replies.... I kind of figured that I could not use a standard msgbox. I think using an hour glass is a good idea, I think I know how to change the cursor to an hour glass. How do I use/construct a progress bar? I have another question, is there a way that you can turn off the visibility of my userform while my modual is running? I used &lt;BR /&gt;
&lt;BR /&gt;
"User_Form_Part_Selection_V1.hide"&lt;BR /&gt;
&lt;BR /&gt;
It seems that the code runs to fast for it to actually hide, it's like the switch does not have time to execute.... It hides if I step thru the code. Thanks for the help!&lt;BR /&gt;
&lt;BR /&gt;
Bill</description>
      <pubDate>Thu, 18 Jan 2007 14:41:02 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865712#M155965</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-18T14:41:02Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865713#M155966</link>
      <description>See attachment!&lt;BR /&gt;
&lt;BR /&gt;
-- &lt;BR /&gt;
T. Ham&lt;BR /&gt;
CAD Automation &amp;amp; Systems Administrator&lt;BR /&gt;
CDS Engineering BV&lt;BR /&gt;
&lt;BR /&gt;
HP xw4300 Workstation&lt;BR /&gt;
Dual Pentium XEON 3.6 Ghz&lt;BR /&gt;
4 GB SDRAM&lt;BR /&gt;
NVIDIA QUADRO FX 3450/4000 SDI (Driver = 8.4.2.6)&lt;BR /&gt;
250 GB SEAGATE SATA Hard Disc&lt;BR /&gt;
3Com Gigabit NIC&lt;BR /&gt;
&lt;BR /&gt;
Windows XP Professional SP2&lt;BR /&gt;
Autodesk Inventor Series 10 SP3a&lt;BR /&gt;
--</description>
      <pubDate>Thu, 18 Jan 2007 14:58:19 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865713#M155966</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-18T14:58:19Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865714#M155967</link>
      <description>Teun, &lt;BR /&gt;
&lt;BR /&gt;
Thanks for the snippet of code... I unfortunately don't have VB, I only have VBA with IV. Thanks for the info. though.&lt;BR /&gt;
&lt;BR /&gt;
Bill</description>
      <pubDate>Thu, 18 Jan 2007 15:25:06 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865714#M155967</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-18T15:25:06Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865715#M155968</link>
      <description>Bill,&lt;BR /&gt;
&lt;BR /&gt;
Fortunately for you the code of the example is also easily to read by opening the vbp file with notebook.&lt;BR /&gt;
You can changes the status of the progressbar by raising the value in once or with steps by placing these raises in different parts of your code. &lt;BR /&gt;
When iterating through lists using For Each you cain raise the value with each lines of the list.&lt;BR /&gt;
&lt;BR /&gt;
Matthijs</description>
      <pubDate>Tue, 23 Jan 2007 13:42:49 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865715#M155968</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-23T13:42:49Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865716#M155969</link>
      <description>Matthijs, &lt;BR /&gt;
&lt;BR /&gt;
Thanks for the reply. I was going simply off of what one of the IT guy's here told me. He has VB programming training, he told me that I could not do it in VBA. I do not have a lot of seat time programming (on in IV's VBA) and I am learning everyday. I did open the files with notepad and can follow the logic behind the code. I'm not sure I fully understand how to modify the code to work for me. I might be off on this but if I read the code loosely (not knowing VB) do it work like this...&lt;BR /&gt;
&lt;BR /&gt;
when the start button is clicked it creates a userform setting the properties, then sets the properties of the "progressbar". then it would seem to iterate through a loop where the progress bar increases by 1 until it completes the loop, then evokes a msgbox "Done!"? &lt;BR /&gt;
&lt;BR /&gt;
I think I kind of understand what it is doing even if my description is not that clear, what I'm fuzzy on is how do you increase "the little blue bar" by 1 in VBA and I'm not sure what you were referring to with "You can changes the status of the progressbar by raising the value in once or with steps by placing these raises in different parts of your code. "&lt;BR /&gt;
&lt;BR /&gt;
Thanks for your help&lt;BR /&gt;
Bill</description>
      <pubDate>Tue, 23 Jan 2007 14:06:47 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865716#M155969</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-23T14:06:47Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865717#M155970</link>
      <description>Bill, &lt;BR /&gt;
Maybe your IT guy has just got the basic VBA training. When in MS VBA screen select Tools--&amp;gt;Additional Controls and select Microsoft Prograssbar Control 6.0. This will add this function in your toolbar. So it seems to me like you can use it.&lt;BR /&gt;
&lt;BR /&gt;
I have copied the example from Teun into VBA and added an extra button. The first is when used something like "For Each", it raises the bar smoothly. The second button illustrates a less smooth raise, but raises the value with steps.&lt;BR /&gt;
&lt;BR /&gt;
Matthijs</description>
      <pubDate>Tue, 23 Jan 2007 15:13:23 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865717#M155970</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-23T15:13:23Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865718#M155971</link>
      <description>very easy way, use the status bar&lt;BR /&gt;
&lt;BR /&gt;
-----------------------------------------------------------------&lt;BR /&gt;
&lt;BR /&gt;
' Get the Inventor Object, if Inventor is not running, start the application&lt;BR /&gt;
'&lt;BR /&gt;
Public Function GetInventor(Optional bCreateApp As Boolean = True) As Inventor.Application&lt;BR /&gt;
&lt;BR /&gt;
On Error Resume Next&lt;BR /&gt;
Set GetInventor = GetObject(, "Inventor.Application")&lt;BR /&gt;
If Err Then&lt;BR /&gt;
    Err.Clear&lt;BR /&gt;
    &lt;BR /&gt;
    If bCreateApp Then&lt;BR /&gt;
    ' ask user to start Inventor&lt;BR /&gt;
        Dim iAns As Integer&lt;BR /&gt;
        iAns = MsgBox("Inventor is not currently running.  Would you like to start the program?", vbYesNo)&lt;BR /&gt;
    &lt;BR /&gt;
        If iAns = vbYes Then&lt;BR /&gt;
            Set GetInventor = CreateObject("Inventor.Application")&lt;BR /&gt;
            If Not GetInventor Is Nothing Then&lt;BR /&gt;
                GetInventor.visible = True&lt;BR /&gt;
            End If&lt;BR /&gt;
        End If&lt;BR /&gt;
    Else&lt;BR /&gt;
        Set GetInventor = Nothing&lt;BR /&gt;
    End If&lt;BR /&gt;
    &lt;BR /&gt;
End If&lt;BR /&gt;
On Error GoTo 0&lt;BR /&gt;
&lt;BR /&gt;
End Function&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
Public Sub MyMacro()&lt;BR /&gt;
&lt;BR /&gt;
Dim oIV as Inventor.Application&lt;BR /&gt;
Set oIV = GetInventor&lt;BR /&gt;
&lt;BR /&gt;
Dim sStatus as String&lt;BR /&gt;
set sStatus = oIV.StatusBarText  'save old status text&lt;BR /&gt;
oIV.StatusBarText = "Running macro, please wait..."&lt;BR /&gt;
&lt;BR /&gt;
' do macro&lt;BR /&gt;
&lt;BR /&gt;
oIV.StatusBarText = sStatus  'put original status text back&lt;BR /&gt;
&lt;BR /&gt;
End Sub</description>
      <pubDate>Tue, 23 Jan 2007 15:46:29 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865718#M155971</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-23T15:46:29Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865719#M155972</link>
      <description>I am not sure it is 100% legal to use the progress bar in VBA, and maybe&lt;BR /&gt;
that is why the IT guy said you can't do it.&lt;BR /&gt;
&lt;BR /&gt;
Here is a way to fake it in VBA.... it is a little more work, especially&lt;BR /&gt;
since VBA doesn't do arrays of controls, but ... for what its worth.&lt;BR /&gt;
&lt;BR /&gt;
-- &lt;BR /&gt;
___________________&lt;BR /&gt;
Kent Keller&lt;BR /&gt;
www.kwikmcad.com&lt;BR /&gt;
&lt;BR /&gt;
&lt;BR /&gt;
&lt;BKLINE&gt; wrote in message news:5460533@discussion.autodesk.com...&lt;BR /&gt;
Matthijs,&lt;BR /&gt;
&lt;BR /&gt;
Thanks for the reply. I was going simply off of what one of the IT guy's&lt;BR /&gt;
here told me. He has VB programming training, he told me that I could not do&lt;BR /&gt;
it in VBA. I do not have a lot of seat time programming (on in IV's VBA) and&lt;BR /&gt;
I am learning everyday. I did open the files with notepad and can follow the&lt;BR /&gt;
logic behind the code. I'm not sure I fully understand how to modify the&lt;BR /&gt;
code to work for me. I might be off on this but if I read the code loosely&lt;BR /&gt;
(not knowing VB) do it work like this...&lt;BR /&gt;
&lt;BR /&gt;
when the start button is clicked it creates a userform setting the&lt;BR /&gt;
properties, then sets the properties of the "progressbar". then it would&lt;BR /&gt;
seem to iterate through a loop where the progress bar increases by 1 until&lt;BR /&gt;
it completes the loop, then evokes a msgbox "Done!"?&lt;BR /&gt;
&lt;BR /&gt;
I think I kind of understand what it is doing even if my description is not&lt;BR /&gt;
that clear, what I'm fuzzy on is how do you increase "the little blue bar"&lt;BR /&gt;
by 1 in VBA and I'm not sure what you were referring to with "You can&lt;BR /&gt;
changes the status of the progressbar by raising the value in once or with&lt;BR /&gt;
steps by placing these raises in different parts of your code. "&lt;BR /&gt;
&lt;BR /&gt;
Thanks for your help&lt;BR /&gt;
Bill&lt;/BKLINE&gt;</description>
      <pubDate>Tue, 23 Jan 2007 17:33:40 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865719#M155972</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-23T17:33:40Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865720#M155973</link>
      <description>Actually after I posted, it dawned on me that you would probably want to &lt;BR /&gt;
have all the image boxes turn on all at once and then change the back color &lt;BR /&gt;
as it progresses.  That way the user would see how far from the end he is. &lt;BR /&gt;
Same basic concept though.&lt;BR /&gt;
&lt;BR /&gt;
-- &lt;BR /&gt;
___________________&lt;BR /&gt;
Kent Keller&lt;BR /&gt;
www.kwikmcad.com</description>
      <pubDate>Tue, 23 Jan 2007 17:35:50 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865720#M155973</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-23T17:35:50Z</dc:date>
    </item>
    <item>
      <title>Re: Message Box</title>
      <link>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865721#M155974</link>
      <description>Guy's, &lt;BR /&gt;
&lt;BR /&gt;
Thanks for all of the input... This is one of those things that now that I can see how easily it can be accomplished. In my working with VBA I have learned enough to accomplish the tasks I want to automate, unfortunately that does not allow the opportunity to branch out an figure other things out. I would have never thought of either of these progress bars. Thanks for sharing... I have a couple more questions... I'll save them for a new post after I do a search. I am working a project deadline so it may be a few day's...&lt;BR /&gt;
&lt;BR /&gt;
Thanks again, &lt;BR /&gt;
Bill</description>
      <pubDate>Wed, 24 Jan 2007 14:07:56 GMT</pubDate>
      <guid>https://forums.autodesk.com/t5/inventor-programming-forum/message-box/m-p/1865721#M155974</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2007-01-24T14:07:56Z</dc:date>
    </item>
  </channel>
</rss>

