|
Looks good. I'm just glad to have been of some guidance.
What exactly are you building, if you don't mind my asking? I sounds like a Notepad substitute, if it is, I like the tabbed approach.
|
|
|
|
|
That is exactly what I am building. I work in a firm where I have to take lots of phnoe calls and remember lots of little side notes. I am using this to build a Notepad Substitute. Each new tab will have a time and date stamp on the top of the tab so that I know when I jotted in it. I will also be able to save each tab individually and set the opacity so that I can compare with stuff behind it without having to switch back and forth. I am using VS.NET 2005 Beta to develope it so You have to download the new .NET Framework 2.0.?? beta as well to run the apps. If you are interested I will send you the source so you can peruse it. I will put it up on some free site when I am done as well if you would rather wait.
Thanks again for the tips,
Taen Karth
|
|
|
|
|
Yes I'd love to see what you have so far, and maybe I can be of some assistance. I'm always looking for new challenges. Also, I have been looking for an excuse to use VS.Net 2005, but I have been a bit lazy and out of ideas. (Too many brain cells used at my real job. lol)
|
|
|
|
|
I noticed a bug with using ShowDialog to display a custom dialog box, and then using ShowDialog from that custom dialog to display a FolderBrowserDialog.
The problem is when I select "Ok" or "Cancel" on the FolderBrowserDialog, both dialog boxes disapear.
Has anyone else run into this problem?
And if you have, have you been able to get around it?
Thanks in advance.
|
|
|
|
|
I want to do a while TName "does not equal"
A.K.A " != "
While TName != "Rangers"
but it's not letting me do it, so I assume that my syntax is wrong. Not used to VB.net. Keeps giving me a "End of statement expected".
|
|
|
|
|
Do While TName <> "Rangers"
Loop
"People who never make mistakes, never do anything."
My Blog
|
|
|
|
|
|
I need some guidance regarding a Windows Service Application and MS-Outlook 2000 type library (msoutl9.olb)
My service app needs to scan an outlook inbox at regular intervals and process incoming email messages. My problem is that the application is unable to create the instance of the Outlook.ApplicationClass() object.
The app has the proper installers and has been installed to run on the local machind under the LocalSystem account.
The Outlook application and namespaces are declared at the beginning of the class definition:
Protected Friend olApp As Outlook.ApplicationClass<br />
Protected Friend olNS As Outlook.NameSpace
I attempt to start the Outlook instance in my service's OnStart() event:
Protected Overrides Sub OnStart(ByVal args() As String)<br />
<br />
'write entry that service has started<br />
EventLog1.WriteEntry("KeyMailSvc Started")<br />
<br />
Try<br />
<br />
'start outlook app and open namespace<br />
olApp = New Outlook.ApplicationClass()<br />
olNS = olApp.GetNamespace("MAPI")<br />
olNS.Logon("", "", False, True)<br />
<br />
'start the timer<br />
With Me.Timer1<br />
.Interval = 30000<br />
.Enabled = True<br />
End With<br />
<br />
<br />
Catch ex As System.Exception... (some error logging goes here)<br />
<br />
I do not get to the Catch. Attempts to start the service time out and I get a MS error message "The server {0006F03A-0000-0000-C000-000000000046} did not register with DCOM within the required timeout." in my System log.
If I compile the same code as a WinForms app and move the Outlook code to the Form_Load event, I have no problems. Can anyone shed some light on this for me?
|
|
|
|
|
Just a quick note...
When I change the object type from Outlook.ApplicationClass object to Excel.ApplicationClass object, the service starts.
Protected Overrides Sub OnStart(ByVal args() As String)<br />
<br />
'write entry that service has started<br />
EventLog1.WriteEntry("KeyMailSvc Started")<br />
<br />
Try<br />
<br />
'start outlook app and open namespace<br />
Me.olApp = New Excel.ApplicationClass()<br />
'Me.olNS = olApp.GetNamespace("MAPI")<br />
'Me.olNS.Logon("", "", False, True)<br />
|
|
|
|
|
I have a VB6 application that I am upgrading to VB .NET
I am having difficulty with pupup menus, (right click an item and pop a menu based on current system status) any samples or examples of how this can be done would be appreciated.
|
|
|
|
|
Are you referring to context menus?
If so, simply drag a context menu from the toolbox into your designer window. When highlighted, it will appear as a menu at the top of your form where you can customize it and add menu items.
Assigning it to controls is easy. Simply select a control on your form, and change the Context Menu property to your newly created context object.
Hope this is what you mean?!
|
|
|
|
|
Hrmph... Kinda guess I got thrown off looking for a tricky way to do it. Thanks for your help, just what I was looking for...
|
|
|
|
|
Ok, so I have created my ActiveX control (using VB6) and now have an .OCX file (with others from the compilation).
I know that when I register this .OCX file from inside my target application (MS Access), I can use the control I created.
How can I distribute this when I update my Access "application" on other PCs?
Do I need to do anything, OR is distributing my latest .MDB file (which includes my inclusion of my ActiveX control) good enough? The later I can try.
Reason: I want to eliminate the user's need to go through Tools | ActiveX Controls | Register | (browse for my .OCX file).
Thanks,
Johnny
|
|
|
|
|
I have a couple of different procedures that retrieve data from a single database. Both return a single value, either an Integer or DateTime. But the one that returns an integer accesses the data by connecting to the database and returning the data using .ExecuteScalar, while the other one builds a DataAdapter, a DataSet, and a DataTable, then references the DataTable to get the data.
my question is, is there any advantge to using DataSets over directly query-ing the database?
|
|
|
|
|
The difference here is not the dataset or not, it is the data adapter or the execute scalar method. Executescalar returns a single value and will always return a single value. The other query, if it always returns a single value would possibly benefit from using the executescalar method b/c it wont use all that memory overhead with datasets and adapters and such.
If you will need to return more than a single value then you have 2 choices really, the dataadapter allows you grab a dataset or fill a datatable - or you can use a datareader. Both return a set of data and have their benefits and problems.
So after a long windy explaination - you are querying the database no matter what, but one uses more objects to get the data.
Cleako
|
|
|
|
|
I have a DataAdapter that joins 3 tables together. The DataAdapter fills a DataSet from these tables. How can I add a new row to the DataSet? I'm using the code below to do this but it errors out on the last line.
Dim newrow As DataRow
newrow = MyDataSet.Tables("MyDataTable").NewRow()
newrow.Item("column1") = 0
newrow.Item("column2") = 1
newrow.Item("column3") = 1
MyDataSet.Tables("MyDataTable").Rows.Add(newrow)
Thanks again in advance.
|
|
|
|
|
I cant see an obvious problem with this code, its very similar to something I use currently.
What exactly is the error?
|
|
|
|
|
Error message is:
"Object reference not set to an instance of an object."
Is the problem because I have more then one table in the DataAdapter? Adding a record to the DataSet is Ok, but the DataSet maps back to three tables. How does it know which of the three tables should end up with the new row?
|
|
|
|
|
1. How do I dynamically generate a datagrid and trap the keyboard keys or mouse click in a datagrid cell?
2. How do I prevent from user to add more rows to datagrid?
3. How do I add the footer totals and change them according to the datagrid cell values?
Simpra
|
|
|
|
|
hi guys!
I'm working on a project now, i need to shut down windows XP via vb6 code.
Can somebody please help me about this subject?
|
|
|
|
|
Run the remote windows shutdown application using the "shell" command. The path for the application is:
C:\WINDOWS\system32\shutdown.exe
°[Halo]°
Project Basilisk
|
|
|
|
|
You can shutdown, and optionally restrat, the system by calling the Win32 API function ExitWindowsEx[^]
Declare Function ExitWindows Lib "user32" Alias "ExitWindowsEx" ( _
ByVal dwReserved As Long, ByVal uReturnCode As Long) As Long
RageInTheMachine9532
"...a pungent, ghastly, stinky piece of cheese!" -- The Roaming Gnome
|
|
|
|
|
I have a vb.net project with a few web pages, in each of the pages they call a custom control type which has scroll bar built in, thats fine and when the pages call each other i can controll the call to the other page by adding scrollbars=no in the window.open call, but when i set one of the pages to set as start page how do i them control if a scroll bar appears?????
any ideas?
Thanks
|
|
|
|
|
Can't you set the .scrollbars = no in the form "Load" event?
Thanks,
Taen Karth
|
|
|
|
|
I have a vb.net project with a few web pages, in each of the pages they call a custom control type which has scroll bar built in, thats fine and when the pages call each other i can controll the call to the other page by adding scrollbars=no in the window.open call, but when i set one of the pages to set as start page how do i them control if a scroll bar appears?????
any ideas?
Thanks
|
|
|
|