Jump to content
Xtreme .Net Talk

mark007

Avatar/Signature
  • Posts

    185
  • Joined

  • Last visited

Everything posted by mark007

  1. Here's an example of my thinking. Seems to work pretty well. Could easily compile it to a custom control. :) CharacterWrappingtextbox.zip
  2. That's still going back in time so would be caught under marble's suggestion which is a method that I use. I have to partly agree with kejpa though that clock tampering is fairly unlikely. If you really wanted to get round it you could require an internet connection to run and store the times on a web server using the MAC address or HD serial for a unique key. Alternatively you could require this just once on initial start and use marbles suggestion for clock tampering. You would then stop them reinstalling windows and the app as they'd also have to replce the NIC and HD to get it working ;) :)
  3. Multiple text boxes might be a way to go though with one having had the additional characters added and one with the actual typed in string. The GotFocus of TextBoxDisplay could hide itself, unhide TextBoxOriginal and put the focus in that box. The lost focus event of TextBoxOriginal could then hide itself, show TextBoxDisplay and assign it text with spaces added after each c number of characters to force a wrap at that point thus giving the illusion of character wrapping. This should be pretty easy to set up I think and work quite well. :)
  4. I think you just want to remove the first slash which makes it start from the web root. :)
  5. There is a workaround. Don't know of it's legalities but I have it working on my laptop. You need a Windows 2000 CD to do it though. It should be legal in the sense of I have legal copies of WinXp Home and Win2000 Pro but who knows, it may not be. Apolgogies to the mods if this is the case! Full details can be found here: http://www.webthang.co.uk/tuts/tuts_server/iis_xph/pippo_xp.asp Personally I think it's quite incredible and annoying to say the least that you can shell out £500 for VS.Net and not be able to run half of it (ASP.Net) without XP Pro!
  6. So it's the query function that's giving you problems? What's it's prototype? :)
  7. I know, I have a similar option on my own forum. I just don't think it's applicable to this app. Thanks for the comments though! :)
  8. I would say use a standard multiline word wrapping textbox but use the keydown /keypress etc. event to add spaces to the words to force a wrap after x characters. The difficulty then comes in removing these spaces again if characters are deleted. Some sort of tracking of the spaces therefore needs putting in place. Off the top of my head I can't remember what events there are but you could do with a before keypress event that removes spaces and a after keypress event that adds them. HTH :)
  9. Like I say it's not possible to store a persistent cookie with details as the machines are multiuser.
  10. Only if you haven't used the app in the last 20 minutes. The PC's this will be run on may well be multiuser so a permanent cookie isn't really an option. :)
  11. Do you consider what I'm doing misuse? Fundamentally using a session is just using a cookie for an id and storing the data for that id on the server right? Where's the problem in checking part of that server stored data for a loggedin property for example? Don't get me wrong here, I'm not trying to prove you wrong or argue with you. Just want to see where potential flaws are... :)
  12. You're quite anti-sessions aren't you ;) Not really sure what you mean - but fundamentally I don't see an issue in using sessions unless MS mucked something up in their implementation. I use them all the time in PHP. :)
  13. Not sure exactly what you mean but the available properties of contact items (in 2000 anyway, there may be more in later versions) are: Account Property Actions Property Anniversary Property Application Property AssistantName Property AssistantTelephoneNumber Property Attachments Property BillingInformation Property Birthday Property Body Property Business2TelephoneNumber Property BusinessAddress Property BusinessAddressCity Property BusinessAddressCountry Property BusinessAddressPostOfficeBox Property BusinessAddressPostalCode Property BusinessAddressState Property BusinessAddressStreet Property BusinessFaxNumber Property BusinessHomePage Property BusinessTelephoneNumber Property CallbackTelephoneNumber Property CarTelephoneNumber Property Categories Property Children Property Class Property Companies Property CompanyAndFullName Property CompanyLastFirstNoSpace Property CompanyLastFirstSpaceOnly Property CompanyMainTelephoneNumber Property CompanyName Property ComputerNetworkName Property ConversationIndex Property ConversationTopic Property CreationTime Property CustomerID Property Department Property DownloadState Property Email1Address Property Email1AddressType Property Email1DisplayName Property Email1EntryID Property Email2Address Property Email2AddressType Property Email2DisplayName Property Email2EntryID Property Email3Address Property Email3AddressType Property Email3DisplayName Property Email3EntryID Property EntryID Property FTPSite Property FileAs Property FirstName Property FormDescription Property FullName Property FullNameAndCompany Property Gender Property GetInspector Property GovernmentIDNumber Property Hobby Property Home2TelephoneNumber Property HomeAddress Property HomeAddressCity Property HomeAddressCountry Property HomeAddressPostOfficeBox Property HomeAddressPostalCode Property HomeAddressState Property HomeAddressStreet Property HomeFaxNumber Property HomeTelephoneNumber Property IMAddress Property ISDNNumber Property Importance Property Initials Property InternetFreeBusyAddress Property IsConflict Property ItemProperties Property JobTitle Property Journal Property Language Property LastFirstAndSuffix Property LastFirstNoSpace Property LastFirstNoSpaceAndSuffix Property LastFirstNoSpaceCompany Property LastFirstSpaceOnly Property LastFirstSpaceOnlyCompany Property LastModificationTime Property LastName Property LastNameAndFirstName Property Links Property MailingAddress Property MailingAddressCity Property MailingAddressCountry Property MailingAddressPostOfficeBox Property MailingAddressPostalCode Property MailingAddressState Property MailingAddressStreet Property ManagerName Property MarkForDownload Property MessageClass Property MiddleName Property Mileage Property MobileTelephoneNumber Property NetMeetingAlias Property NetMeetingServer Property NickName Property NoAging Property OfficeLocation Property OrganizationalIDNumber Property OtherAddress Property OtherAddressCity Property OtherAddressCountry Property OtherAddressPostOfficeBox Property OtherAddressPostalCode Property OtherAddressState Property OtherAddressStreet Property OtherFaxNumber Property OtherTelephoneNumber Property OutlookInternalVersion Property OutlookVersion Property PagerNumber Property Parent Property PersonalHomePage Property PrimaryTelephoneNumber Property Profession Property RadioTelephoneNumber Property ReferredBy Property Saved Property SelectedMailingAddress Property Sensitivity Property Session Property Size Property Spouse Property Subject Property Suffix Property TTYTDDTelephoneNumber Property TelexNumber Property Title Property UnRead Property User1 Property User2 Property User3 Property User4 Property UserCertificate Property UserProperties Property WebPage Property YomiCompanyName Property YomiFirstName Property YomiLastName Property HTH :)
  14. Yep, I may do that but I'm not sure whether I want to yet for security reasons. I got everything I wanted to work working anyway so all seems good so far. Now just looking into some Custim Server controls for the menu. :)
  15. forms authentication isn't flexible enough for what I want. I don't believe that it will maintain the post data anyway from my reading of it. Also what's wrong with checking a session to see if someone is logged in? A session is effectively a cookie i.e. it comes via a cookie but main data stored on the server.
  16. Yes, could use the cache I guess. The danger is it's deleted sooner than expected due to lack of memory though. Hopefully this would be fine though so I might well go with this. Thanks for the suggestion. :)
  17. I by no means expect you to do the work for me!!! I still don't see how this works: But the whole point is that the session has expired so I no longer have these session details.....I therefore don't know who the user is. Thinking it through though I guess a possibility is to do it kind of backwards to your suggestion: 1) Store the data 2) Place the key used for storing this data into thenewly created session 3) When they login check if an "OldPostData" item exists in the sessions collection. 4) If so then obtain the data back This should work I think. Would also need a session_end event (or whatever it's called) to check for the existence of the "OldPostData" key and if so delete the data under this key. Or perhaps a safer way might be to have a cleanup whereby data over 1 day old is deleted... The user should then only have trouble if they take time to login - in which case tough! Thanks for the ideas, it got me thinking. :)
  18. The following should do the trick Sub Main() Try Dim objOutlook As Outlook._Application objOutlook = New Outlook.Application Dim objNS As Outlook._NameSpace = objOutlook.Session Dim objFolder As Outlook.MAPIFolder = _ objNS.Folders.Item("Public Folders") objFolder = objFolder.Folders.Item("All Public Folders") objFolder = objFolder.Folders.Item("Contact Mgmt") objFolder = objFolder.Folders.Item("RC Contacts") Dim objItems As Object = objFolder.Items Dim objItem As Object For Each objItem In objItems if System.Convert.ToString(objItem.Categories).IndexOf("Staff")>-1 then Console.WriteLine(objItem.Email1Address & vbCrLf) End if Next Catch ex As Exception Console.Writeline(ex.Message) End Try End Sub HTH :)
  19. How do I still know the userid etc.? What safe place did you have in mind? And what key could I use to access it again when they have logged in again? :)
  20. I don't think you are following, though maybe you are. Honestly, if this is doable I'd be quite pleased. (Yet to look at those exmaples you suggested michael). The code behind would look something more like: 'Code Behind Public titleimg As String Public template as String 'Your datasource .. dtrReader.Read titleimg = dtrReader("titleimg") template=dtrReader("template") dtrReader.Close How would you now insert title into the template at the relevant point and then ouput the completed template to the page? Solutions I can think of are: 1. define your own replace terms e.g. [=myvar] which you can replace using a the variable name in your code. Though for several variables this becomes several lines of code 2. More complicated - perhaps somehow use the compiler services to actually compile your template maybe.. Both of these fall well short of the simplicity of: eval("$parsedtemplate='".$template."';"); print $parsedtemplate; Are you meaning using a simple replace for your defined replace points at per 1 above? Or do you have something else in mind? :)
  21. I've searched around a bit but can't find anything that has handled POST data. There are numerous examples of the easy scenario of GET data. I have a Login Control that I place on each of my pages. This control checks the session to see if a user is loggedin or not and if they are set a LoggedIn property of the control to true so that the page the control is on can display the content and hide the login control or vice versa. If the login control is displayed they enter their username and password and hit login. The credentials are checked and any errors reported or the user is logged in. On being logged in the page can then be displayed. However I'm considering the scenario where someone is logged in and enters lots of details into a form to the extent that the session expires while they are doing this. They then hit submit and the form is posted back. The login control notices the session no longer exists and sets loggedin to false so processing is halted and the login control displayed. They then enter their username and password and hit login. How can I now access the data they originally filled in on the form. Clearly if it was simple data that used GET then I could just store the querystring. However posted data seems to be a different animal altogether. Any ideas? Help very much appreciated. :)
  22. Have posted here as it's effecting a web user control but this is possibly a more general query. As per the title I don't appear able to draw controls on the designer. Instead of the standard pointer to drag an area for the control I get a cursor and am therfore unable to drop controls on the designer. I have worked out a workaround in that if I right click on a control in the toolbox and select copy I can then paste it onto the deisgner. Anyone have any ideas as it's very irritating! :)
  23. Michael, how? do you have an example? Kahlua001, how would you execute the <% tags? I assume you are talking about something like this? <html> <Head></head> <body> <div class="content">Content goes here</div> <div class="title"><img src="<% =titleimg %> /></div> </body> </html> Now if that is stored in a database how do you then execute it to replace <% =titleimg %> with the actual data??
  24. You've kind of missed it. In my example both the template and the varaible would be stored in a database so would be 100% in the database. It's just the way it's organised.
  25. Maverick.Net doesn't seem to have anything programming related. Perhaps I best highlight the situation I'm thinking about with an example. You have a setting in the database that stores the title image path of the page. This setting is retireved from the database into a PHP variable $titleimgv and displayed on the page. The page is created from a template that perhaps has the form: <html> <Head></head> <body> <div class="title"><img src="$titleimg" /></div> <div class="content">Content goes here</div> </body> </html> If however the site owner decides to move the title image to the bottom of the page he can just edit the template to: <html> <Head></head> <body> <div class="content">Content goes here</div> <div class="title"><img src="$titleimg" /></div> </body> </html> As the template is evaluated no matter where the variable appears it is parsed.
×
×
  • Create New...