Jump to content
Xtreme .Net Talk

lothos12345

Avatar/Signature
  • Posts

    294
  • Joined

  • Last visited

About lothos12345

  • Birthday 04/07/1979

lothos12345's Achievements

Newbie

Newbie (1/14)

0

Reputation

  1. I have written a Visual Basic application which incorporates the use of the txtextcontrol and crystal reports. For those who do not know the txtextcontrol is a control that allows us to make programs we create look more like microsoft word. My problem comes in when I try to use rtf tables in the txtextcontrol. I insert a table and use the columns and rows and it looks fine in the application. But when I do a print preview which incorporates Crystal Reports the text I put in the tables is horribly spaced. I researced this and basically I was told that crystal reports does not handle rtf tables very well. I need a way for users to use tables in my application and have it display correctly on the crystal report. Any suggestions would be greatly appreciated. I am using Visual Basic.NET 2003 and Crystal Reports 9.0.
  2. I have written a Visual Basic.NET application. It's intent is to run on a VPN Server, that means that the user are going to have severly restricted abilities to include not even being able to write to a directory. The way around this was to impersonate an administrator log on at the run of the application. This has caused another problem when the user has VPN in from home and is starting to use this application everything is fine until they try to print from this application. My supervisor tells me that the print out should be printed out on their printer at home and this is automatically handled by the VPN serves in otherwords we do not have to worry about it in code but he thinks that since we are impersonating an administrator logon this impersonation stops this from working correctly. We need to impersonate an adminstrator in order to write to the directory and to get the process name which we do as well. If we do not impersonate an administrator it fails. Any suggestions or advice would be greatly appreciated.
  3. I am impersonating and administrator logon for one of my visual basic.net applications. My problem comes in when I try to print the a report using the application, it keeps going to the default printer under the administrator account and not the user who is currently logged into the computer. I am working with Crystal Report 9.0, I am stopping the impersonation right before the print but it still goes to the administrator account for the default printer. How can I resolve this? Any help offered is greatly appreciated.
  4. The app opens and I can read the registry but I cannot read any process information to include the username and id. I am trying to create a directory in the Startup path of the application. I have thought of something but I am not sure how to accomplish it. Is there a way I can run the app as administrator and program this from the application?
  5. I have written a visual basic.net class who's sole purpose is it get the user name and process id of a person that is running the particuliar application in which has this class and use that information to create a unique directory with a particularily name text file. This application works great if I am logged in as administrator into the machine but if I log in as someone else I cannot get the process information nor can I get the right to create the unique directory. Ideally the solution would be to increase the permissions of the Logon, unforunately this is not an option. I need the ability to do perform all the required actions as with administrator powers though I am logged in as the lesser user. This needs to be done in code. Any examples or help would be greatly appreciated.
  6. I have written a visual basic application that interacts with 2 types of scanners the Kodak and the Visioneer scanners. My problem is when I get a document that is too light. In the Kodak it scans in as is however the Visioneer degrads the scan to a point where it is unreadable. Adjusting the brightness does work but when that happens the scanner will no longer read a barcode which can be associated with some documents. I am kinda of a wits end, any suggestions/thoughts on how I can handle this would be greatly appreciated.
  7. You were absolutely correct it was killing itself before the it killed the other instances. Thanks for your help.
  8. i have written a visual basic.net 2003 application and upon it closing I want it to kill all instances of the application that are running, so I used the code below Dim proc() as Process proc = Process.GetProcessesByName("AppName") For Each SingleProcess as Process in Proc SingleProcess.Kill Next The above code works generally well but there are occasions when it will not close all instances of the application and I am not sure why. If anyone can shed some light as to the reason, it would be greatly appreiciated. Thanks
  9. I have a button that bolds selected text in an Rtf textbox. The problem is I want to be able to unbold the selected text if they click the bold button again the and the selected text is bolded. Just adding and undo button will not work because the user could have made several changes since bolding the selected text. Basically I want it to work like Word. This has to be in Visual Basic.NET. Any help given is greatly appreciated.
  10. Can anyone explain to me how to accomplish the following? I need to find a method in VB .net to enumerate a process user name or sessionid. User name is preferred. Native is preferred, using system.diagnostics, if not available then API and WMI as last option. Any help offered is greatly appreciated.
  11. I have a crystal report issue when I have a field in the detail section with the Can Grow property of that field checked it does work as expected but when wrapping I get and issue like WWWWWWWWWWWWW WWWWWwwwWWWWWW and I need it to wrap like WWWWWWWWWWWWWW WWWWWWWWWWWWWW Any ideas on what may be causing it to wrap text incorrectly would be greatly appreciated.
  12. I have created a Visual basic.net application that uses a visioneer 9650 usb scanner. I am using an eztwain class given to me by the supplier to interface this scanner with my application. My problem is when I scan an image in that has been faxed to me the application turns the whole image black or rather inverts it. The white becomes black and black becomes white. And it is doing this automatically. However other images I scan in it scans fine though the other images are not faxed to me. Anyhow an example of the code I am using is pasted below: My problem is that it inverts images when it shouldn't. Dim fileName As String fileName = "c:\image.tif" Call EZTwain.SetHideUI(1) Call EZTwain.SetIndicators(0) Call EZTwain.SetFileAppendFlag(0) If EZTwain.OpenSource("Visioneer 9650 V1.10") <> 0 Then Call EZTwain.SetPixelType(0) Call EZTwain.SetBitDepth(1) Call EZTwain.SetResolution(200) Call EZTwain.SetXferCount(1) Call EZTwain.SetAutoScan(0) Call EZTwain.DIB_SmartThreshold(Me.Handle) Call EZTwain.AcquireToFilename(Me.Handle, fileName) End If If EZTwain.LastErrorCode() <> 0 Then Call EZTwain.ReportLastError("Unable to scan.") End If Any help offered is greatly appreciated.
  13. I have written a sql query that a crystal report is using the query I wrote is as follows: -------------------------------------------------------------------------- SELECT TOP 100 PERCENT dbo.tblPtProgReportMain.PtProgHeader, dbo.tblPtProgReportMain.PtProgFooter, dbo.tblPtProgReportMain.PtProgSalutation, dbo.tblPtProgReportMain.PtProgSigBlock, dbo.tblPtProgReportMain.PatientName, dbo.tblPtProgReportMain.PatientSex, dbo.tblPtProgReportMain.PatientProfileId, dbo.tblPtProgReportMain.PatientSSN, dbo.tblPtProgReportMain.PatientDOB, dbo.tblPtProgReportMain.PatientDOI, dbo.tblPtProgReportMain.nextvisitdate, dbo.tblPtProgReportMain.TreatingDoc, dbo.tblPtProgReportMain.TreatmentsNum, dbo.tblPtProgReportMain.TreatmentDates, dbo.tblPtProgReportMain.OtherRx, dbo.tblPtProgReportMain.Medication, dbo.tblPtProgReportMain.PhysicianComment, dbo.tblPtProgReportMain.PriorHx, '' AS DiagDesc, dbo.tblPtProgReportDetail.NoteValue, dbo.tblPtProgReportDetail.sortorder AS Detailsortorder, case dbo.tblPtProgReportMain.initeval when 0 then tblPTProgLists.Listtext WHEN 1 then tblPTProgLists.Listtext2 WHEN 2 then tblPTProgLists.Listtext3 end AS GroupName, tblPTProgLists.sortorder AS Groupsortorder, dbo.tblPtProgReportMain.ChiefComplaint, dbo.tblPtProgReportMain.initeval AS SupressCC, dbo.tblPtProgReportMain.Diagnosis, case dbo.tblPtProgReportMain.initeval when 0 then 'Physical Therapy Progress Note' when 1 then 'Physical Therapy Initial Evaluation' when 2 then 'Physical Therapy Daily Note' end AS LtrType, dbo.tblPtProgReportMain.printsig, ' ' AS docSigPic FROM dbo.tblPTProgLists WITH (NOLOCK) INNER JOIN dbo.tblPtProgReportDetail WITH (NOLOCK) ON dbo.tblPTProgLists.PtProgListid = dbo.tblPtProgReportDetail.PtProgGrpId Right outer JOIN dbo.tblPTProgReportMain WITH (NOLOCK) ON dbo.tblPtProgReportDetail.PtProgReportId = dbo.tblPTProgReportMain.PtProgReportId WHERE (dbo.tblPTProgReportMain.PtProgReportId = @rptid) UNION ALL SELECT '' as PtProgHeader, '' as PtProgFooter, '' as PtProgSalutation, '' as PtProgSigBlock, '' as PatientName, '' as PatientSex, '' as PatientProfileId, '' as PatientSSN, '' as PatientDOB, '' as PatientDOI, '' as nextvisitdate, '' as TreatingDoc, '' as TreatmentsNum, '' as TreatmentDates, '' as OtherRx, '' as Medication, '' as PhysicianComment, '' as PriorHx, '' AS DiagDesc, '' as NoteValue, '' as Detailsortorder, '' as GroupName, '' as Groupsortorder, '' as ChiefComplaint, '' as SupressCC, '' as Diagnosis, '' AS LtrType, '' as printsig, practicemanager.dbo.tblDocSigs.DocSigPic FROM Practicemanager.dbo.tblDocSigs INNER JOIN Practicemanager.dbo.PatientVisit ON Practicemanager.dbo.PatientVisit.DoctorId = Practicemanager.dbo.tblDocSigs.DoctorFacilityId INNER JOIN dbo.tblPtProgReportMain ON Practicemanager.dbo.PatientVisit.PatientVisitId = dbo.tblPtProgReportMain.PVID WHERE (dbo.tblPtProgReportMain.PtProgReportId = @rptid) -------------------------------------------------------------------------- The crystal report is the groupname to group by, my problem is that the information that is static such PatientName does not display. It is blank in the report I browsed the data in the field in the Field Explorer and the information is there it is just on the second line. And my signature does not come out at all it is the item in the second query of the union. I am not sure what to do the only thing that does work right is the displaying of the details using the group by. Please help and as always any help given is greatly appreciated.
  14. I have a visual basic.net application I have files in a folder and for each file in the directory I want too add them to an arraylist. But I want them to be sorted from top to bottom based on there creation times. How can I accomplish this? Any help offerred is greatly appreciated.
  15. I have a Visual Basic.Net application and for the data interface I am using Access I am feeding it a command string as follows: VarTemp = "SELECT IFIELD1, IFIELD2, IFIELD3, IFIELD4, IMAGELIST, IDNUM FROM INDEXDB1 WHERE (IFIELD1 LIKE 'BN*') OR (IFIELD1 LIKE 'BR*') OR (IFIELD1 LIKE 'ES*') OR (IFIELD1 LIKE 'IG*') OR (IFIELD1 LIKE 'WZ*')" This always returns nothing however when I put this same string in an Access query it returns what I expect it to return. Also from the application when I feed it the sql command: VarTemp = "SELECT IFIELD1, IFIELD2, IFIELD3, IFIELD4, IMAGELIST, IDNUM FROM INDEXDB1" It works as expected too. The issue I have is when I use the where clause and only when I use it from the program. There is something wrong with how I am feeding the where clause from the program though I am not sure what. Any help offered is greatly appreciated.
×
×
  • Create New...