Hi all, It is along time since I have posted here so my apologies in advance if I get it wrong. I have a list (example below) of names in 2 excel columns (the obvious "Last Name" and "First Name") with multiple instances of surnames and the odd variance of first names such Jed and Ray Wilten and the others examples.. What I am trying to do is firstly get a list of the different individual names (to be used to name individual worksheets) and then a count of how many instances of those names appear in the list. there
What code do you have so far. And which part are you stuck on?
On Tue, Oct 11, 2022, 03:01 Graeme Clough <[log in to unmask]> wrote:
> Hi all, > It is along time since I have posted here so my apologies in advance if I > get it wrong. > I have a list (example below) of names in 2 excel columns (the obvious > "Last Name" and "First Name") with multiple instances of surnames and the > odd variance of first names such Jed and Ray Wilten and the others > examples.. > What I am trying to do is
I'd use a collection for this. I'd loop through the cells containing names and create a full name using something like <Last Name>, <First Name> (if that isn't unique enough, perhaps also put in a comma separated <Middle Name>. Before adding to the collection, check to see if a name exists and only add it to the collection if the name is unique. After you've looped through all rows in the spreadsheet, your collection will just contain unique names and then you can do what you wish using the collection.
Load the entire set of mane pairs into an array Then post them into a Dictionary within VBA - essentially a 2 entry array - Excel allows you to create a new key with it's data entry 1 ? And the key would be the firstname, a separator character (or set) and the second name Excel then allow the entries to be accesses in ascending sequence - (get next) So you can add 1 to an existing key to count the number of entries for each name.
Hello all and thanks for the ideas, Will probably use the "collections" idea. Have to put aside for a while (health fix-up) however but should I get it done I will post the results. Once again, Thanks all, Graeme.
hi, I have a sets of edit boxes that contain time values like "7:36", but adding them together seems to be awkward as VBA sees the entry as text. Using Val() just gives me the hours, not the minutes, Format() does not help.
So I have ended up with this code that just seems clunky...
Try this, Dim strTIL_Pt_TOTAL as string strTIL_Pt_TOTAL=str(TIL_Pt_TOTAL\60) & ":"& cstr(TIL_Pt_TOTAL mod 60)
Cheers & HTH, Fred. Lyhne, SysAdmin
of all the things I've lost, I miss my mind the most.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Richard Sent: Monday, June 8, 2015 7:46 PM To: [log in to unmask] Subject: Adding Time - Userform & Edit Boxes
hi, I have a sets of edit boxes that contain time values like "7:36", but= adding them together seems to be awkward as VBA sees the entry as text.=20=
hi all, just a question about the scroll area (excel 2007) - how secure is this? If I set the area in VBA (sheet properties tab) and lock the VBA project... If the user did not know the VBA password, would they be able to bypass this setting some how? Basically I need to store some information on the sheet and not allow the user to see it or change it. thanks
The ScrollArea has to be reset every time the workbook opens - it doesn't save with the workbook.
> Date: Tue, 11 Nov 2014 00:01:15 -0500 > From: [log in to unmask] > Subject: [VB-B] Scroll Area > To: [log in to unmask] > > hi all, just a question about the scroll area (excel 2007) - how secure is this? > If I set the area in VBA (sheet properties tab) and lock the VBA project... > If the user did not know the VBA password, would they be able to bypass this setting some how? > Basically I need to store some information on
I see your question is asked regarding the security context of the Excel application framework. Your last comment though regarding seeing and changing makes wonder if this is not an issue of visibility. You can't change what you can't see. Maybe there is more to the requirment.
Thx
Bob
-----Original Message----- >From: Richard <[log in to unmask]> >Sent: Nov 11, 2014 12:01 AM >To: [log in to unmask] >Subject: [VB-B] Scroll Area > >hi all, just a question about the scroll area (excel 2007) - how secure is this? >If I set the area in VBA (sheet properties tab) and lock the VBA project... >If the
Because I think you will find the scrollbars are relative to the Excel Application object and not the Workbook object. Might be wrong though as I haven't tested that hypothesis
-----Original Message----- >From: Rory Archibald <[log in to unmask]> >Sent: Nov 11, 2014 4:00 AM >To: [log in to unmask] >Subject: Re: [VB-B] Scroll Area > >The ScrollArea has to be reset every time the workbook opens - it doesn't save with the workbook. > >> Date: Tue, 11 Nov 2014 00:01:15 -0500 >> From: [log in to unmask] >> Subject: [VB-B] Scroll Area >> To: [log in to unmask] >> >> hi all, just a question about
Scroll bars and ScrollArea are separate things. The ScrollArea property is worksheet specific, but it doesn't persist between sessions (like a few of the worksheet properties) and must be reset each time the workbook is opened.
> Date: Tue, 11 Nov 2014 07:53:22 -0500 > From: [log in to unmask] > Subject: Re: [VB-B] Scroll Area > To: [log in to unmask] > > That would be true... > > Because I think you will find the scrollbars are relative to the Excel Application object and not the Workbook object. Might be wrong though as I haven't tested that hypothesis > > > -----Original Message----- >
Are you asking a question or making a statement? Since the question of security has been answered I've been looking for the next specific question but have been missing it.
-----Original Message----- >From: Rory Archibald <[log in to unmask]> >Sent: Nov 11, 2014 8:06 AM >To: [log in to unmask] >Subject: Re: [VB-B] Scroll Area > >Scroll bars and ScrollArea are separate things. The ScrollArea property is worksheet specific, but it doesn't persist between sessions (like a few of the worksheet properties) and must be reset each time the workbook is opened. > >> Date: Tue, 11 Nov 2014 07:53:22 -0500 >> From: [log in to unmask] >> Subject:
And Excel workbooks are not secure if you allow the user access they can use an alternative to Excel to open them and thus not have any macro's activated.
You can expect the VBA code to be reasonably secure if you protect it, and from there you can post entries into a very hidden sheet, global variables, the registry, or - if you ensure the file is held within a NTFS file-system, the second, or other streams of the file.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Bob Coward Sent: Tuesday, November 11, 2014 12:28 PM To: [log in to unmask] Subject: Re: [VB-B] Scroll Area
I see your question is asked regarding the security context of the Excel application framework. Your last comment though regarding seeing and changing makes wonder if this is not an issue of visibility. You can't change what you can't see. Maybe there is more to the requirment.
I was making a statement in response to your statement.
> Date: Tue, 11 Nov 2014 08:35:37 -0500 > From: [log in to unmask] > Subject: Re: [VB-B] Scroll Area > To: [log in to unmask] > > Are you asking a question or making a statement? Since the question of security has been answered I've been looking for the next specific question but have been missing it. > > > -----Original Message----- > >From: Rory Archibald <[log in to unmask]> > >Sent: Nov 11, 2014 8:06 AM > >To: [log in to unmask] > >Subject: Re: [VB-B] Scroll Area > > > >Scroll bars and ScrollArea are separate things. The ScrollArea
I have a access database and want to add a button that will prompt a user to enter copy from ticket# and a copy to ticket# then once OK is clicked, copy data from the copy from ticket# to the copy to ticket #. This would save time in data entry. Just not sure how to go about doing it...
Subtraction? -------- Original message -------- From: Marc Lepley <[log in to unmask]> Date:02/28/2014 11:11 AM (GMT-05:00) To: [log in to unmask] Subject: [VB-B] Code to perform date check Need to run some code to verify that "closed date" is >= "start date" and display an error message if it fails this test...any ideas? ------------------------------------------------------------ - The VISBAS-BEGINNERS list is hosted on L-Soft international's LISTSERV(R) software running on Microsoft Windows Server 2008 R2. - The List Archive can be found at: http://peach.ease.lsoft.com/archives/visbas-beginners.html - To unsubscribe from this list simply use this link: mailto:[log in to unmask]
More like a data entry validation to make sure that the entered closed date does not occur before the start date...
Marc Lepley Work Management Data Sustain Team E&P Maintenance & Reliability Excellence / E&P IT&S Backbone oneteam onevision US Office: +1 281.504.9836 US Mobile: +1 832 803 4395
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Peter Sent: Friday, February 28, 2014 10:53 AM To: [log in to unmask] Subject: Re: [VB-B] Code to perform date check
I have not tested this scenario so I throw it out for you to consider. I believe DatDiff(interval in days, start date, closed date) function could return a negative integer when comparing your start date and closed date. If it does return a negative you confirm the closed date occurs before the start date.
If ClosedDate >= StartDate Then intMessage = MsgBox("Something here" & vbNewLine _ & vbNewLine & "Please try again.", vbInformation) End If
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Marc Lepley Sent: Friday, February 28, 2014 11:11 AM To: [log in to unmask] Subject: [VB-B] Code to perform date check
Need to run some code to verify that "closed date" is >= "start date" and display an error message if it fails this test...any ideas?
If dteStartDate.Value >= dteEndDate.Value Then intMessage = MsgBox("Something here" & vbNewLine & vbNewLine & "Please try again.", vbInformation) dteEndDate.SetFocus Exit Sub End If
Randy Anderson | Senior Systems Analyst | BC Mail Plus Shared Services BC Ph: 250 217-0462 | e: [log in to unmask] | m: PO Box 9453, Stn Prov Govt, Victoria BC V8W 9V7
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Christian, Lorraine Sent: Friday, February 28, 2014 1:40 PM To: [log in to unmask] Subject: Re: [VB-B] Code to perform date check
Marc Lepley Work Management Data Sustain Team E&P Maintenance & Reliability Excellence / E&P IT&S Backbone oneteam onevision US Office: $B!! (B +1 281.504.9836 US Mobile: +1 832 803 4395
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Christian, Lorraine Sent: Friday, February 28, 2014 3:40 PM To: [log in to unmask] Subject: Re: [VB-B] Code to perform date check
I'm not having fun with VB6 these days. Makes me glad to use .NET. Anyway, I have a form that has a data grid on it that accepts cheque numbers. When there are 2 or more rows, I do a validation to ensure that similar numbers haven't been previously entered. In order to do this, I check for duplicate values, allow the operator to fix and then revalidate. During the revalidation, I need to reset the array and repopulate it with the new numbers from each of the rows.
On 29/10/2013 07:28, Randy Anderson wrote: > I'm not having fun with VB6 these days. Makes me glad to use .NET. Anyway, I have a form that has a data grid on it that accepts cheque numbers. When there are 2 or more rows, I do a validation to ensure that similar numbers haven't been previously entered. In order to do this, I check for duplicate values, allow the operator to fix and then revalidate. During the revalidation, I need to reset the array and repopulate it with the new numbers from each of the rows. > > My problem
I'm doing some validation on a series of text boxes to ensure that the user enters the correct information.
My problem arises when the user clicks on a textbox (we'll use 3 as an example) and decides they have made a data entry error in the previous textbox (textbox 2). They don't enter any data into textbox 3 and they click on textbox 2.
It sounds like you are doing validation on exit of the textbox. I would only do validation when the user clicks a button or some other action that submits the form for processing.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Randy Anderson Sent: Wednesday, October 23, 2013 12:48 PM To: [log in to unmask] Subject: EXTERNAL: [VB-B] Value of textbox when clicking into it
Are you using VB6 for this (or better yet, are you not using a version of .NET for this)?
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Miley, David G Sent: Friday, October 25, 2013 3:36 AM To: [log in to unmask] Subject: Re: [VB-B] Value of textbox when clicking into it
It sounds like you are doing validation on exit of the textbox. I would only do validation when the user clicks a button or some other action that submits the form for processing.
I'm working on some existing code that a previous employee had 95% finished. I don't have time to rewrite in .NET. The suggestion to validate after all of the data has been entered seems like a good way to get around the problem. I'll see if I can do that without too much work. I had added this to the other validation strings to get around the issue short term
On 24/10/2013 04:47, Randy Anderson wrote: > This gives a runtime error 13 (type mismatch) for textbox 3 because I haven't correctly validated. My issue is I can't figure out what the validation would be by them simply clicking on textbox 3 and then clicking somewhere else. None of the following work.
Randy Anderson BC Mail Plus Systems Shared Services BC | Citizens' Services & Open Government 1150 McKenzie Avenue, Victoria BC V8W 9V7 Office/Cell 250.217.0462
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of J Trahair Sent: Friday, May 24, 2013 11:00 AM To: [log in to unmask] Subject: Re: [VB-B] Date Time function not working correctly
Yes - mm is minutes. For months use MM (upper case). Also use HH (uppercase) for hours in 24hr format.
I've added a COM reference to Microsoft Excel 12.0 Object Library in my project. I can see the reference in the Project designer, but when I type Dim XlApp As Excel.Application the object look ahead doesn't work and I get a blue line underneath the code. What am I missing?
Never mind. I had forgotten Imports Microsoft.Office.Interop
Randy Anderson BC Mail Plus Systems Shared Services BC | Citizens' Services & Open Government 1150 McKenzie Avenue, Victoria BC V8W 9V7 Office/Cell 250.217.0462
-----Original Message----- From: Randy Anderson [mailto:[log in to unmask]] Sent: Friday, March 22, 2013 11:03 AM To: [log in to unmask] Cc: Anderson, Randy S CITZ:EX Subject: Not able to use Excel reference
From: [log in to unmask] To: [log in to unmask] Subject: [VB-B] Setting an image/picture to a userform control (VSTO) [Correction] Date: Mon, 15 Oct 2012 15:36:24 +0200
Hi all, VSTO Excel, Visual Studio 2012
In VBA, to assign a built-in picture to a label on an userform, one can use this code:label1.Picture = Application.CommandBars.GetImageMso("HappyFace",16,16)
What is the code to achieve the same result for a label on an userform in VSTO?
You may have better success addressing this question to the forums that are dealing with this preview product at http://msdn.microsoft.com/en-US/office/apps/fp179866
/tr
On Mon, Oct 22, 2012 at 10:10 AM, Raymond K. Gota Toudji < [log in to unmask]> wrote:
> Please, anyone? > > > Gr, > Raymond > > From: [log in to unmask] > To: [log in to unmask] > Subject: [VB-B] Setting an image/picture to a userform control (VSTO) > [Correction] > Date: Mon, 15 Oct 2012 15:36:24 +0200 > > > > > > > Hi all, > VSTO Excel, Visual Studio 2012 > > In VBA, to assign a built-in picture to a label
Ok, I'll try that. Already have posted the question to the specific VSTO forum, without success so far ...http://social.msdn.microsoft.com/Forums/en-US/vsto/thread/84339387-d3a2-4fa8-b6c7-4f62f932f8bd With 59 readers, only one person answered, with the advise to google something and find out the soluction there ... After doing that for more than 45 minutes, I gave up!
It's frustrating that a simple line of code in VBA Excel (Visual Basic for Application) can become so much trouble in VSTO (Visual Studio Tools for Application)
Try this form1.picture = app.path & "\picturename.jpg" or form1.picture = picture1.picture
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Raymond K. Gota Toudji Sent: Monday, October 22, 2012 11:48 AM To: [log in to unmask] Subject: Re: [VB-B] Setting an image/picture to a userform control (VSTO) [Correction]
Ok, I'll try that. Already have posted the question to the specific VSTO forum, without success so far ...http://social.msdn.microsoft.com/Forums/en-US/vsto/thread/84339387-d3a2-4 fa8-b6c7-4f62f932f8bd With 59 readers, only one person answered, with the advise to google something and find out the soluction there ... After doing that for more than 45 minutes, I gave up!
I just tried it. No result. I give up :-( > In VBA, to assign a built-in picture to a label on an userform, one > can use this code:label1.Picture = > Application.CommandBars.GetImageMso("HappyFace",16,16) > What is the code to achieve the same result for a label on an > userform in VSTO?
Gr, Raymond
> Date: Mon, 22 Oct 2012 12:44:48 -0400 > From: [log in to unmask] > Subject: Re: [VB-B] Setting an image/picture to a userform control (VSTO) [Correction] > To: [log in to unmask] > > Try this > form1.picture = app.path & "\picturename.jpg" or form1.picture = > picture1.picture > > > -----Original
In VBA, to assign a built-in picture to say a label on an userform, one can use this code:label1.Picture = Application.Commandbars.GetImageMso("HappyFace",16,16)
What is the code to achieve the same result for a label on an userform in VSTO?
This subroutine works fine using windows XP but does not work with Vista nor Windows 7. Can anyone show me how to get it to work with Vista and Windows 7?
Private Sub cmdBackup_Click() If txtDestination <> "" Then Dim bSuccess As Boolean Dim BackupFolderName, Destination As String
This routine makes the specified directory but does not copy the database. I do not get an error message other than MsgBox " Backup unsuccessful", vbInformation, "" Listed below is the ShellFileCopy function:
Public Function ShellFileCopy(src As String, dest As String, _ Optional NoConfirm As Boolean = False) As Boolean
'PURPOSE: COPY FILES VIA SHELL API 'THIS DISPLAYS THE COPY PROGRESS DIALOG BOX 'PARAMETERS: src: Source File (FullPath) 'dest: Destination File (FullPath) 'NoConfirm (Optional): If set to 'true, no confirmation box 'is displayed when overwriting 'existing files, and no 'copy progress dialog box is 'displayed
This works fine on my Vista box if I copy to and from folders that I have permission to work with.
In your case the call to SHFileOperation is returning a non 0 value. That value will tell you what the error is (see http://msdn.microsoft.com/en-us/library/windows/desktop/bb762164%28v=vs.85%2 9.aspx for return codes).
I'd also suggest that if you don't need the Explorer style progress and cancel functions of SHFileOperation, then you'd probably be better off using the FileScriptingObject for copying and moving files.
Rob, thanks but the link that you7 provided could not be found.
-----Original Message----- From: Visual Basic Beginner's List [ <mailto:[log in to unmask]> mailto:[log in to unmask]] On Behalf Of Robert Lee Sent: Monday, October 15, 2012 2:56 PM To: [log in to unmask] Subject: Re: [VB-B] Backup Routine
David,
This works fine on my Vista box if I copy to and from folders that I have permission to work with.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of David Sent: Monday, October 15, 2012 4:25 PM To: [log in to unmask] Subject: Re: [VB-B] Backup Routine
Rob, thanks but the link that you7 provided could not be found.
When I do the keypress with specific letter Ex. My screen show A I press in my keyboard A. the routine it fine but if I press O the routine play the song of O and ignore the letter show it in the screen. In this case will be A. Who know what is the mistake.
If e.KeyChar = "A" Then Process.Start("Letra A.wmv")
'this line of code will never fire since it only gets here if .keychar = "A" If e.KeyChar <> "A" Then Label1.Text = temp End If End If
try this instead,
If e.KeyChar = "A" Then Process.Start("Letra A.wmv") Else Label1.Text = temp End If
HTH,
Rob Lee
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Fam. Álvarez Cruz Sent: Sunday, October 14, 2012 2:21 PM To: [log in to unmask] Subject: [VB-B] problem with thst routine in my if then
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Robert Lee Sent: Monday, October 15, 2012 1:02 PM To: [log in to unmask] Subject: Re: [VB-B] problem with thst routine in my if then
Not 100% sure if I understand correctly, but...
If e.KeyChar = "A" Then Process.Start("Letra A.wmv")
'this line of code will never fire since it only gets here if .keychar = "A" If e.KeyChar <> "A" Then Label1.Text = temp End If End If
I'm coding a VB 2008 solution that needs to read individual lines from a very large file of ~3.5 million lines. I'm testing a smaller file of ~35000 lines in order to maximize the time to process. Using VB 6 the following code takes approx 2 seconds
Do Until fsoStream.AtEndOfStream = True inputFileStr = fsoStream.ReadLine inputNumRecs = inputNumRecs + 1 Loop
I'm a bit worried about that Dim strInput_Line being inside the loop. Try: Dim strInput_Line As String = "" Do Until objReader.EndOfStream = True strInput_Line = objReader.ReadLine() '& vbNewLine lngTotal += 1 Loop
Anyway, as I discovered a few years ago, for raw speed forget Windows, use DOS.
HTH
Jonathan Trahair ----- Original Message ----- From: Randy Anderson To: [log in to unmask] Sent: Friday, September 28, 2012 5:54 PM Subject: [VB-B] VB 2008 Streamreader vs VB 6 Readline
Tried that previously, still 5 seconds. Thanks anyway.
Randy Anderson BC Mail Plus Phone: 250 217 0462 Fax: 250 952 5117 E-mail: [log in to unmask]
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of J Trahair Sent: Friday, September 28, 2012 9:59 AM To: [log in to unmask] Subject: Re: [VB-B] VB 2008 Streamreader vs VB 6 Readline
I'm a bit worried about that Dim strInput_Line being inside the loop. Try: Dim strInput_Line As String = "" Do Until objReader.EndOfStream = True strInput_Line = objReader.ReadLine() '& vbNewLine lngTotal += 1 Loop
What's the size of the file, and what type of reader are you using?
I can read 500k lines (~500 MB) with an IO.StreamReader in < 2 seconds (1596 ms). If I double the line size (~1GB) I can still get it and about 3.1 seconds on average.
If you need blazing fast speed you might consider using a stream and a binary reader, reading chunks of the file into a byte array, and then manipulating it in memory. My.Computer.FileSystem.ReadAllBytes can get the first file in < 250 ms. (second file is too large for a single pass read).
Dim objReader As New System.IO.StreamReader(FileName) Do Until objReader.EndOfStream = True strInput_Line = objReader.ReadLine() lngTotal += 1 Loop
The file I am testing is 37000 records (40MB) and it takes 5 seconds. The prod file will be 3.7 million records (4GB), so I'd love to get this time down.
Randy Anderson BC Mail Plus Phone: 250 217 0462 Fax: 250 952 5117 E-mail: [log in to unmask]
If you are referring to the Metro (or whatever it's called this week) interface with all of the tiles, you can't write any of that with VB6 (or even proper .NET).
Metro apps are actually little HTML5 / CSS3 apps running in a full screen browser sandbox, along with some Javascript libraries (IIRC) to get to the WinRT runtime libraries for things like file IO and events from the OS. I'm over simplifying this a bit, but they aren't applications as we know them.
Robert, I tried compatibility mode, run as administrator etc.
I've already created a touch interface for one of my apps and it works fine with Xp. Vista and Win 7 The compiled apps work on windows 8, it is the development tools that won't install, mainly VB6 I'm wondering if it was possible to upgrade a win7 OS to win 8 and all the tools will remain registered
So you just want to do desktop apps, not Metro apps.
Windows XP Compatibility Mode is a bit different from compatibility mode on the properties on the exe. It's actually an XP VM that is run under Virtual PC, but is supposed to appear seamless in Win7. It's a feature on the Pro and up versions of Win7, but I'm not sure if it's in the RTM Win8 edition. I think in Win7 that it's an add on that you have to install.
Yes, it is available for win7 Pro, But is not needed because I can install on win 7 32 bit and 64 bit,
Parts of the IDE is installing but some ocx's will not register neither at installation or manually wit regsvr32.ext or Regit.exe I have one app running partially but am getting OLE errors and graphics server error Seems when the app is started and loads another instance of the graphics server and when trying to display a graph get a message, The graphics server is already loaded And doe not display the graph :-))
Dim Song As ASong For Each Song In _Songs x_Write.WriteStartElement("Song") x_Write.WriteStartElement("FileName") x_Write.WriteString(Song.FileName) x_Write.WriteEndElement() x_Write.WriteStartElement("Title") x_Write.WriteString(Song.Title) x_Write.WriteEndElement() x_Write.WriteStartElement("Artist") x_Write.WriteString(Song.Artist) x_Write.WriteEndElement() x_Write.WriteEndElement() Next
Why not use a List instead of Array, then use Adelle's For Each loop to cycle through the list, you don't need to keep track of length and if you want to know how many ther are you can use the Count property. Biggest perk is you don't need to ReDim the list size if you want to add another.
And for the record, the reason why I was doing it that way was I was trying to learn how to create a class that implemented IEnumerable.
On Mon, Aug 20, 2012 at 5:49 AM, Frank Corrao <[log in to unmask]> wrote: > Why not use a List instead of Array, then use Adelle's For Each loop to cycle through the list, you don't need to keep track of length and if you want to know how many ther are you can use the Count property. Biggest perk is you don't need to ReDim the list size if
You still are, the main feature of IEnumerable is Collections and the For Each loop. Collections include the List, and the Dictionary as well as Arrays.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of John Meyer Sent: Monday, August 20, 2012 6:37 PM To: [log in to unmask] Subject: Re: [VB-B] Array element problems
Currently, I use the code below to get user's log on ID under windows XP. But it will not run under Windows 7. What is the right codes to work both environment?
This e-mail may contain confidential or privileged information. If you think you have received this e-mail in error, please advise the sender by reply e-mail and then delete this e-mail immediately. Thank you. Aetna
Hi, I am going to use the VB.net 2010 to generate an ASP page. The problem is I do not have SQL. I only have Microsoft Access 2010 available to me and I only need to display some read only data through the Web. Could you please help me to understand on how to generate a connection string?
First Access is the wrong RDBMS for use in a Web app especially when SQL Server Express can be downloaded from Microsoft for free. That said here is a great place for connection strings: http://www.connectionstrings.com/
John Warner
> Date: Mon, 13 Feb 2012 10:47:13 -0500 > From: "Robitaille, Dorothy L" <[log in to unmask]> > Subject: Access 2010 and ASP.net connection > > Hi, I am going to use the VB.net 2010 to generate an ASP page. The problem > is I do not have SQL. I only have Microsoft Access 2010 available to me and I > only need to display some
Thank you John for this link to connection. It is a great site
I knew you were right. Access is the wrong database for Web apps. The reason I have problem to use the SQL server I was told SQL has to have SQL server to host and there is admin process involved. Every time if user needs to access the page and she/he has to grant permission to it. Is this true to SQL Sever Express as well?
I noticed that you indicated that you needed to present some read only information to the presentation layer. I'm wondering if you need all that database power, configuration, Grant User, etc stuff. Being that you have looked at connectionstrings would a solution for you be to build a connection string to a flat file or text file? Once you have that connection string setup with a tabular flat file you will be able to write typical select statements against the file and that might be a way to access and display read only information without all the hassle of
Yes Bob. I set up Access 2010 database on the share and only one person updated the information on the backend on the daily basis. Then I want to display the information which is ready only to all the other users, but this information will be a parent and Child relationship. But, this is very simple one to many relationship information. The reason I want to keep Database was tried to keep the relationship between the records. Is there is a way to show the relationship if this is a flat file? Thanks! Dorothy
The administration of the Express version of SQL Server is minimal and there are lots of great guides and places for advice on the subject. The problem with Access in a Web app is the way Access manages data locks and concurrency. Access is a desktop application, note how it ships with MS Office, a web app is hosted on a Server because it requires IIS and server type services (in the background no need to worry about it as a developer). SQL Server is a server oriented database, it has built in processes for dealing with concurrency issues and
I have a VB6 app that runs on Win7 just fine (after 1,001 changes) with the exception of a printer problem. When the printer dialog box comes up and the user says 4 (or any number > 1) copies, only one copy will print. All other applications (at least that is what I am told) print multiple copies just fine. And it is more complicated that that, it works just fine on some Win7 s.
I have a fairly simple winsock program that I'm trying to use to learn from. It's a short client-server program where the client app. connects to and passes a number to the server app. However, it doesn't look like the server app is "seeing" the data. I've tried to google different variants of "winsock" "VB" etc. but nothing but vb6 or other stuff that won't work comes up. I'm using Vb studio 2008. Does anyone have a simple working example of how it needs to get set up - or - does anyone want to try a shot at the
Both sample sets are simple classes that you create in a new Console App, but can easily be modified for Win Forms once you get the grasp of what they are doing.
Outstanding! THANK YOU! That's exactly what I was looking for. I did a search on the MS site but that didn't come up......
Again..THANKS!!
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Robert Lee Sent: Wednesday, October 19, 2011 3:48 PM To: [log in to unmask] Subject: Re: [VB-B] Winsock help....
Richard,
The following link has 4 samples that can be used to build a simple client and server for either synchronous or asynchronous socket communication.
Richard, This is vb6, but, is show the various options... It also shows that ports are important. Note they must match on server AND client... http://www.codeproject.com/KB/IP/winsock.aspx
Here is a resource for vb.net : http://msdn.microsoft.com/en-us/library/system.net.aspx In that list you will find the "Sockets.Namespace" which is the full classes for sockets: http://msdn.microsoft.com/en-us/library/system.net.sockets.aspx
Lastly, here is one sample for client/server for .net... Hope it helps: http://www.codeproject.com/KB/IP/filesharingvb7.aspx
Thank you! I found a lot of VB6 stuff but winsock has changed so much since then... these look like great resources - Thanks!!
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Ernie Sent: Wednesday, October 19, 2011 4:06 PM To: [log in to unmask] Subject: Re: [VB-B] Winsock help....
Richard, This is vb6, but, is show the various options... It also shows that ports are important. Note they must match on server AND client... http://www.codeproject.com/KB/IP/winsock.aspx
No problem. Sometimes just figuring out the terms to search is half the battle!
I use "VB.Net" (or just ".Net") in searches and tend to get better results than just using "VB" (you end up with a lot of vb6 stuff as you found). You also have to look at dates on threads/samples/articles, since many will reference 2001 or 2003 versions, and a lot has changed in VB.Net since then (which may explain broken things if you copied old code samples into 2008).
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Robert Lee Sent: Wednesday, October 19, 2011 4:09 PM To: [log in to unmask] Subject: Re: [VB-B] Winsock help....
No problem. Sometimes just figuring out the terms to search is half the battle!
I use "VB.Net" (or just ".Net") in searches and tend to get better results than just using "VB" (you end up with a lot of vb6 stuff as you found). You also have to look at dates on threads/samples/articles, since many will reference 2001 or 2003 versions, and a lot has
I've written a front end to run a canned exe that executes in a dos window. The exe generates an informational message when it completes and writes it into the cmd.exe window. Is there any way to interact with the cmd.exe window so that I can retrieve this message and then act on it?
I need to connect to a mdb file located in internet from a VB desktop application. For Example: My database is located here: http://www.mysite.com/dbfolder/mydb.mdb What should I do in VB 6.0?
Dave, first is your site local or worldwide? If local, is it hosted with the database exposed to the lan? Is it on a hosted website like www.microsoft.com ? Is it a SQL server it is on or MySQL server? Lots of Questions to answer before we can help.
General answers: If created in SQL or MySQL, you would be given a "Connection String" when it was created. This connection string is used to allow VB6 to access your database and read/write/update it. The code is Simple and found all over the internet. For more info, Google.com is your buddy,
Ernie just a quick point of reference, an MDB is a Microsoft access DataBase. No biggie but will when you see it save you looking up solutions to MySQL or Postgre and that sort of thing.
To answer the OP's question, even if the PC is exposed to the Internet Access is a file based database system, you would have to be able to access the file system. If this is done you could do it but there is a huge problem if you expose the file system to the internet the bad guys will find you and kill your
Dave / John??? Again, it depends on what type of MDB (Microsoft Data Base) that Dave is trying to access. My local area network has a MS Access Database that has the .mdb extension and it works well on the network. But, it will not work on the internet! I was trying to get Dave to give us more info about what type of .MDB he wants to access over the internet. I have several MDB's online and they work great from VB6 and VB.NET. They are secure and do not require VPN's. So, not sure why all the "exposing
">. I have several MDB's online and > they work great from VB6 and VB.NET. They are secure and do not require > VPN's."
Wow you have Access Databases you can connect to using VB (classic) or VB.NET over the Internet, with no VPN required? Could you give us a snippet of code? PC1 in France PC2 (with MDB) in say California Only link between two PCs is Internet
Dave / John, Sorry I did not reply sooner, have not been in the office...
John was correct in his comments. I was wrong, I got mixed up with a few other emails... You can NOT directly connect to a MS-Access Database over the internet. (Note the word directly!) BUT, you can do it program wise. You need server/client code to send/receive the data... To recap...
I have a classic VB project that uses an Access Database on a local computer. I would like to place the database on the internet and connect to it using the VB project. I am not concerned with security. I only need to know how to make the connection. A snippet of code would be helpful.
Dave, (Sorry, long note...) Access Database's are NOT standard databases. They are just files that are accessed by a program or MS-Access in a way that is similar to a real database. I sent a previous post that explained, but, it may have been lost. Basically, Access databases are a file that is stored on a local machine. They can be used from a machine on your local computer or from a networked local computer or even from a VPN'd networked computer. But, not across the internet as a file stored on a server. There are two ways to still
Dave, one further idea... You could have the program at the other end, just download the Access database and it could alter it locally and then re-store it up on the internet server. I think it is easier to just move up to an internet database. Access to it is easy. Ernie..
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Dave Mason Sent: Wednesday, October 12, 2011 7:55 AM To: [log in to unmask] Subject: Re: [VB-B] connect to internet mdb
I still think a VPN is the easiest way to do this. Then both computers appear to be on the same LAN. Setting up a VPN connection between two Windows computers is pretty easy. Is the thinking here that it is difficult?
http://www.youtube.com/watch?v=1s5JxMG06L4
John Warner
> > Date: Thu, 13 Oct 2011 01:14:56 -0400 > From: Ernie <[log in to unmask]> > Subject: Re: connect to internet mdb > > Dave, one further idea... You could have the program at the other end, just > download the Access database and it could alter it locally and then re-store > it up on the
Yes, John, I think that would work. Without knowing what Dave really wanted to do across the internet, it is hard to say which is best. Dave, what are you trying to send from France to California??? Full Access Database read/write data, or just reading some data? More info will help...
Hello Everybody, I am still working with good old VB6 (Enterprise). I have a regular Common Controls toolbar on which I have a button with tbrPlaceholder style. I am trying to put a Label control on it but cannot determine how do I put it on the button since the button has no properly defined borders.
I am a bit rusty in VB6. I have inherited about a 100 text files in which I would like to read and output as an Access table but I am a bit stuck in how to read the fields. They are fixed length variables missing data, sometimes consecutive fields
1234abcde 1234567890 12345678
This above are var1 = 4 chars, var2 = 5 chars, var3 = 5 chars missing, var4 = 10 chars, var 5 and 6 = both 8 chars missing, var 9 = 4 chars, var 10 = 4 chars
If I remember correctly you should be able to take the following sample and read your test file as Input. To parse the data parts out of the line that is read you could use a combination of the MID and Len statements.
Here is the text from the help files on the MID statement.
Sorry for the improper direction but you will want to use the MID Function instead of the MID statement to extract part of a string from an existing string.
Mid Function Example The first example uses the Mid function to return a specified number of characters from a string.
I'm writing this with tears in my eyes, I came down here to London,England for a short vacation and i was mugged at gun point last night at the park of the hotel where i lodged, all cash,credit cards and cell phone were stolen off me. I've been to the embassy and the police here but they're not helping issues at all, My flight leaves in less than 24hrs from now and am having problems settling the hotel bills.
I went home with the waitress The way I always do How was I to know She was with the Russians, too
I was gambling in Havana I took a little risk Send lawyers, guns and money Dad, get me out of this, ha
I'm the innocent bystander But somehow I got stuck Between a rock and a hard place And I'm down on my luck Yes, I'm down on my luck Well, I'm down on my luck
I am trying to find an intermediate to advanced level tutorial on creating a progress bar, preferably one that has concise, clear instructions. If I sound a little tense, it's because I've been googling and youtubing. The results are not that pretty.
You can also use the search function on vb-Helper to search articles. There are some more advanced articles there (MDI forms and whatnot), but I'm not sure what you are actually trying to accomplish, so didn't want to muddy up the waters.
HTH, Rob Lee
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of John Meyer Sent: Wednesday, April 13, 2011 4:22 PM To: [log in to unmask] Subject: [VB-B] Need a tutorial on progress bars in .NET
It's .NET (thought I mentioned that in the subject line).
The biggest problem to me is where to put the background worker. I have a class that manages the song list, and a windows form. There can be multiple instances of song list.
On 4/13/2011 3:17 PM, Robert Lee wrote: > Assuming VB6: > > http://www.vb-helper.com/howto_progress_bar_timer.html > > http://www.vb-helper.com/howto_progress_bar_no_timer.html > > http://www.vb-helper.com/howto_statusbar_progress_indicators.html > > http://www.vb-helper.com/howto_statusbar_show_progress.html > > > You can also use the search function on vb-Helper to search articles. There > are some more advanced articles there (MDI forms and whatnot), but I'm not > sure what you are
My system is setup that one of the "printers" actually creates a PDF file and not print the document to the printer.
The problem is that each time a file name must be entered.
If printing reports for say sales staff but in stead of printing it to the ordinary printer I want to print it to a PDF file, how do I name the file from source code using the staff members name or number
Don't know if you can do it directly from the printer. You may need a library like iText to create the printed document:
http://www.itextpdf.com/download.php
On 3/24/2011 12:30 PM, Douw Kruger wrote: > Hi > > > > My system is setup that one of the "printers" actually creates a PDF file > and not print the document to the printer. > > The problem is that each time a file name must be entered. > > > > If printing reports for say sales staff but in stead of printing it to the > ordinary printer I want to print
Public Function ASong.Write() As XElement Dim xWrite As XElement = <song> <name><%= Me.Name %></name> <filename><%= Me.FileName %></filename> <artist><%= Me.Artist %></artist> <album><%= Me.Album %></album> <genre><%= Me.Genre %></genre> <lyrics><%= Me.Lyrics %></lyrics> <cover><%= Me.Cover %></cover> <comment><%= Me.Comment %></comment> </song>
Return xWrite End Function
And the code that creates the document:
Dim xPlayList As New XDocument Dim xSongList As New XElement("SongList") xPlayList.Add(xSongList) For Each lv As ListViewItem In lvSongs.Items Dim Song As ASong = DirectCast(lv.Tag, ASong) xSongList.Add(Song.Write) Next xPlayList.Save("playlist.xml")
-----Original Message----- >From: John Meyer <[log in to unmask]> >Sent: Mar 17, 2011 9:31 AM >To: [log in to unmask] >Subject: [VB-B] Problem creating an XML file in code. > >Here's my code: > >Public Function ASong.Write() As XElement > Dim xWrite As XElement = <song> ><name><%= Me.Name %></name> ><filename><%= Me.FileName %></filename> ><artist><%= Me.Artist %></artist> ><album><%= Me.Album %></album> ><genre><%= Me.Genre %></genre> ><lyrics><%= Me.Lyrics %></lyrics> ><cover><%= Me.Cover %></cover> ><comment><%= Me.Comment %></comment> ></song> > > Return xWrite > End Function >
That worked, but I found another error, specifically in the way I'm grabbing off the ListViewItems from the listview.
For Each lv As ListViewItem In lvSongs.Items
It seems this isn't picking up any Items, even though I know the listview has items.
Thanks for the help.
On 3/17/2011 8:10 AM, Bob Coward wrote: > John, > > See if using a XMLTextEditor will help you. It gets pretty simple when you control writing the different parts of the document. > > http://vb.net-informations.com/xml/create-xml-vb.net.htm > > G'Luck, > > Bob Coward > > -----Original Message----- >> From: John Meyer<[log in to unmask]> >> Sent: Mar
Code: Private Function FindAlbums(ByVal p_ID As String) As List(Of AnAlbum) Dim uri As String = String.Format("http://musicbrainz.org/ws/1/artist/{0}?type=xml&inc=Official+release-events", p_ID)
Dim xDoc As New XmlDocument Dim rqAlbums As HttpWebRequest = DirectCast(WebRequest.Create(uri), HttpWebRequest) Dim rsAlbums As HttpWebResponse = DirectCast(rqAlbums.GetResponse, HttpWebResponse) Dim srAlbums As New StreamReader(rsAlbums.GetResponseStream)
FindAlbums = New List(Of AnAlbum) xDoc.LoadXml(srAlbums.ReadToEnd) MessageBox.Show(xDoc.SelectNodes("//release").Count)
For Each rel As XmlNode In xDoc.SelectNodes("artist/release-list/release") Dim Album As New AnAlbum Album.ID = rel.Attributes("id").InnerText Album.ASIN = rel.SelectSingleNode("asin").InnerText Album.Title = rel.SelectSingleNode("title").InnerText Dim li As New ListViewItem li.Tag = Album li.Text = Album.Title lvAlbums.Items.Add(li) FindAlbums.Add(Album) Next
Hard to say since I have no, zero idea about the xml document or even a clue about the schema. Given the information provided I would guess you are not holding your mouth right when you execute the code.
John Warner > Date: Thu, 10 Mar 2011 15:57:34 -0700 > From: John Meyer <[log in to unmask]> > Subject: xmldocument.selectNodes not returning anything (XPath error?) > > Code: > Private Function FindAlbums(ByVal p_ID As String) As List(Of AnAlbum) > Dim uri As String = > String.Format("http://musicbrainz.org/ws/1/artist/{0}?type=xml&inc=Official+rel > ease-events", > p_ID) > > Dim xDoc As New XmlDocument > Dim rqAlbums As HttpWebRequest =
On 3/11/2011 3:44 AM, John Warner wrote: > Hard to say since I have no, zero idea about the xml document or even a clue about the schema. Given the information provided I would guess you are not holding your mouth right when you
I have managed to create a program to analyze a lot of data and the print the reports to a printer automaticly and in sequence to the printer
I would like however to print each report with its own unique name as generated by the program to a Word or PDF file without manually assigning a name every time.
The command you are giving will create a generic database with the generic rules, not a copy of what you set up. You can use Stored Procedures to create a database that has what you want for settings. You will have to tell it that you want numeric fields and decimals set to 2, or you can run a copy command to duplicate your dummy database.
I have a tried and true application written in VB6. It is maybe 7 years old. It works good with win 2000 and win XP. Vista caused us some headaches, but the application runs OK. Win 7 is better but we have trouble knowing where the .mdb database file is stored. The default C:\Program Files\myApp\myDatabase.mdb ends up in virtual store, etc.
You can get environment variables with a call to "environ". I don't have VB6 on this machine, but I think it returns an array of string. I don't know that any of the special paths are in the environment variables though.
If that doesn't work the article below has info on an API Call to get the special folders paths, but I don't know if this DLL still exists for Vista and Win7. http://www.thescarms.com/vbasic/specialfolders.aspx
Is your myDatabase deployed with your application? In other words in the original VB6 project did you hard code the path to your Dbase? Because in W7 it is very hard or even impossible to address the Program Files directories(X86) or 64bits without Admin rights
I suggest that you either deploy your app in a different folder(e.g. c:\MyApp) which will contain the new Dbase if I understand correctly.
I don't know if there is such as syntax as "SELECT * INTO..." and you haven't specified which type of database you are using, but most databases should support the following syntax: cSQL01 = "INSERT INTO My_New SELECT * FROM Old_Table WHERE VAL(VRSK) > 0"
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Douw Kruger Sent: January 20, 2011 12:29 AM To: [log in to unmask] Subject: [VB-B] Query
A great resource for SQL queries is the w3schools website. Here's a link to the page that explains the SELECT INTO statement http://www.w3schools.com/sql/sql_select_into.asp
Regards, /tr
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Douw Kruger Sent: Thursday, January 20, 2011 12:29 AM To: [log in to unmask] Subject: [VB-B] Query
Hi
I have a table from which I want to select data into another table
----- Original Message ----- From: "Douw Kruger" <[log in to unmask]> To: <[log in to unmask]> Sent: Wednesday, January 05, 2011 5:47 PM Subject: [VB-B] Recordcount
> How can I get the number of records in a newly created table where the > table > was created with > > > > mProcNameMaand = "xyz" > > mProcName = "ABC" > > strMaand = "02" > > > > oCon.ConnectionString = ..... > > oCon.Open > > cSQL01M = "SELECT * INTO " & mProcNameMaand & " FROM " & mProcName & " > WHERE MID(DATUM,4,2) = " & strMaand > > oCon.Execute
Is there a VB6 method, object or function that will send a HTTP request (with GETS) to a url and wait and receive the HTTP response as a text string? (I have been working with Android and java's HttpClient is a very handy thing that I have found many uses for.)
I believe you can use the WinSock control for this request when using VB6. If I remember correctly you have a URL property and and execute method for your POST/Get.
Let us know how this works out for you.
G'Luck Bob Coward
-----Original Message----- >From: John Brown <[log in to unmask]> >Sent: Jan 4, 2011 11:50 AM >To: [log in to unmask] >Subject: [VB-B] HttpClient for VB6 > >Hello to all, > >Is there a VB6 method, object or function that will send a HTTP request >(with GETS) to a url and wait and receive the HTTP response as a text >string? (I have been
Also in addition to Bob's mention of the Winsock control there is MSXML that provides all that functionality. You have it already installed on your computer if you have Internet Explorer installed. You can find examples of using it by Googling also there is a SDK (MSXML SDK) on MSDN somewhere.
------Original Message------ From: Douw Kruger Sender: Visual Basic Beginner's List To: [log in to unmask] ReplyTo: Visual Basic Beginner's List Subject: [VB-B] SUM TOTAL OF COLUMN Sent: Jan 1, 2011 12:34 PM
Hi
I have a table called Theron in a MDB file. In this table is a column called PRICE. It is a text field that's used to store values.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Petter Osucha Sent: 01 Januarie 2011 07:46 nm To: [log in to unmask] Subject: Re: [VB-B] SUM TOTAL OF COLUMN
Why are you storing prices in a text field?
Use the database's SUM() function.
What VB version?
------Original Message------ From: Douw Kruger Sender: Visual Basic Beginner's List To: [log in to unmask] ReplyTo: Visual Basic Beginner's List Subject: [VB-B] SUM TOTAL OF COLUMN Sent: Jan 1, 2011 12:34 PM
I'm wanting to create a tab page with a unique function. The only concern I have is the fact that I want to lay it out visually yet design the code behind it. The previous extensions I have done have only needed me to modify the code behind them. Is there any way to accomplish this?
A couple of questions / solutions come to mind here.
Do you need to have all tab of the pages in the TabControl use the inherited tab page, and are you overriding just the TabPage, or the entire TabControl?
Do you need to be able to use the TabPage in the designer (adding controls to it at design time)?
On 12/31/2010 2:55 PM, Robert Lee wrote: > A couple of questions / solutions come to mind here. > > Do you need to have all tab of the pages in the TabControl use the inherited > tab page, and are you overriding just the TabPage, or the entire TabControl? > > Do you need to be able to use the TabPage in the designer (adding controls > to it at design time)? > > If you just need a custom control docked into a TabPage (even if you need a > lot of them) then you could create a
In that case I'd create a new UserControl (ATwitterListControl) that has all of the functionality that you need for a single list.
When you create the new TabPage in code (after the user selects the list) you can just add a new instance of the UserControl to the tabPage, and dock it. Just create properties and methods in the UserControl that you can access to pass data back and forth.
On 12/31/2010 3:24 PM, Robert Lee wrote: > In that case I'd create a new UserControl (ATwitterListControl) that has all > of the functionality that you need for a single list. > > When you create the new TabPage in code (after the user selects the list) > you can just add a new instance of the UserControl to the tabPage, and dock > it. Just create properties and methods in the UserControl that you can > access to pass data back and forth. > > HTH, > Rob
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of John Meyer Sent: Saturday, January 01, 2011 8:18 AM To: [log in to unmask] Subject: Re: [VB-B] Extending a tab page
That worked, thanks
On 12/31/2010 3:24 PM, Robert Lee wrote: > In that case I'd create a new UserControl (ATwitterListControl) that has all > of the functionality that you need for a single list. > > When you create the new TabPage in code (after the user selects the list) > you can just add a new instance of the UserControl to the tabPage, and dock >
> I am trying to do sorting of Armenian text (our alphabet is > "non-latin") in listbox or combobox. Does anyone know if there is any > approach to the problem of sorting texts with "non-latin" characters?
> Just a general idea: I thought of assigning a number to each letter > and then sorting by numbers: > E.g. > a=1 > b=2 > ... > This method could be fine if the items are stored in a database (each > word could have
Yes, Steve, I know it is a very problematic issue, but someone some time has to start dealing with it. The problem is that our alphabet consists of 39 letters, otherwise I could associate Armenian characters with English ones and that's all. As for the leading zeros: do we really need them? I mean if numbers are separated by commas or dots (like 1.2.5.39.5) won't such combination of figures be sorted correctly? For example, sorted in descending order: 1.5.25.4 1.7.2.5 2..10.6 ... I tried searching the web, but nothing helpful so far.
Oh, by the way, April 7 is the day of maternity and beauty in Armenia (women's day, like March 8), so in this regard I would like to wish all women and girls on the list (as well as mothers, wives and girl-friends, daughters of other members) love, happiness and beauty, so that they always make our life better :))
>I am trying to do sorting of Armenian text (our alphabet is >"non-latin") in listbox or combobox. Does anyone know if there is any >approach to the problem of sorting texts with "non-latin" characters?
Perhaps the CompareStringA API might be an approach you could take. Quote from the free API-Guide:
"The CompareStringA function compares two character strings, using the locale specified by the given identifier as the basis for the comparison."
Thank you, Toby, I will try it. Unfortunately comments are in German, and I am not such an experienced programmer to say that I do not need comments in code written by others. Anyway, I'll try to figure it out. As for the Armenian locale: is it "1067 ??" (and what do the question marks mean? I guess these are some characters my mail agent failed to display correctly).
The reason the leading zeros are important is because the sort is done Alphanumerically. Let me try to explain. Alphanumeric sorting is done one character at a time, as if the digits were strings, so when it compares "4" and "17", it actually is comparing "4" and "1", so "17" is less than "4", even though 17 (the value, not the string) is greater than 4 (the value, not the string). but, if you add the leading zeros, then it will compare "04" and "17" and it will find that "0" is less than "1".
I would like to thank everybody for the inputs, but I need some time to test the suggestions and process the information provided :)) So, I will come back with the results...
Thank you once more.
Best regards, Ed
Saturday, April 7, 2007, 1:50:59 PM, you wrote:
> The reason the leading zeros are important is because the sort is done > Alphanumerically. Let me try to explain. > Alphanumeric sorting is done one character at a time, as if the digits were > strings, so when it compares "4" and "17", it actually is comparing "4" and > "1",
I came to the conclusion that the method you have suggested suits me best, but I have one more question connected with locale: the Armenian locale you have specified in your e-mail is 1067 (I found the the same on the Internet), but in the code the locale for German is &H800 (the format is quite different). Could you please explain me what is the difference?
On 12/25/2010 1:09 AM, Douw Kruger wrote: > I have a big table in a MDB that must be sorted and then saved in the sorted > state. > > > > Any indications on how to do this. >
SQL, retrieve results in an array, delete, then do an insert.
sorry to not answer your question but relational database concepts say sorting is unimportant for storage. you can run sql queries to sort whenever you like. so i would ask you why you need the results to be stored in a sorted state.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of John Meyer Sent: December 25, 2010 6:58 AM To: [log in to unmask] Subject: Re: [VB-B] Sorting
What you want cannot be done. Access stores data on your drive based on a hashing routine, where/how it places the data is anyone's guess (well there are ways to sort of predict but who cares) . What you might consider is making a primary key that orders the data the way you want so that when someone opens the table in the Access GUI they see what appears to be the data in a particular order. For example if I wanted to keep a table ordered by last names I might use for the primary key the first 4
On 12/26/2010 6:24 AM, John Warner wrote: > What you want cannot be done. Access stores data on your drive based on a hashing routine, where/how it places the data is anyone's guess (well there are ways to sort of predict but who cares) . What you might consider is making a primary key that orders the data the way you want so that when someone opens the table in the Access GUI they see what appears to be the data in a particular order. For example if I wanted to keep a table ordered by last names I might
I will not have access to e-mail during this time. I will respond to your message when I return. If this is regarding an urgent matter, please contact Phil Pinkowsky.
Have a great day! Tanya Hodorowski
Note: This is an automated response to your message "[VB-B] Replicate table" sent on 12/11/10 2:59:32 AM.
In an msaccess data base, I'd store those pdf files as objects. That's how Microsoft stores all of the clip art it puts on Windows systems. We were shown that in a beginning Msaccess class some years ago.
On 4/14/2010 4:03 AM, Douw Kruger wrote: > Is it possible to store a pdf file to a memo field on for instance a Access database? > > Regards > > Douw
not a memo field. You could store it as a BLOB, but as any database developer will tell you that's not what databases are for. You're much better off storing the filepath.
Which of the following be the best way if a huge table containing the detail of items registered against invoices must be searched for the detail of a specific invoice.
1). Using a SQL statement using " Select ......." OR 2). Create a primary index and then using Find
If you are searching for a small set of data from large table, u can try on indexing.
On Sat, Apr 3, 2010 at 12:15 AM, Douw Kruger <[log in to unmask]>wrote:
> Which of the following be the best way if a huge table containing the > detail of items registered against invoices must be searched for the detail > of a specific invoice. > > 1). Using a SQL statement using " Select ......." OR > 2). Create a primary index and then using Find > > Advise / suggestions will be appreciated. > > Regards > > Douw > >
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]]On Behalf Of Douw Kruger Sent: Saturday, April 03, 2010 1:15 AM To: [log in to unmask] Subject: [VB-B] Selecing / Finding data
Which of the following be the best way if a huge table containing the detail of items registered against invoices must be searched for the detail of a specific invoice.
Please excuse me if VISBAS-BEGINNERS is not the place for this subject. (If not here, where?)
I know how to do this in ADO but not ADO.NET. In the following code myReader is iterating through the Batches Table contents. The code works just fine with no errors if there are Transactions for myReader("BatchID"). If there are no Transactions for myReader("BatchID"), there is an error written in the Immediate Window which says "A first chance exception of type 'System.InvalidCastException' occurred in Microsoft.VisualBasic.dll". The Try, Catch, End Try keeps the application running w/o crashing but when myCommandEX.ExecuteScalar() returns DBNull, the error
Do a search on DBNull and ADO.Net, I think you need to use something other than DBNull to represent Nothing.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of John Brown Sent: Wednesday, March 31, 2010 1:21 PM To: [log in to unmask] Subject: [VB-B] my shortcommings with ADO.NET
Hello,
Please excuse me if VISBAS-BEGINNERS is not the place for this subject. (If not here, where?)
Try: If TypeOf(myCommandEX.ExecuteScalar()) Is DBNull
Jeff Tsay
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of John Brown Sent: Wednesday, March 31, 2010 1:21 PM To: [log in to unmask] Subject: [VB-B] my shortcommings with ADO.NET
Hello,
Please excuse me if VISBAS-BEGINNERS is not the place for this subject. (If not here, where?)
I know how to do this in ADO but not ADO.NET. In the following code myReader is iterating through the Batches Table contents. The code works just fine with no errors if there are Transactions for myReader("BatchID"). If there are no Transactions for myReader("BatchID"),
Thanks for the suggestion. I implemented the suggestion but it creates more errors and causes the app to operate incorrectly.
Here is the code: Do While myReader.Read() Dim myCommandEX As OleDbCommand = connX.CreateCommand() myCommandEX.CommandText = "SELECT SUM(Amount) as BatchTtl FROM Transactions " _ & "WHERE BatchID = " & myReader("BatchID").ToString Try If TypeOf (myCommand.ExecuteScalar()) Is DBNull Then dblTtl = 0 Else dblTtl = CType(myCommandEX.ExecuteScalar(), Double) End If Catch dblTtl = 0 End Try Loop
I guess you might also need to check the type for myReader("BatchID") before concatenating the returned value to the string to be assigned to the command text.
Jeff
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of John Brown Sent: Thursday, April 01, 2010 12:59 PM To: [log in to unmask] Subject: Re: [VB-B] my shortcommings with ADO.NET
Jeff,
Thanks for the suggestion. I implemented the suggestion but it creates more errors and causes the app to operate incorrectly.
Why do you have your object declared as myCommandEX butthen use the object myCommand? Or is this just a typo in your message.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Jeff Tsay Sent: Thursday, April 01, 2010 11:51 PM To: [log in to unmask] Subject: Re: [VB-B] my shortcommings with ADO.NET
Hi! John,
I guess you might also need to check the type for myReader("BatchID") before concatenating the returned value to the string to be assigned to the command text.
If you are asking me, I guess John declared myCommandEX as an oleDb.OleDBCommand (i.e., a data command in ADO.NET, not a command button in a window form).
Jeff
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Frank Corrao Sent: Friday, April 02, 2010 6:11 AM To: [log in to unmask] Subject: Re: [VB-B] my shortcommings with ADO.NET
Why do you have your object declared as myCommandEX butthen use the object myCommand? Or is this just a typo in your message.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]]On Behalf Of Frank Corrao Sent: Friday, April 02, 2010 5:11 AM To: [log in to unmask] Subject: Re: [VB-B] my shortcommings with ADO.NET
Why do you have your object declared as myCommandEX butthen use the object myCommand? Or is this just a typo in your message.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Jeff Tsay Sent: Thursday, April 01, 2010 11:51 PM To: [log in to unmask] Subject: Re: [VB-B] my shortcommings with ADO.NET
Dim myCommandEX As OleDbCommand = connX.CreateCommand()
OleDbCommand is a "Microsoft New Speak" name for a ADO.Net Command Object to work on a Jet Database Engine database. If I try to make sense out of the names Microsoft uses, I just get confused. Well actually, when it comes to new Microsoft stuff, I guess confused is a normal state of being, at least for me. I do believe, but I may be wrong, that there are people smarter than myself that actually understand that stuff but I am sure that it is a very, very small percentage of people.
On 3/28/2010 2:40 AM, Douw Kruger wrote: > In VB6 a Access file was opend with > > Public ppDBase As New ADODB.Connection > ppDBase.ConnectionString = _ > "provider=Microsoft.jet.OLEDB.4.0;"& _ > "Password=xxxxx;Data Source = c:\data\MyDB.mdb" > ppDBase.Open > > > What is the proper way of opening the new 2007 Acess databases ending on. ACCDB > > Regards. > > Douw > > > > ------------------------------------------------------------ > - The VISBAS-BEGINNERS list is hosted on a Windows 2003(TM) server > running L-Soft international's LISTSERV(R) software. > - The List Archive can
I'm looking for a tutorial on https, since I need to enable it in a library that I'm working on. Does anybody have a good .NET tutorial out there. C# is fine if I can translate it on over.
What is it you don't understand? HTTPS is just a protocol that encrypts the traffic over your HTTP connection. You place a certificate in IIS (IIS manual will tell you how also the certificate issuer will have instructions). Otherwise design your page as normal. If you need to move them from http://John.Meyer.com to https://John.Meyer.com you just use any of the redirect options in dotnet.
As John said it is just a port setting change in IIS, regular http will usually use the 80 ports (80,81, etc..) or 8080 ports. For HTTPS you usually use port 443. There is one thing though that you will need to read up on and that is certificate styles, by default your code will want a certified certificate, in some cases it will take some coding to have it accept a non-certified certificate (one that you issue yourself via a Windows Server running Certificate Server.
Okay, BTW, It's not necessarily going to run on an IIS server (I'm working on twitterVB at http://twittervb.codeplex.com). I'm just wondering if any of the calls that I would make via normal httpwebrequests would radically change because I'm using https as opposed to http.
On 3/25/2010 5:24 AM, Frank Corrao wrote: > As John said it is just a port setting change in IIS, regular http will usually use the 80 ports (80,81, etc..) or 8080 ports. For HTTPS you usually use port 443. There is one thing though that you will need to read up on and that is
Still the same thing, it may not be a full IIS, or it may even be apache or IBM Sphere or something else, the principle is still the same. The http protocol is common to all those, implementation and features may be different. I would do some searches on https and twitter.
Hi, We have one of the VB.net 2005 front end with the SQL backend application. the application works fine for most of the users, for some reason, there is a user has trouble to see the full screen of the form. I have uninstall and reinstall the application serval times, and I have changed the user's display resolution 1024by768, 1152 by 864... multiple. But the user still will not able to see the whole screen. The bottom at the screen (multiple buttons) was missing. Any ideas? Thanks! Dorothy
My wife had cataracts until recently - I used Accessibility (a Windows setting to assist with poor vision) so that screen text can be read more easily. The downside is that nothing fits onto the screen anymore, despite re-installs, changing form settings in .Net, etc.
Have these settings been applied to your user's computer?
Most likely a custom font or DPI settings is effecting the screen layout. The best way to handle this is to develop the forms to be completely independent of the users screen size.
For instance even though _my_ monitors are 1600*1200 / 1600*1050, I develop for 1024*768, and set everything to scroll if the screen gets smaller. If someone uses 800*600 or a custom DPI they will have scroll bars on most screens, but at least they can get to everything.
Thank you very much Jonathan. I have checked the users Display Properties theme as well. Font size as normal. But I have not try the Accessibility. Thank you very much. I will let you know.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of J Trahair Sent: Monday, March 22, 2010 1:13 PM To: [log in to unmask] Subject: Re: [VB-B] Partial of the Sceen View
Thank you Rob for those great tips. Going forward I will adapts those tips for my applications. Good to know. I do not own the application below. I have to help users on this issue.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Robert Lee Sent: Monday, March 22, 2010 2:00 PM To: [log in to unmask] Subject: Re: [VB-B] Partial of the Sceen View
I need to write some java stuff for an android application. Anybody know of any "learning java for the VB6 programmer" resources?
As a matter of fact, when I first investigated android, I went to a beginners forum and there was a discussion about VB Net. Since I have found no other reference to VB anywhere in android stuff, I just dismissed it as some misguided beginners. Anybody have any information about this?
I used the following code in VB6 to read data from a Random Access file with fixed data lenghts
Private Type DeleteCode As Byte TransDate As String * 11 Iets01 As String * 11 Iets02 As String * 11 Iets03 As String * 11 TransDate2 As String * 11 TransCode As String * 11 Iets04 As String * 4 AccountNo1 As String * 11 AccountNo2 As String * 21 CustLastName As String * 30 ContactNumber As String * 19 Someth1 As String * 12 Operator As String * 6 Someth2 As String * 1 Taal As String * 1 Race
There are a couple of solutions. One will look like what you are used to using with VB6, but is slow, clunky, and requires the use of the Microsoft.VisualBasic.Compatibility namespace, which isn't distributed with the framework, and not supposed to go into a production environment. The best way to see how this method works is to open your vb6 project with VS 2008 and let the upgrade engine do its magic. This method would upgrade your fileOpen methods, and use a file handle to access the data.
I am trying to unzip a compressed .zip file with VB Net 2005. I got some code from MSDN http://msdn.microsoft.com/en-us/library/system.io.compression.deflatestream. aspx but I get the error "INvalidDataException was unhandled - Block length does not match with its component". When I look that up it says: The exception that is thrown when a data stream is in an invalid format. I even zipped a file with Win XP and still got the error. I am not making much progress with this code.
He issue is exactly as stated, the compression formatthat is used. If you are compressing the file try using dotnet to compress it, then you should be able to use the basic dotnet uncompress stream, otherwise you need to use the same compression format, most of the compression tools have their own format but one that WinZip uses is most common.
This part within your link might suggest you could experience unexpected results:
"This class does not inherently provide functionality for adding files to or extracting files from .zip archives."
Check out SharpZipLib. You could also use a GPL solution (http://www.icsharpcode.net/OpenSource/SharpZipLib/Default.aspx). There is lots of code using that solution. If Push comes to shove there is a way to use J# but then you get into deploying J# stuff (http://msdn.microsoft.com/en-us/magazine/cc164129.aspx).
For years I have used the following code to successfully print a picture (in colour if on a colour printer).
Printer.PaintPicture LoadPicture(mstrAppPath & "Logo header with address.jpg"), 2000, 800
For instance, this prints a company logo and address image onto the paper.
In Vista, sometimes, it prints in black and white to a particular colour printer, although other programs eg. Word always print in colour onto that printer, and the VB app always prints in colour to a virtual printer eg. a pdf file.
Hi, I have a VB.NET window based project and I have create a setup file. But after I setup, there is no icon on the desktop as well as in the "User's Program Menu"
I have added an setup file into the Solution. Under the setup file, there are Detected Dependencies and Primary output from mypooject.
Dorothy, Please send you replies in 'Plain Text' I don't know what format you are using, but it's nearly impossible for me to read using 'Outlook'
Cheers & HTH,
Fred Lyhne
FAILURE IS NOT AN OPTION. It comes bundled with the software.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Robitaille, Dorothy L Sent: Tuesday, February 09, 2010 10:46 AM To: [log in to unmask] Subject: Re: How to creat an shortcut icon on user's desktop - VB.NET 2005
I have Outlook 2007 and it came in just fine, there are some settings in the Options that might help
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Fred Lyhne Sent: Tuesday, February 09, 2010 12:55 PM To: [log in to unmask] Subject: Re: [VB-B] How to creat an shortcut icon on user's desktop - VB.NET 2005
Thank you Fred for letting me know my email format has the problem
I got it about how to create a short cut on my desktop for a window based application using VB.net setup and deployment. *Here is what you need to do to generate a icon on the desktop 1. From Solution Explorer click your setup project. 2. Click File System Editor (on top of Solution Explorer). 3. When File System Editor has opened, on left tab you can see "File System on Target Machine". Click Application Folder. 4. Then on the left tab the "Primary output from MyApp
Could somebody have a look at this code and tell me what I'm doing wrong. So far I'm getting the correct count of elements, but they're all the first element. Here's the URL for the documentation http://twic.li/api And here's a sample of what I am parsing through http://twic.li/api/getUsersContent?username=twiclistaff&content_type=photos
Public Overloads Function GetUsersPhotos(ByVal p_strUserName As String) As List(Of ATwiCliPhotoFile) GetUsersPhotos = New List(Of ATwiCliPhotoFile) Dim strURL As String = TCC_GET_USERS_CONTENT_URL & "?username=" & p_strUserName & "&content_type=photos"
Hi, Thanks again for all the post. I have added a deployment project into the solution. Your advices are very help during the processes.
I have created a setup project into the my project solution and output group I selected Primary output for Deploy. I have added an icon during the deployment. But after installation, there is an icon on the desktop. When I click it, the icon is not point to the EXE file.
First off Dorothy on your development machine change the location of the database to where you would like the production version to hold the database, having it install to a debug location is not good practice.
Next question, is the ReferenceData.mdb preloaded with information? If the answer is yes then you will want to add the mdb file to your deployment, it does not need to be in the project folder that you are looking at in solution explorer but it can be. In the deployment project you will be asked if there are any external files, you will say
Great Advise Frank!! Let me try thank you so very much!!
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of Frank Corrao Sent: Wednesday, February 03, 2010 2:35 PM To: [log in to unmask] Subject: Re: [VB-B] Need some advise prior to deploy an application
First off Dorothy on your development machine change the location of the database to where you would like the production version to hold the database, having it install to a debug location is not good practice.
I would also suggest that you have a facility to create/refresh/update the reference database - tables and data using flat files (such as .TXT or SV) - Scripts to create the tables, indexes and links, etc. and then load the data from files Also scripts to update the table content, remembering that the client/user systems may create their own links to the tables and data you provide. Regardless of any warnings you issue and include in the facility and it's installation process they will try, and then complain bitterly and loudly if your facility has to be re-created to
Hi Jim. Thank you for your suggestion. Currently I am using the Access.mdb bile. Refresh data will be a issues going forward. Are you saying that I have to use the xxx.txt or csv file instead of MDB file If I want to create/refresh/update the reference database? I did not get it.
I have a "shade tree" idea that I tried several years ago that has proved to be useful. In the default directory I provide a station setting text file I open this file and it contains the path and filename of the database. Then I incorporate this info into my connection string.
This has been useful. I have not found any limitation. Works with multi user and servers, etc. And it is really handy when Microsoft comes out with new restrictions as to what you can do in what directory.
Consider (as limited by the usage licence, and terms of your facility). The user has your data in a .mdb - and adds their tables and data into that .mdb The user has your data in a .mdb - and extracts it from the tables you supply into their Excel workbook(s) and uses it for lots of their own developed Excel facilities
Thanks for sharing John. So ArchivesSS.txt has the path of ArchivesXX.mdb. ArchivesSS.txt will be located in the share server or local path after deployment?
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of John Brown Sent: Wednesday, February 03, 2010 3:55 PM To: [log in to unmask] Subject: Re: [VB-B] Need some advise prior to deploy an application
I suspect that idea could be expanded to include userid/passwords and other control values for use within the Access environment with NTFS file access controls on the text file to restrict access to those passwords to authorised users That way you could have a different version of the file in each authorised users OS managed 'usersfiles' area
Thank you Jim for the explanation. It is new to me. But it is very useful. I will need to spend some time to better understood your notes. Something new that I can research for it.
-----Original Message----- From: Visual Basic Beginner's List [mailto:[log in to unmask]] On Behalf Of James Button Sent: Wednesday, February 03, 2010 3:58 PM To: [log in to unmask] Subject: Re: [VB-B] Need some advise prior to deploy an application
Sorry for the delay. ArchivesSS.txt is located in the same location as the application. In a multi user enviornment each user (station) would have a setting (thus the SS) that contains the location and name of the mdb file you are using. One user might have have the server mapped as drive L: so the ArchivesSS.txt file would contain "L:\SpecialPlace\OurInc\OurInfo.mdb" (without the quotes) and another user's computer might refer to the same file as "\\MainserverABC\SpecialPlace\OurInc\OurInfo.mdb". In this scenario the application is installed on each computer. And ArchivesSS.txt is the name of the file in the code I provided but
I am using the Outlook object to send email. I'm finding that the script doesn't actually send all the email. Some of it gets stuck in the Outbox, until I physically open Outlook. Is there a setting or method I should be using to force the emails to go right away? We recently upgraded to Office XP and it was working fine with Office 2000.
Is it set to send immediately? Is there an option on the messagesend 'command' to tell it do it 'now'?
JimB
----- Original Message ----- From: "Randy Anderson" <[log in to unmask]> To: <[log in to unmask]> Sent: Friday, February 05, 2010 5:45 PM Subject: [VB-B] Outlook object keeping mail in outbox
I am using the Outlook object to send email. I'm finding that the script doesn't actually send all the email. Some of it gets stuck in the Outbox, until I physically open Outlook. Is there a setting or method I should be using to force the emails to go right away? We recently upgraded
The actual program is set to send email immediately. I don't see a method for the mail object that would make it do it now. In fact before we upgraded, the messages were sent "now".
Randy Anderson BC Mail Plus Phone: (250) 952 4383 Fax: (250) 952 5117 E-mail: [log in to unmask] Visit us online at: www.pss.gov.bc.ca
Sorry, that was my best guess at a simple reason/solution hopefully someone else can help
Perhaps the win-home and/or winnt forums, or an outlook one, or news.microsoft.com news-server forum
JimB ----- Original Message ----- From: "Anderson, Randy S SSBC:EX" <[log in to unmask]> To: <[log in to unmask]> Sent: Friday, February 05, 2010 7:12 PM Subject: Re: [VB-B] Outlook object keeping mail in outbox
> The actual program is set to send email immediately. I don't see a method > for the mail object that would make it do it now. In fact before we > upgraded, the messages were sent "now". > > Randy Anderson
"full-featured Microsoft NTP client that comes built-in with Windows 2000, Win-XP",
and probably Vista and Win-7 ?
Ming: are you using older Operating Systems ?
Many Thanks, Steve
-----Original Message----- From: Visual Basic Beginner's List On Behalf Of Lam, Ming Sent: Thursday, February 04, 2010 3:13 AM To: [log in to unmask] Subject: Re: V-B Digest - 3 Feb 2010 (#2010-13)
Since I was asking a question it would probably be best to see what my XP-Pro machine is set up to do on this score.
I discovered that I have three choices for a Time Server, and that while I can manually do a time check/update by clicking the button, the OS is set to do it on its own, automagically, at 6 AM every 7 days.
We had a set of machines that needed to be synced several times a day, or a 3rd party app would cease to recognize our time stamps correctly. For this I just added a call to "Shell("net time /...", AppWinStyle.NormalFocus)..."
If you start a command prompt and type "net time /?" it will give you a list of the switches that you can pass, including the machine name that you want to sync to.
I have a written a program in vb6 using the sendkeys function. It works well in xp and xp pro but the problems that come with using the sendkeys function have popped up when installed in Vista and #7. I am looking for help with the API replacement or a .bas module that will replace this function.