I'm still quite the programming novice, especially concerning Asp.net and I've just got a quick question...
On my webpage users will be able to upload excel spreadsheets to the database. But as it sits right now the file name of that uploaded data is hard coded. I got to thinking that if more than one person simultaneously uploads a file this would create two of the same named file, so the possibility that they would just rewrite the other's is there. So my thought was to somehow use a guid to overcome the trouble and just generate some very random file names so they wouldn't conflict. I've figured out how to create the guid, but now it's sending that info inside the virtual path I've created (I'm using Server.MapPath) that's got me stumped.
So is it possible to use variables within a virtual path, let alone just a simple function call to my guid generator?
Any help or insight would be greatly appreciated.
Here's a couple snippets of my code:
Public Function getNewGuid() As String Dim g As New Guid() Return Guid.NewGuid().ToString() End Function